Waqar Khan <wk80...@gmail.com> writes:

> But, is the above way of using dictionary as cache correct? Or is
> there a "deffered" way of doing this?  All I want is an inmemory cache
> that is compatible with this async paradigm?

Yes, it is fine to use a single dict as a cache. Twisted is
single-threaded an so only one callback is running at a time. There's no
need to lock etc.

(Or, is there another reason you need to cache to "be async"? Like maybe
it's using memcached or so?)

-- 
meejah

_______________________________________________
Twisted-Python mailing list
Twisted-Python@twistedmatrix.com
https://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Reply via email to