Client ignoring proxy settings

Discuss all problems you have with Servoy here. It might help to mention the Servoy version and Operating System version you are using

Client ignoring proxy settings

Postby jozef.kopanicak » Thu Sep 04, 2014 2:38 pm

Hi,

A customer of ours is having problems trying to connect to the application server through a proxy. I have searched the forum, found some suggestions how to set the proxy settings in Java and in network profiles on the application server, but the client is still trying to connect directly, as far I can see in the Java log.

We use the http&socket tunnel mode, the Proxy Settings in Java are set to use the proxy server. I told the customer to try to use the browser settings or an automatic proxy configuration script, which he did, but no luck.

The customer has shown me, that the client connects to the proxy-server once, but then continues to try to connect directly to the Application Server. I assume, the first connection being the deeplink that they start in their browser and the next connection are from Java WebStart. I let them check if they could connect from the proxy to our application server through the RMI Port and there were no problems.

Any ideas why are the proxy settings ignored?

In the Java log, there are only connection timeouts and this one:
Code: Select all
ERROR - Debug                      - Error getting the service servoy.IApplicationServer from host <our_application_server_ip:rmi_port>
java.lang.NullPointerException
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.getRemoteClientSocketFactory(ClientTunnelRMISocketFactoryFactory.java:266)
   at com.servoy.j2db.smart.J2DBClient.connectApplicationServer(J2DBClient.java:1855)
   at com.servoy.j2db.smart.J2DBClient.startApplicationServerConnection(J2DBClient.java:1836)
   at com.servoy.j2db.ClientState.applicationServerInit(ClientState.java:314)
   at com.servoy.j2db.smart.J2DBClient.startupApplication(J2DBClient.java:775)
   at com.servoy.j2db.smart.J2DBClient$4.run(J2DBClient.java:683)
   at com.servoy.j2db.smart.J2DBClient.mainImpl(J2DBClient.java:707)
   at com.servoy.j2db.smart.J2DBClient.main(J2DBClient.java:670)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at com.sun.javaws.Launcher.executeApplication(Unknown Source)
   at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
   at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
   at com.sun.javaws.Launcher.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
java.net.ConnectException: Connection timed out: connect
   at java.net.DualStackPlainSocketImpl.connect0(Native Method)
   at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
   at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
   at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
   at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
   at java.net.PlainSocketImpl.connect(Unknown Source)
   at java.net.SocksSocketImpl.connect(Unknown Source)
   at java.net.Socket.connect(Unknown Source)
   at java.net.Socket.connect(Unknown Source)
   at java.net.Socket.<init>(Unknown Source)
   at java.net.Socket.<init>(Unknown Source)
   at com.sebster.tunnel.impl.nb.createSocket(nb.java:8)
   at com.sebster.tunnel.impl.gc.connect(gc.java:5)
   at com.sebster.tunnel.DelegatingTunnelClient.connect(DelegatingTunnelClient.java:2)
   at com.sebster.tunnel.impl.bb.connect(bb.java:3)
   at com.sebster.tunnel.DelegatingTunnelClient.connect(DelegatingTunnelClient.java:2)
   at com.sebster.tunnel.impl.le.<init>(le.java:11)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider$1.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:2)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:11)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:10)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory$RmiSocketFactoryProvider.<init>(ClientTunnelRMISocketFactoryFactory.java:301)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory$RmiSocketFactoryProvider.<init>(ClientTunnelRMISocketFactoryFactory.java:299)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.createFactoryProvider(ClientTunnelRMISocketFactoryFactory.java:253)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.getClientSocketFactory(ClientTunnelRMISocketFactoryFactory.java:276)
   at com.servoy.j2db.smart.J2DBClient.exportObject(J2DBClient.java:3333)
   at com.servoy.j2db.smart.J2DBClient.bindUserClient(J2DBClient.java:3305)
   at com.servoy.j2db.ClientState.applicationServerInit(ClientState.java:315)
   at com.servoy.j2db.smart.J2DBClient.startupApplication(J2DBClient.java:775)
   at com.servoy.j2db.smart.J2DBClient$4.run(J2DBClient.java:683)
   at com.servoy.j2db.smart.J2DBClient.mainImpl(J2DBClient.java:707)
   at com.servoy.j2db.smart.J2DBClient.main(J2DBClient.java:670)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at com.sun.javaws.Launcher.executeApplication(Unknown Source)
   at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
   at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
   at com.sun.javaws.Launcher.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)


We also tried going through http, configuring the proxy settings in a network profile on the application server, and the customer reported back, the he could log in, but it was extremely slow (in the range of 15 minutes which should only take seconds). The customer has also sent me the log and the situation is similar, just istead of connection timeouts there were bad requests

Code: Select all
ERROR - Debug                      - Error getting the service servoy.IApplicationServer from host <our_application_server_ip:rmi_port>
java.lang.NullPointerException
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.getRemoteClientSocketFactory(ClientTunnelRMISocketFactoryFactory.java:266)
   at com.servoy.j2db.smart.J2DBClient.connectApplicationServer(J2DBClient.java:1855)
   at com.servoy.j2db.smart.J2DBClient.startApplicationServerConnection(J2DBClient.java:1836)
   at com.servoy.j2db.ClientState.applicationServerInit(ClientState.java:314)
   at com.servoy.j2db.smart.J2DBClient.startupApplication(J2DBClient.java:775)
   at com.servoy.j2db.smart.J2DBClient$4.run(J2DBClient.java:683)
   at com.servoy.j2db.smart.J2DBClient.mainImpl(J2DBClient.java:707)
   at com.servoy.j2db.smart.J2DBClient.main(J2DBClient.java:670)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at com.sun.javaws.Launcher.executeApplication(Unknown Source)
   at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
   at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
   at com.sun.javaws.Launcher.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)
INFO  - vb                         - using proxy <customer_proxy_hostname/proxy.pac>
INFO  - vb                         - jcifs library found; NTLM support enabled
com.sebster.tunnel.http.client.HttpException: 400 Bad Request
   at com.sebster.tunnel.impl.vb.b(vb.java:112)
   at com.sebster.tunnel.http.client.HttpTunnelClient.connect(HttpTunnelClient.java:5)
   at com.sebster.tunnel.http.client.AuthenticatingHttpTunnelClient.connect(AuthenticatingHttpTunnelClient.java:27)
   at com.sebster.tunnel.impl.bb.connect(bb.java:3)
   at com.sebster.tunnel.DelegatingTunnelClient.connect(DelegatingTunnelClient.java:2)
   at com.sebster.tunnel.impl.le.<init>(le.java:11)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider$1.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:2)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:11)
   at com.sebster.tunnel.multiplexer.rmi.ClientMultiplexedRmiSocketFactoryProvider.<init>(ClientMultiplexedRmiSocketFactoryProvider.java:10)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory$RmiSocketFactoryProvider.<init>(ClientTunnelRMISocketFactoryFactory.java:301)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory$RmiSocketFactoryProvider.<init>(ClientTunnelRMISocketFactoryFactory.java:299)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.createFactoryProvider(ClientTunnelRMISocketFactoryFactory.java:253)
   at com.servoy.j2db.server.rmi.tunnel.ClientTunnelRMISocketFactoryFactory.getClientSocketFactory(ClientTunnelRMISocketFactoryFactory.java:276)
   at com.servoy.j2db.smart.J2DBClient.exportObject(J2DBClient.java:3333)
   at com.servoy.j2db.smart.J2DBClient.bindUserClient(J2DBClient.java:3305)
   at com.servoy.j2db.ClientState.applicationServerInit(ClientState.java:315)
   at com.servoy.j2db.smart.J2DBClient.startupApplication(J2DBClient.java:775)
   at com.servoy.j2db.smart.J2DBClient$4.run(J2DBClient.java:683)
   at com.servoy.j2db.smart.J2DBClient.mainImpl(J2DBClient.java:707)
   at com.servoy.j2db.smart.J2DBClient.main(J2DBClient.java:670)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
   at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
   at java.lang.reflect.Method.invoke(Unknown Source)
   at com.sun.javaws.Launcher.executeApplication(Unknown Source)
   at com.sun.javaws.Launcher.executeMainClass(Unknown Source)
   at com.sun.javaws.Launcher.doLaunchApp(Unknown Source)
   at com.sun.javaws.Launcher.run(Unknown Source)
   at java.lang.Thread.run(Unknown Source)


I am really at a loss here. What else can I do? Are the bad requests a problem on the proxy side? As far as I understand, http mode should only go through the http port. Why is there an "Error getting the service servoy.IApplicationServer from host <our_application_server_ip:rmi_port>"?
Jozef Kopanicak
Mirus Software AG
jozef.kopanicak
 
Posts: 11
Joined: Wed Aug 29, 2012 10:17 am

Return to Discuss possible Issues and Bugs

Who is online

Users browsing this forum: No registered users and 10 guests

cron