Topic
  • 4 replies
  • Latest Post - ‏2013-07-17T07:52:41Z by HermannSW
msmps
msmps
193 Posts

Pinned topic Response from TCP server.

‏2013-07-10T17:44:09Z |
We need to send a request to tcp server
and that tcp server might send so many responses.
 
Will DP process the responses normally? As all i saw is till now one req and corresponding response. 
Updated on 2013-07-10T17:44:26Z at 2013-07-10T17:44:26Z by msmps
  • msmps
    msmps
    193 Posts

    Re: Response from TCP server.

    ‏2013-07-11T12:39:56Z  

    Let me know is this feasible 

  • HermannSW
    HermannSW
    4640 Posts

    Re: Response from TCP server.

    ‏2013-07-11T13:22:12Z  
    • msmps
    • ‏2013-07-11T12:39:56Z

    Let me know is this feasible 

    You can access TCP backend over these 4 protocols:

    • tcp:
    • tcpssl:
    • tcps:
    • tcpsssl:

    DataPower typically does 1 request, 1 responses.

    You cannot process more than one response in case the service response type is XML/SOAP:
    https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014947493#8abe29c1-bed7-4233-9f29-6a45ae2eb354

    Reason is, that even if the TCP server will not send a FIN after the 1st XML response, DataPower will determine the end of first XML response and start processing of the response rule.


    For Non-XML data received from backend (with Non-XML response type), DataPower will wait until server closes connection by sending a FIN. This is discussed in detail in above Thread.

    So for Non-XML you server needs to close the connection after all responses have been returned to DataPower.

    But DataPower does not "know" where the boundaries of the returned messages are.
    From DataPower point of view it is just one big response.

    So you will have to parse the big response into the small responses.

     

    Hermann<myXsltBlog/> <myXsltTweets/> <myCE/>

  • msmps
    msmps
    193 Posts

    Re: Response from TCP server.

    ‏2013-07-17T03:04:28Z  
    • HermannSW
    • ‏2013-07-11T13:22:12Z

    You can access TCP backend over these 4 protocols:

    • tcp:
    • tcpssl:
    • tcps:
    • tcpsssl:

    DataPower typically does 1 request, 1 responses.

    You cannot process more than one response in case the service response type is XML/SOAP:
    https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014947493#8abe29c1-bed7-4233-9f29-6a45ae2eb354

    Reason is, that even if the TCP server will not send a FIN after the 1st XML response, DataPower will determine the end of first XML response and start processing of the response rule.


    For Non-XML data received from backend (with Non-XML response type), DataPower will wait until server closes connection by sending a FIN. This is discussed in detail in above Thread.

    So for Non-XML you server needs to close the connection after all responses have been returned to DataPower.

    But DataPower does not "know" where the boundaries of the returned messages are.
    From DataPower point of view it is just one big response.

    So you will have to parse the big response into the small responses.

     

    Hermann<myXsltBlog/> <myXsltTweets/> <myCE/>

    Thanks Hermann for the reply.

    what if we set the response type to nonxml and send couple of xml's in response.

    does the dp proceesing ends after first response or does it wait till all the responses before connection was rerminated.

  • HermannSW
    HermannSW
    4640 Posts

    Re: Response from TCP server.

    ‏2013-07-17T07:52:41Z  
    • msmps
    • ‏2013-07-17T03:04:28Z

    Thanks Hermann for the reply.

    what if we set the response type to nonxml and send couple of xml's in response.

    does the dp proceesing ends after first response or does it wait till all the responses before connection was rerminated.

    Hi Robert,

    it will wait until the backend terminates the connection by sending a FIN in that case, or until backside connection times out.

    Then it will start response rule processing.

     

    Hermann<myXsltBlog/> <myXsltTweets/> <myCE/>