Tuukka,
I am not aware of any ability to call out to a REST service directly from EGL. Of course, if native RPG, COBOL, or CL can do this, then you could call that.
We do support invoking a SOAP service from generated EGL COBOL Batch programs. The best doc I could find is this info using this link:
http://www.ibm.com/support/knowledgecenter/SSMQ79_9.5.0/com.ibm.egl.pg.doc/topics/pegl_serv_types_cpt.html?lang=en
EGL-generated Java and COBOL code are both in use when an EGL-generated COBOL program is deployed on IBM i and accesses a SOAP service. To understand the implication, be aware of the following runtime events:
-
The EGL-generated code calls the local, EGL-generated proxy.
-
The proxy calls the EGL COBOL runtime code; specifically, the catcher program that handles the data conversion between COBOL and Java.
-
The catcher program uses the Java Native Interface (JNI) to invoke EGL Java runtime code, which runs on the Java Virtual Machine (JVM) on IBM i.
-
The EGL Java runtime code accesses the SOAP service locally or remotely.
The initial call to the proxy is slow because the EGL Java runtime code is loaded, including all the JAR files in the classpath. The loading occurs only on the first call or after IBM i unloads the JVM from memory.
Attached is a picture of this.
I am trying to find any more detailed doc.
markevans