Skip to Content
0
Former Member
Jun 17, 2005 at 10:19 AM

JCO.Server and multithreading

256 Views

Hi All,

I have a question about how you build a JCO.Server that could accept multiple concurrent requests...

In the application we are building, the number of requests is likely to be very high and having a JCO.Server that can only accept one call at a time is likely to adversley affect performance.

I can see two ways that you may be able to fix this:

1. Build threading into the handleRequest method - I get the impression from the documentation that this won't work as it indicates that as soon as the handleRequest method completes it returns the results back to SAP.

2. We don't need to do anything - multiple concurrent requests are handled by JCO itself. I can't find any kind of documentation that supports this.

3. We register different instances of the same server against the gateway. This seems the more likely way it wants you to work, however this means there is no way to dynamically scale the application as load increases.

From looking at the underlying C RFC library documentation, it says it fully supports multithreading - so it seems a bit odd that this isn't also covered in the JCO library.

Anyone have any advice on how you can implement what we need with the JCO libraries?