Forum Stats

  • 3,826,323 Users
  • 2,260,624 Discussions
  • 7,896,896 Comments

Discussions

SOA Socket problem: Creative Ideas needed

3261249
3261249 Member Posts: 10
edited Mar 6, 2017 3:35AM in SOA Suite Discusssions

Hi All,

I have a requirement that has been driving me insane for months; My SOA Composite Application needs to start with the receival of a TCP/IP message with a flow that goes like this:

1- Receive message over TCP/IP.
2- Immediately reply with a fixed Acknowledgment message.
3- Do some logic and Call some other systems to formulate the response message in BPEL.
4- Reply with the response message over the same TCP/IP connection (without closing it) .
5- await an Acknowledgment message to mark the end of the transaction.

Problem:

I'm using the socket adapter to implement this requirement, I need to define this handshake protocol, to which I have 2 options:

- XSL: only problem is that the acknowledge message contains some special characters that are not permitted in xml1.0 (permitted in xml1.1 though)

- Java: In another project with the same requirement but where I was the sender not the receiver, I was able to implement the iCustomParser class and use the executeOutbound method where I have an input and output stream so I have full control over the protocol and it was done successfully. The problem with the requirement I have now is that I'm the receiver and there are 2 separate java methods for the inbound request:


executeInboundRequest: which takes the inputStream as a param, and executeInboundReply:which takes the payload and the output stream as param

So now when I receive the request, I won't have any way of writing back and replying with the acknowledgment(I do not have an outputstream object); so the only way to reply AFAIK(as far as I know) is to invoke the reply from BPEL which calls the "executeInboundReply" method that can also only write to the output stream so I won't even be able to read the acknowledge message(step 5) from the sender.

The only solution left is to write my own java application for receiving the TCP/IP requests without using the socket adapter and I will have to do thread management and stuff that Oracle SOA Suite should already provide out of the box.

Any ideas or help is greatly appreciated as all the solutions I tried have failed thus far.

P.S.: I don't know if this is the proper place to post such a problem and reach an audience of professional SOA developers, if there are other places, kindly tell me.

Tagged:
Switam Dhumal

Answers

  • 3261249
    3261249 Member Posts: 10
    edited Mar 6, 2017 3:35AM

    So Basically, the question was, using the socket Adapter and a java handshake iCustomParser implementation, is there any way to send TCP/IP messages in the executeInboundReply method after receiving a request?

This discussion has been closed.