Page 1 of 1

extensionHandler related nullPointerException

Posted: 09 Feb 2009, 09:56
by aMUSiC
At random points, I'm getting this kind of exception in my logs:

Code: Select all

INFO   | jvm 1    | 2009/02/09 11:58:17 | 10:58:17.017 - [ WARNING ] > Exception in ExtensionHandler: java.lang.NullPointerException
INFO   | jvm 1    | 2009/02/09 11:58:17 | Exception type: java.lang.NullPointerException
INFO   | jvm 1    | 2009/02/09 11:58:17 | java.lang.NullPointerException
INFO   | jvm 1    | 2009/02/09 11:58:17 |       at it.gotoandplay.smartfoxserver.extensions.JavascriptExtension.logASError(JavascriptExtension.java:665)
INFO   | jvm 1    | 2009/02/09 11:58:17 |       at it.gotoandplay.smartfoxserver.extensions.JavascriptExtension.handleRequest(JavascriptExtension.java:295)
INFO   | jvm 1    | 2009/02/09 11:58:17 |       at it.gotoandplay.smartfoxserver.controllers.ExtensionHandler.processEvent(ExtensionHandler.java:500)
INFO   | jvm 1    | 2009/02/09 11:58:17 |       at it.gotoandplay.smartfoxserver.controllers.ExtensionHandler.run(ExtensionHandler.java:344)
INFO   | jvm 1    | 2009/02/09 11:58:17 |       at java.lang.Thread.run(Unknown Source)
The downside is that the server is running 6 different zones with different extensions, and I don't have an indication as to which script excactly is the one that causes this problem.

So, before I go about searching through all of my extensions line by line, I'd like to ask what does this exception refer to. What kind of error should I be looking for?

Posted: 11 Feb 2009, 07:20
by Lapo
Never seen this before :(
I would need more infos on how to recreate it.

Posted: 11 Feb 2009, 11:50
by aMUSiC
I wish I knew where to start.. initially I thought that it had to do with his error I'm getting about 10-20 times a day:

[ WARNING ] > it.gotoandplay.smartfoxserver.exceptions.MissingExtensionException: Unrecognized extension name: [ backgammon ]! Zone: backgammon, Room: 1

however the time frames that this one and the above exception appear are totally different. I also do not understand why this warning occurs since there is a a backgammon.as extension with the "backgammon" name, and it's being used all the time. For that i thought that the flash client might be trying to send an XT message to the extension after its containing room has been destroyed due to some interval gone astray. However I've made sure that all intervals are cleard, but I'm still getting this.

Anyhow, it doesn't seem to affect the operation of the server and/or the games on it, but I'd like my log to have a "clean bill of health"

Posted: 12 Feb 2009, 08:27
by Lapo
Sounds like you are using lots of AS server side includes, maybe even nested includes. Is this the case?
It seems that error is caused by the parser not able to recognize which portion of the code has generated an error.
Could you give me more details? Maybe privately if you don't want to discuss your code here.

Feel free to drop us an email (From the main menu Support > Contact us)

Posted: 12 Feb 2009, 14:22
by aMUSiC
Actually there is not a single server side include on any of the extensions (I'm part Italian so I love Spaghetti... code =P)

There are basically 3 games running at all times. Each of those games has a zone level extension, and each room that gets created dynamically gets a room level extension. So basically there are 6 extensions in total with no includes.

The room level extensions send internalRequests back to their parent zone level extensions with information regarding game progress etc.

Frankly, I'm at a loss here as well...

Posted: 12 Feb 2009, 15:20
by Lapo
Server version?

Posted: 13 Feb 2009, 08:51
by aMUSiC
1.6.5. Bluebox is also latest version.

Posted: 13 Feb 2009, 09:12
by Lapo
Please zip your log files and send them to our email (from the main menu > Support > Contact us)
I'd like to take a closer look

Posted: 02 Mar 2009, 05:34
by alamed
Hello,
Was a cause found for this problem? we are getting the exact thing in our server.
Server version 1.6.5.01 with Blue box. 1 Game running. Cant not yet be reproduced.

We get the exact error in the wrapper.log.

Posted: 02 Mar 2009, 17:54
by Lapo
Yes, there's a case in which the error is reported in a cryptic way. We have now fixed the issue so we can send you a patch if you need it urgently (send us an email with a reference to this post).
An official release will be available later this month together with some other fixes.

Hope it helps