I already grep'ed my virtualenv for "threadpool" and there's nothing except
gevent itself, which uses it :(
Same for my project's code.

threadpool is used somewhere inside gevent.hub, and the amount of threads -
10 set there as default, signals that it's gevent's threadpool threads that
are present in my app.

So still no clue of the problem, I'll try to ask to Denis for help on this.

Thanks!


On Mon, Jun 24, 2013 at 11:01 PM, Roberto De Ioris <[email protected]> wrote:

>
> >> >
> >>
> >> It looks like you are using a python c module not using the gil in the
> >> right way (or simply not compatible with gevent).
> >>
> >> Can you report the list of modules you are using ?
> >>
> > Attached the output of *pip freeze | sort*, though I doubt this may be of
> > any use. Sorry for lots of stuff in there, I don't use all of these
> > modules
> > directly, but most of it - yes.
> >
> >>
> >> Currently i see this kind of problems with the zookeeper c
> >> implementation
> >> and some older release of the memcached module based on libmemcached.
> >
> >
> > I noticed now, that when i attach with gdb to the running process, I have
> > all these threads blocked in the same "sem_wait" call, except for the
> main
> > thread, which runs gevent.
> >
> > I have dynamic code in the django app, which shows all greenlet's and
> > thread's stacktraces.
> > It seems, all of the threads (not greenlets), except the main one are
> > doing
> > this:
> >
> > # ThreadID: 140100927207168
> > File: "/usr/local/lib/python2.7/dist-packages/gevent/threadpool.py",
> > line 182, in _worker
> >   task = task_queue.get()
> > File: "/usr/local/lib/python2.7/dist-packages/gevent/_threading.py",
> > line 432, in get
> >   self.not_empty.wait()
> > File: "/usr/local/lib/python2.7/dist-packages/gevent/_threading.py",
> > line 148, in wait
> >   waiter.acquire()
> >
> >
> > The amount of threads matches the amount shown in gdb, so it looks like
> > this is correct.
> > I can't find any references to "threadpool" in my code, not sure where
> are
> > these coming from.
> >
> > It's probably worth asking on the gevent mailing list about it, what do
> > you
> > think, Roberto?
> >
> > Thanks!
> >
> >
>
> Well, you have a gazillion of modules :)
>
> you should check for threadpool in any of them
>
> Your problem is pretty annoying because the harakiri cannot save you as no
> request is running during the lock :(
>
> --
> Roberto De Ioris
> http://unbit.it
> _______________________________________________
> uWSGI mailing list
> [email protected]
> http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi
>
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to