Page 1 of 1

Exception at SmartFoxServer.canLogin

Posted: 24 Nov 2006, 10:30
by milosh6
Hello Lapo :)

well, we are now receiving the exception when calling the "canLogin" method, and we really cannot figure out why is this exception generated, as it is generated by canLogin method.

Here is the stack trace. Any ideas?

Code: Select all

java.lang.NullPointerException
	at it.gotoandplay.smartfoxserver.SmartFoxServer.canLogin(SmartFoxServer.java:1985)
	at it.gotoandplay.smartfoxserver.extensions.ExtensionHelper.canLogin(ExtensionHelper.java:102)
	at geesee.handler.LoginRequest.execute(LoginRequest.java:168)
	at geesee.handler.Handler.run(Handler.java:54)
	at geesee.GeeseeExtension.handleInternalEvent(GeeseeExtension.java:137)
	at it.gotoandplay.smartfoxserver.controllers.MessageHandler.dispatchEvent(MessageHandler.java:141)
	at it.gotoandplay.smartfoxserver.controllers.SystemHandler.handleLoginRequest(SystemHandler.java:374)
	at it.gotoandplay.smartfoxserver.controllers.SystemHandler.processEvent(SystemHandler.java:164)
	at it.gotoandplay.smartfoxserver.controllers.SystemHandler.run(SystemHandler.java:112)
	at java.lang.Thread.run(Unknown Source)

Posted: 24 Nov 2006, 14:14
by Lapo
is this error happening on each login attempt?
To me it looks like the client got disconnected in the middle of the login transaction

Posted: 24 Nov 2006, 14:51
by milosh6
No, it happens only sometimes, but relatively often considering the amount of clients using the chat. How do we prevent this exception from occuring?

Posted: 24 Nov 2006, 15:31
by Lapo
This exception should be seen very rarely or not seen at all.
Paired with the other problems you reported it seems that often connections get closed or shut down unexpectedly. Also it sounds weird that these connections die so prematurely... i.e. at login time, which usually happens a few seconds after connecting.

Is your server exposed directly to the internet? Or is it behind a router / firewall? Does it run a software firewall?
Are these failed connections coming always from the same place?

If you want we can try a remote test with a stress test tool, opening a few connections (50-100 or more) and see what happens.
Maybe drop us an email so we can discuss how to do it.

hope it helps