Re: Outbound Call with JCO

Emre Kosen <[email protected]> Thu, 26 Jun 2003 09:00:57 -0600
Newsgroups gmane.comp.java.sun.connector
Message-ID <[email protected]>
Hi,

As you mentioned JCo supports both inbound (Java calls ABAP) and outbound (ABAP calls Java) calls in desktop and web server applications. You can see inbound call examples at JCo Tutorial bundled in the sapjco package. Thomas Schuessler's writing style and editing of the tutorial is clean and understandable. Unfortunately, there is no outbound call examples which is the missing point. However in the docs folder of the same package you can see 2 examples(Example5.java and Example7.java) about writing an RFC Server with Java, but these are only code snippets and no information again.

Now, let me briefly explain the outbound call process:

Java Part:
-Write your listener server with/without using the template at Example5/7.

BASIS Part:
-with transaction sm59, create an RFC Destination (type TCP/IP). Set 'Activation Type' as Registration and enter your Program ID into 'Registration' field. IMPORTANT: Program ID will be the same with the one in your Java code! Do not forget to define your gateway host and service since SAP will access your listener via this gateway.

ABAP Part:
-Write a report program or a wrapper func. module to test your listener. In the program, call the listener as shown below:

CALL FUNCTION <your Program ID> DESTINATION <your RFC Destination>
.
.
.

Now, you have written an RFC Server with Java :)

Best Regards,
Emre

===========================================================================
To unsubscribe, send email to [email protected] and include in the body
of the message "signoff CONNECTOR-INTEREST".  For general help, send email to
[email protected] and include in the body of the message "help".