Hi all,

First of all, I am not Twisted nor Python expert, so this question is maybe 
trivial. The question is related to an IMDB plugin.
Anyway, I created a layer between my resource provider (that does some HTTTP 
operations and returns deferred) and the controllers. This is mainly for 
caching and convenience purposes and works quite OK. What I do, I create a 
singleton of my extra layer (retriever) which then internally calls resource 
provider. The problem is that if user has for example 20 movies in library, 
that means 20 defereds are fired almost instantly, resulting in 20 HTTP GETs 
(and some more because of the resource provider implementation)
This is also bit annoying for user because then the responses to the GET 
requests arrive asynchronously and therefore I want to implement a queueing 
mechanism. I got some inspiration from MediaScanner, so create an object, in 
that one create deferred and put this in the queue and return created deferred. 
When the time comes, the object is taken out of the queue, processed and (here 
comes my problem) how can I signal the original callee that "it's finished".
Maybe this needs some code example, probably it's bit too long to post it here, 
but I can add it later if it clarifies what I am talking about :)

Cheers,
Matej
----------

www.inPage.sk ��� Domena, webhosting, e-mail a seo od 3 Sk/denne.

Reply via email to