if you use sessions, consider something different then the disk-based ones .... 10 times a second can get messy faster then you think if multiple users are involved. I'd use caches, but default caches like cache.ram or cache.disk would have nearly the same problem. Consider switching to memcache or redis, and in that case, there are adapters for either cache or sessions. Another sweet thing would be to use a fast database backend.
On Wednesday, March 13, 2013 11:27:10 AM UTC+1, Alan Etkin wrote: > > > I am sending ajax requests to the server every 100 milli secs. And I want >> to share a variable between every request that need to be updated on every >> request. I tried using global variable but it din't worked. Neither could I >> find anything like static variables. >> > > Why you don't use the session object? > > # This persists trough requests > # until the session is cleared > session.myvar = <updated value> > > -- --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.

