-> http clients don't die: max_clients limit reached, request queued. 10 active, 217 queued requests.
-> remote adding ui could be improved (cleanup fields on ok/on load, no error message until everything is ok)
--> kill the motion respawning mechanism on sigint
-> add an autoupdate mechanism
-> style scroll bars
# add a motion running checker
def checker():
+ ioloop = tornado.ioloop.IOLoop.instance()
+ if not ioloop.running(): # just stopped
+ return
+
if not motionctl.running() and config.has_enabled_cameras():
motionctl.start()
logging.info('motion started')
- ioloop = tornado.ioloop.IOLoop.instance()
ioloop.add_timeout(datetime.timedelta(seconds=settings.MOTION_CHECK_INTERVAL), checker)
checker()
import cleanup
def do_cleanup():
+ ioloop = tornado.ioloop.IOLoop.instance()
+ if not ioloop.running(): # just stopped
+ return
+
try:
cleanup.cleanup_images()
cleanup.cleanup_movies()
logging.error('failed to cleanup media files: %(msg)s' % {
'msg': unicode(e)})
- ioloop = tornado.ioloop.IOLoop.instance()
ioloop.add_timeout(datetime.timedelta(seconds=settings.CLEANUP_INTERVAL), do_cleanup)
do_cleanup()