Hi
TomEE does have the ability to do remote EJB calls over HTTP, although it
isn't based on IIOP. This capability has actually been around in OpenEJB in
the pre-TomEE days :-).
In TomEE, you'll need to enable remote support, and configure a list of
packages that are allowed to be serialized/deserialized.
tomee.remote.support = true
tomee.serialization.class.blacklist = *
tomee.serialization.class.whitelist = org.mycompany.package
After that, you can lookup and call remote EJBs in the usual way. The
global JNDI names of your EJBs should be logged out at deploy time.
Properties properties = new Properties();
properties.put(Context.INITIAL_CONTEXT_FACTORY,
"org.apache.openejb.client.RemoteInitialContextFactory");
properties.put(Context.PROVIDER_URL, "
http://localhost:8080/tomee/ejb");
Context ctx = new InitialContext(properties);
Object ref =
ctx.lookup("global/ejb-remote-call-2/Greetings!org.superbiz.remote.Greetings");
This should also work with a reverse proxy such as HTTPD in front of TomEE.
You may wish to turn on authentication so anonymous users can't call your
business methods.
I've always quite liked this functionality as it enables remote EJB access
in a fairly straightforward way, without needing to open up other ports.
Hope that helps.
Jon
On Tue, Mar 23, 2021 at 4:00 PM COURTAULT Francois <
[email protected]> wrote:
> Hello everyone,
>
> Previously we were using Welogic. In one of our use-case, we performed a
> remote EJB (so using iiop) call to the our customer backend over the
> internet.
> Because of some firewall issue we might have, we use http tunneling iiop
> to perform this call.
>
> Do you know if we can do the same with TomEE ?
>
> Best Regards.
>
>
>
>