I have a problem with payara running on docker. I’m running the image payara/server-full:5.2022.5 on docker on ubuntu/wsl on windows 11. I’m unable to connect to the ejb-port 3700 from windows. Connection from ubuntu/wsl works well. I have tried a lot of things… May you can help me to connect to the payara and make jndi-lookups.
Start the payara-container:
docker run -p 3700:3700 -p 8080:8080 -p 4848:4848 payara/server-full:5.2022.5
I dont have deployed anything.
After that I can reach localhost:8080 and localhost:4848 from my windows-browser (4848 with certificat-issues).
I wrote a minimal java-ejb-client that lookups the default jdbc-datasource (“jdbc/__default”). Lookup works fine from ubuntu/wsl, but dosnt work from windows.
Result of minimal-example-client startet from Ubuntu/WSL:
Start minimal example client Apr 21, 2023 8:22:41 AM com.sun.enterprise.v3.server.CommonClassLoaderServiceImpl findH2Client INFO: Cannot find h2db client jar file, h2 jdbc driver will not be available by default. Apr 21, 2023 8:22:42 AM org.glassfish.enterprise.iiop.api.GlassFishORBHelper postConstruct INFO: GlassFishORBFactory service initialized. Apr 21, 2023 8:22:47 AM org.hibernate.validator.internal.util.Version <clinit> INFO: HV000001: Hibernate Validator null Got instance: com.sun.gjc.spi.jdbc40.DataSource40@1da4b3f9
minimal-example-client startet from windows:
Start minimal example client Apr 21, 2023 8:23:54 AM com.sun.enterprise.v3.server.CommonClassLoaderServiceImpl findH2Client INFORMATION: Cannot find h2db client jar file, h2 jdbc driver will not be available by default. Apr 21, 2023 8:23:54 AM org.glassfish.enterprise.iiop.api.GlassFishORBHelper postConstruct INFORMATION: GlassFishORBFactory service initialized.
Than the connection hangs for at least 30 minutes. The application will not terminate, no exception, nothing happens.
If I remove the IIOP-Listener at port 3700 and change the admin-server to listen at 3700, I can reach the admin-webpage from windows-browser at localhost:3700. That means, there are no networking/firewall/portmapping-issues.
If I do a tcpdump on the payara-docker-container, I see different communications from the ubuntu/wsl and windows. Both tcpdumps attached here. I see, that the communication from windows contains the external-windows-ip in cleartext. The communication from ubuntu/wsl dont transmit any IP at this location.
I have created an own image based on openjdk and installed payara by hand in that container. Same issue…
For some special reasons, Im pinned to Java8. So I cant update to Payara6 at this moment.
I cant switch to the ejb via http invoker-servlet, because I need to lookup JMS-Resources. This is not (yet) supportet by the http-interface.
Is there an general restriction for using EJB-Lookups in this setup? Why is port 3700 not exposed by default in the docker-file?
What can I do to get this simple case working?
Thanks in advance for every kind of help!