SFS2x 2.2.0 GhostHunter NPE

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

grhwood
Posts: 116
Joined: 15 Mar 2011, 04:43

SFS2x 2.2.0 GhostHunter NPE

Postby grhwood » 02 Nov 2012, 08:08

Hi,

This happened occasionally. Here is the stacktrace;

Code: Select all

Scheduler callback exception. Callback: com.smartfoxserver.bitswarm.sessions.DefaultSessionManager$SessionCleaner@90d9c17, Exception: java.lang.NullPointerException
        com.smartfoxserver.v2.util.monitor.GhostUserHunter.buildReport(GhostUserHunter.java:93)
        com.smartfoxserver.v2.util.monitor.GhostUserHunter.hunt(GhostUserHunter.java:59)
        com.smartfoxserver.v2.SmartFoxServer$NetworkEvtListener.handleEvent(SmartFoxServer.java:996)
        com.smartfoxserver.bitswarm.service.BaseCoreService.dispatchEvent(BaseCoreService.java:110)
        com.smartfoxserver.bitswarm.sessions.DefaultSessionManager.applySessionCleaning(DefaultSessionManager.java:743)
        com.smartfoxserver.bitswarm.sessions.DefaultSessionManager.access$0(DefaultSessionManager.java:688)
        com.smartfoxserver.bitswarm.sessions.DefaultSessionManager$SessionCleaner.doTask(DefaultSessionManager.java:86)
        com.smartfoxserver.bitswarm.util.scheduling.Scheduler.executeTasks(Scheduler.java:214)
        com.smartfoxserver.bitswarm.util.scheduling.Scheduler.run(Scheduler.java:152)
        java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
        java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
        java.lang.Thread.run(Thread.java:722)
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: SFS2x 2.2.0 GhostHunter NPE

Postby Lapo » 02 Nov 2012, 09:30

Thanks for reporting, it should be nothing to worry about but we'll make sure to avoid reporting the error in the next release
Thanks
Lapo
--
gotoAndPlay()
...addicted to flash games
User avatar
Fraggle
Posts: 62
Joined: 02 Apr 2010, 06:41
Location: Paris, France

Re: SFS2x 2.2.0 GhostHunter NPE

Postby Fraggle » 16 Jan 2013, 08:54

2.4.0, still having the issue.

Will upgrade to 2.5.0 and see how it goes.
Could this be related to a unusually high number of packet dropped?
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: SFS2x 2.2.0 GhostHunter NPE

Postby Lapo » 16 Jan 2013, 09:14

If there's many ghost users, maybe.
Lapo

--

gotoAndPlay()

...addicted to flash games
User avatar
Fraggle
Posts: 62
Joined: 02 Apr 2010, 06:41
Location: Paris, France

Re: SFS2x 2.2.0 GhostHunter NPE

Postby Fraggle » 17 Jan 2013, 13:41

Hi Lapo,

We upgraded to 2.5.0 and I sill have the NPE:

Code: Select all

17 Jan 2013 | 13:22:03,449 | WARN  | Scheduler1-thread-1 | bootLogger |     | Scheduler callback exception. Callback: com.smartfoxserver.bitswarm.sessions.DefaultSessionManager$SessionCleaner@3b0e95ca, Exception: java.lang.NullPointerException
   com.smartfoxserver.v2.util.monitor.GhostUserHunter.buildReport(GhostUserHunter.java:109)
   com.smartfoxserver.v2.util.monitor.GhostUserHunter.hunt(GhostUserHunter.java:59)
   com.smartfoxserver.v2.SmartFoxServer$NetworkEvtListener.handleEvent(SmartFoxServer.java:1025)
   com.smartfoxserver.bitswarm.service.BaseCoreService.dispatchEvent(BaseCoreService.java:110)
   com.smartfoxserver.bitswarm.sessions.DefaultSessionManager.applySessionCleaning(DefaultSessionManager.java:754)
   com.smartfoxserver.bitswarm.sessions.DefaultSessionManager.access$0(DefaultSessionManager.java:699)
   com.smartfoxserver.bitswarm.sessions.DefaultSessionManager$SessionCleaner.doTask(DefaultSessionManager.java:87)
   com.smartfoxserver.bitswarm.util.scheduling.Scheduler.executeTasks(Scheduler.java:214)
   com.smartfoxserver.bitswarm.util.scheduling.Scheduler.run(Scheduler.java:152)
   java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
   java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
   java.lang.Thread.run(Unknown Source)


Also, I have user that are "logged in" from smartfox point of view, but still connected after more than 24h of inactivity (the connexion is not in CLOSE_WAIT on the server). Thoses users have 85bytes in, 235bytes out, and then a lot of drop packet and a huge message queue.
I'm using CustomLogin, I'm guessing they are disconnecting before the CustomLogin handler is done, causing a race conditions that leave them in a "strange" state. I'll try to reproduce it and let you know.
Still, I was expecting the Ghost Hunter to kick them out, but they are still there.

Any idea?

Fraggle
User avatar
Lapo
Site Admin
Posts: 23008
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: SFS2x 2.2.0 GhostHunter NPE

Postby Lapo » 17 Jan 2013, 14:54

Hi,
I have to ask if you are entirely sure that the patch was applied correctly because the error line numbers don't match with the 2.5 code.

I'm using CustomLogin, I'm guessing they are disconnecting before the CustomLogin handler is done, causing a race conditions that leave them in a "strange" state. I'll try to reproduce it and let you know.
Still, I was expecting the Ghost Hunter to kick them out, but they are still there.

I would like to investigate this more closely. Don't restart the server if possible, and get in touch with me (Lapo) using support@... we can send a diagnostic extension that allows us to see what's going on.
It's the only way for us to understand what's happening, since these issues are very hard to reproduce at will

thanks
Lapo

--

gotoAndPlay()

...addicted to flash games

Return to “SFS2X Questions”

Who is online

Users browsing this forum: No registered users and 58 guests