mrjoes / tornadio2

Python socket.io server implementation on top of Tornado framework
Other
523 stars 118 forks source link

session_check_interval is in milliseconds instead of seconds #41

Closed dop251 closed 12 years ago

dop251 commented 12 years ago

Hi,

I've noticed that the session check interval is taken directly from the settings (where it's said to be in seconds and default value is 15) and supplied to the PeriodicCallback constructor. However the constructor expects milliseconds, rather than seconds. It should be fixed by multiplying check_interval by 1000 in the following line:

self._sessions_cleanup = ioloop.PeriodicCallback(self._sessions.expire, check_interval, self.io_loop)

Dmitry