Error "Connection to Servoy Server is invalid"

Questions, answers, tips and ideas on Servoy Client

Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 9:05 am

Hi all,
I'm trying to get my first solution running at customers site. Unfortunately when I connect from a client PC to the server, the Java-engine starts up, then the standard Smartclient window shows up and finally a messagebox with the error "Connection to Servoy Server is invalid" pops up. The same link (http://192.168.1.217:8080/servoy-client ... lient.jnlp) works fine when I directly call that on the application server box itself, thus the link as well as the basic setup and application must be ok.

I then switched Tracing on at the appserver and get the following errors:
Code: Select all
2011-07-08 08:23 SocketAccepter[0] INFO com.servoy.j2db.util.Debug Compressing socket closed
2011-07-08 08:23 SocketAccepter[0] ERROR com.servoy.j2db.util.Debug SocketAcceptor failure for socket: 2ff7ac92[SSL_NULL_WITH_NULL_NULL: Socket[addr=/192.168.1.97,port=55089,localport=1099]]
I/O exception, see log for full details: Unrecognized SSL message, plaintext connection?
2011-07-08 08:23 http-8080-1 INFO com.servoy.j2db.util.Debug Loading messages from server: null table: null
2011-07-08 08:23 http-8080-1 INFO com.servoy.j2db.util.Debug Loading messages on server for a client, modified change: -1, language: de_DE, solution: null


For further testing I have disabled all local firewalls on the server als well as on the client. Tested with different clients, which are standard "Windows 7 Pro" or WinXP boxes, the server is a Windows 2008 R2. Servoy is on 5.2.9, i.e. everything is on current patchlevel. Network is a standard Windows Domain network environment, all PCs are in the same IP-segment.

What is the problem here?
Last edited by wOOdy on Tue Jul 12, 2011 7:07 pm, edited 1 time in total.
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby ROCLASI » Fri Jul 08, 2011 9:49 am

Hi wOOdy,

The most common issue is that people don't have 'Direct Connection' selected in the network settings in the Java Control panel.
Can you check that ?
Robert Ivens
SAN Developer / Servoy Valued Professional / Servoy Certified Developer

ROCLASI Software Solutions / JBS Group, Partner
Mastodon: @roclasi
--
ServoyForge - Building Open Source Software.
PostgreSQL - The world's most advanced open source database.
User avatar
ROCLASI
Servoy Expert
 
Posts: 5438
Joined: Thu Oct 02, 2003 9:49 am
Location: Netherlands/Belgium

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 10:13 am

Hi Robert,
Yepp. It works with "Direct Connection". Is that the only solution? Because that would mean, that other Java-based apps with different sources may not work then, since they wouldn't find their way to the standard internet proxy ?
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby ROCLASI » Fri Jul 08, 2011 10:24 am

Hi wOOdy,

As far as I know this is it but I am no Windows guru.
But why would you think other apps might not work ? A proxy only adds an extra layer of complexity and thus is more likely to cause issues (like with Servoy) than a direct connection.
Robert Ivens
SAN Developer / Servoy Valued Professional / Servoy Certified Developer

ROCLASI Software Solutions / JBS Group, Partner
Mastodon: @roclasi
--
ServoyForge - Building Open Source Software.
PostgreSQL - The world's most advanced open source database.
User avatar
ROCLASI
Servoy Expert
 
Posts: 5438
Joined: Thu Oct 02, 2003 9:49 am
Location: Netherlands/Belgium

Re: Error "Connection to Servoy Server is invalid"

Postby Harjo » Fri Jul 08, 2011 11:09 am

wOOdy, what is your connectionmode on the servoy-server?

try using, http & socket or complete http tunneling,
that works oke, with proxy servers! and you dont have set java to direct connection.
Harjo Kompagnie
ServoyCamp
Servoy Certified Developer
Servoy Valued Professional
SAN Developer
Harjo
 
Posts: 4321
Joined: Fri Apr 25, 2003 11:42 pm
Location: DEN HAM OV, The Netherlands

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 12:31 pm

Hi Robert,

In real-world installations you always have a firewall/proxy combination to protect the internal network from outsiders as well as block internal highjackers to send stuff to the outside world. Thus a proxy should be really a common scenario. I have already added exeptions to the proxy rules for that Servoy-Appserver, but somehow they are not respected by the Servoy client.

Ok, so if I have to set that DirectConnection on each and every client: Is there a way to automate that setting or to globally set it for all clients? Changing 50 or more PCs manually doesn't make me too happy, and isn't exactly what I would call a "maintainence-free One-Click installation". Haven't found a working solution to use the GroupPolicies for centrally managing the Java Runtime settings. Anyone with success here?
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby ROCLASI » Fri Jul 08, 2011 12:48 pm

Hi wOOdy,

wOOdy wrote:In real-world installations you always have a firewall/proxy combination to protect the internal network from outsiders as well as block internal highjackers to send stuff to the outside world. Thus a proxy should be really a common scenario.


I didn't dispute that fact. All I was asking why you would think other java apps would not work with Direct Connection when Servoy does in your environment.

wOOdy wrote:I have already added exeptions to the proxy rules for that Servoy-Appserver, but somehow they are not respected by the Servoy client.

Ok, so if I have to set that DirectConnection on each and every client: Is there a way to automate that setting or to globally set it for all clients? Changing 50 or more PCs manually doesn't make me too happy, and isn't exactly what I would call a "maintainence-free One-Click installation". Haven't found a working solution to use the GroupPolicies for centrally managing the Java Runtime settings. Anyone with success here?

I think this (the proxy question) might be a question for Sebastiaan (sebster).
Robert Ivens
SAN Developer / Servoy Valued Professional / Servoy Certified Developer

ROCLASI Software Solutions / JBS Group, Partner
Mastodon: @roclasi
--
ServoyForge - Building Open Source Software.
PostgreSQL - The world's most advanced open source database.
User avatar
ROCLASI
Servoy Expert
 
Posts: 5438
Joined: Thu Oct 02, 2003 9:49 am
Location: Netherlands/Belgium

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 12:59 pm

Harjo wrote:wOOdy, what is your connectionmode on the servoy-server?
try using, http & socket or complete http tunneling,


Are you talking about the setting at /servoy-admin/network-settings/ SocketFactory.tunnelConnectionMode? That one was originally at "http", I then tried the other two settings. Both times also restarted the server, but still had no luck. Is there anything else to adhere to?
Last edited by wOOdy on Tue Jul 12, 2011 7:08 pm, edited 1 time in total.
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 1:11 pm

ROCLASI wrote: All I was asking why you would think other java apps would not work with Direct Connection when Servoy does in your environment.

Sorry, I missed that part in my first answer.
In our scenario the ServoyAppServer is an Intranet application, and therefor can get accessed by "direct connection". But if another Java-app would be an Internet / External application, then that outgoing traffic would get blocked by the firewall, if in "direct connection" mode. Only if you use the redirection ports trough the firewall, the communication to an outside app would be working. At least, that's my understanding of firewalls/proxies so far. :) Thus you could either have DirectConnection enabled and Servoy is happy, but all external JavaApps are not working; or have the external Stuff working, but not Servoy. Not the best solution... But I could be wrong of course. Dabbling with all that network stuff is not my primary expertise :)

wOOdy
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Fri Jul 08, 2011 1:16 pm

Since Robert says "the most common issue", this implies that this is a somewhat common problem? Therefor I tried to find some pointers by googling the web as well as searching the Servoy-Wiki.
If I do this query on the wiki
http://wiki.servoy.com/dosearchsite.action?key=DOCS&searchQuery.queryString=direct+connection&searchQuery.spaceKey=DOCS
the third exerpt seems to be the ticket, since it talks about "Enable direct connections..."
But when I click on the provided link, this text-excerpt is not shown?! Where did the Wiki-search found that text?
<groan>
Last edited by wOOdy on Tue Jul 12, 2011 7:08 pm, edited 1 time in total.
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby jcompagner » Tue Jul 12, 2011 5:15 pm

if you need to go over proxies, and the clients all have proxies configured you have to use the tunnel (in http&socket would then be the best thing)

in 5.x you have first to set this property: SocketFactory.rmiServerFactory (set it to 'com.servoy.j2db.server.rmi.tunnel.ServerTunnelRMISocketFactoryFactory') then the property below (SocketFactory.tunnelConnectionMode) can be set to http&socket

then clients will be able to connect without the change to direct connection.
But they will then use the proxy if that is the thing that is configured,
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8828
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet

Re: Error "Connection to Servoy Server is invalid"

Postby wOOdy » Tue Jul 12, 2011 7:02 pm

Hi Johan,

Yes, that did the trick! Thank you very much... I was aready experimenting with a company-wide centralized Java config file, which could get pushed to the clients via group-policies. But this way it's much easier.
With kind regards from Bavaria

wOOdy

Servoy and Visual FoxPro Evangelist
Microsoft "Most Valuable Professional" from 1996 to 2009
"Servoy Valued Professional“ 2011
wOOdy
 
Posts: 20
Joined: Mon Aug 09, 2010 2:43 pm

Re: Error "Connection to Servoy Server is invalid"

Postby Robert Huber » Tue Jul 12, 2011 7:48 pm

Hi

I just today happened to have the exact same error on 2 different Windows Server 2008R2 starting a Smart Client (not from the Developer). Same behaviour on a Windows 7 machine, also a connection error. Quite strange. If I use a MacBook as client, it works. Somewhere must be a small difference here.

Regards,

PS: I also can't get the Application Server updated, may be it has something to do with that behaviour (see thread: viewtopic.php?f=11&t=16453&p=88845#p88845).
Attachments
connection invalid.png
connection invalid.png (6.73 KiB) Viewed 14122 times
Robert Huber
7r gmbh, Switzerland
SAN Developer
www.seven-r.ch
User avatar
Robert Huber
 
Posts: 1239
Joined: Tue Aug 23, 2005 6:52 pm
Location: Schaffhausen, Switzerland

Re: Error "Connection to Servoy Server is invalid"

Postby jcarlos » Tue Sep 25, 2012 10:41 pm

Robert Huber wrote:I just today happened to have the exact same error on 2 different Windows Server 2008R2 starting a Smart Client (not from the Developer). Same behaviour on a Windows 7 machine, also a connection error. Quite strange. If I use a MacBook as client, it works. Somewhere must be a small difference here.


Hi Robert,

How was the issue resolved for you?

Thanks! Carlos
Juan-Carlos Sanchez, Stanford University - Law and Economics
jcarlos
 
Posts: 578
Joined: Thu May 04, 2006 8:55 pm
Location: Palo Alto, California USA

Re: Error "Connection to Servoy Server is invalid"

Postby jcarlos » Tue Sep 25, 2012 11:51 pm

jcompagner wrote:if you need to go over proxies, and the clients all have proxies configured you have to use the tunnel (in http&socket would then be the best thing)

in 5.x you have first to set this property: SocketFactory.rmiServerFactory (set it to 'com.servoy.j2db.server.rmi.tunnel.ServerTunnelRMISocketFactoryFactory') then the property below (SocketFactory.tunnelConnectionMode) can be set to http&socket

then clients will be able to connect without the change to direct connection.
But they will then use the proxy if that is the thing that is configured,


Hi Johan,

Only one of my clients running windows 7 64 bit, and the latest recommended version of Java (32-bit Java 7), can’t connect to the server. This client gets the exact same message: Error "Connection to Servoy Server is invalid"

We are using Servoy 6.1.0.

I want to follow the recipe that you pointed out here, but I can't find the SocketFactory.rmiServerFactory in either the servoy-admin/network-settings page or the servoy.properties file.

Did this change in Sevoy 6.1? Any help will be appreciated!

Thank you, Carlos
Juan-Carlos Sanchez, Stanford University - Law and Economics
jcarlos
 
Posts: 578
Joined: Thu May 04, 2006 8:55 pm
Location: Palo Alto, California USA

Next

Return to Servoy Client

Who is online

Users browsing this forum: No registered users and 5 guests