$(function () { pageContext.i18n.modTalk = 'moderation talk'; pageContext.i18n.replyToComment = 'Reply'; pageContext.i18n.modTalkEmpty = 'moderation talk is empty'; pageContext.url.getModTalk = "/comments/%25ID%25/listModTalk.json"; pageContext.url.possibleCommentRecipients = "/comments/%ID%/possibleRecipients.json"; pageContext.url.commentEdit = '/comments/%25ID%25/edit.html'; pageContext.url.commentView = '/comments/%ID%/view.html'; pageContext.i18n.commentVisibility = { 'full': 'Viewable by all users', 'op': 'Viewable by the original poster', 'mod': 'Viewable by moderators', 'opAndMod': 'Viewable by moderators and the original poster', 'other': 'Advanced visibility', 'dialogTitle': 'Comment visibility', 'selectGroups': 'Visible to groups', 'selectOther': 'Other recipients', 'selectOriginalPoster': 'Original poster', 'selectModerators': 'Moderators', 'selectAssignees': 'Asked to answer users' }; pageContext.i18n.commentMenuLabels = { 'comment-edit': 'comments.menu.edit', 'comment-delete': 'comments.menu.delete', 'comment-convert': 'comments.menu.convert' };pageContext.i18n.answer= { bestAnswer: 'Best Answer', controlBar : { accept: 'Accept', unaccept: 'Unaccept', acceptCommand: 'Accept this answer as correct', cancelAcceptedCommand: 'Remove this answers accepted status' } }; window.croles = { u: false, op: false, m: false, og: false, as: false, ag: false, dc: false, doc: false, eo: false, ea: false }; tools.init({ q: { e: false, ew: false, eo: false, r: false, ro: false, d: false, dow: false, fv: false, c: false, co: false, p: false, tm: false , ms: false, mos: false }, n: { f: false, vf: false, vfo: false, vr: false, vro: false, c: false, co: false, vu: false, vd: false, w: false, wo: false, l: false }, c: { e: false, eo: false, d: false, dow: false, ta: false, tao: false, l: false }, a: { e: false, ew: false, eo: false, d: false, dow: false, a: false, aoq: false, ao: false, tc: false, tco: false, p: false, tm: false }, pc: croles }, { tc: true, nsc: true }); commandUtils.initializeLabels(); }); Skip to Content

HTTP Sender ,HCI Odata Receiver Multiple Entity Set ,Unable to POST the data

Hi Experts,

We are doing a HTTP to OData Scenario,where the OData Receiver has multiple entity Sets. OData is from a gateway OData Receiver.

The error which we are facing is trying to post the data from POSTMAN:

"Bad Request : 400 : HTTP/1.1 005056A509B11ED1BDD3D7B1A3B4C509 http://schemas.microsoft.com/ado/2007/08/dataservices/metadata"> 005056A509B11ED1BDD3D7B1A3B4C509 xml:lang="en">The request URI is not valid. The segment 'POSet' refers to an entity set and not to a single entity http://schemas.microsoft.com/ado/2007/08/dataservices/metadata"> "

PFB Screenshots of the Receiver OData Configuration :

Note :

The receiver system, is on the cloud and not on-premise.


odata-receiver.jpg (76.2 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    Apr 05, 2017 at 06:14 AM

    Hi Shreyas,

    Please could you share the format of data from the sender. Is its JSON ?, then you could directly use the HTTP receiver adapter without using the converter step to send data to the OData receiver.

    I am not sure why this defaultTenant is getting added, this should be checked.

    Regards,

    Gayathri

    Add comment
    10|10000 characters needed characters exceeded

    • Yes the format of the data is in JSON. Given below is the format of the data.

      {

      "root_element" :

      {

      "key":"value",

      "key":"value",

      "key":"value",

      "element" :{

      "key":"value",

      "key":"value",

      }

      ,

      "itemlist" [

      "key":"value",

      "key":"value",

      "key":"value",

      },

      {

      "key":"value",

      "key":"value",

      "key":"value",

      }

      ]

      "additem":[

      {

      "key":"value",

      "key":"value",

      },

      {

      "key":"value",

      "key":"value",

      }

      ]

      }

      }

      We even tried with the receiver adapter as HTTP but we were facing some problemswith CSRF-tokens.

  • Apr 04, 2017 at 08:07 AM

    Hi Shreyas,

    The error states bad request, so looks like there is an issue in the resource path. Try by selecting a single entity. Please could you try remodeling the request using the inbuilt tool modeler?

    Regards,

    Gayathri

    Add comment
    10|10000 characters needed characters exceeded

  • Apr 05, 2017 at 04:56 AM

    Hi Gayathri,

    Yes I did do the modelling and there were multiple entity sets,that were shown and I selected the POSet which was required.

    PFB screenshot of the model operation :

    PFB screenshot of the scenario :

    The problem that we were facing was the converted XML format from the converter is not accpeted by the OData receiver,

    I.e there is a format mismatch of the XML payload of the converter and OData.

    Also on the receiver side if we give the connection details as per below screenshot :

    Then we get the following error on the postman :

    An internal server error occured: Request Payload: Either the OData metadata content available in the server is outdated or the request payload seems to be incorrect = http://ip_address:8080/sap/opu/odata/sap/ZMOH_PO_CREATION_SRV_defaultTenant with error => No such entity found in the edmx.

    My doubt is that why a _defaultTenant gets added in this URL:

    http://ip_address:8080/sap/opu/odata/sap/ZMOH_PO_CREATION_SRV_defaultTenant .even though we have given the entity set.

    Please suggest a way tackle this issue.

    Thanks and Regards

    Sreyas


    Add comment
    10|10000 characters needed characters exceeded