On 27 feb, 07:03, Rama <[email protected]> wrote:
> On 10 feb, 21:24, Carlos Daniel Ruvalcaba Valenzuela
>
> <[email protected]> wrote:
> > You could try setting threading off unless you spaw threads on your tg
> > app, uwsgi does not make use of threads in your config and test if
> > that helps.
>
> > Also what version of uwsgi are you using? there seems to be problems
> > with 1.0.3 I think, it would be useful to cross post this to the uwsgi
> > list. Although this seems to be a db connectivity related problem too.
>
> One more thing, I have a concern as before the 'out of sync' error,
> there is another exception showing up
> which says 'SQLObjectNotFound: The object Visit by the ID 0 does not
> exist'.
>
> Full backtrace here:
>
> http://dpaste.com/708425/
>
> Could that have something to do?
>
> Rama

Hello people, I've finally solved all my issues with help from the
uWSGI crew.

Just for the record: the solution to have multiple processes is to
enable lazy workers startup.

Paste from uwsgi reply:

---cut---
It is a bit of time i do not use SQLObject, but i bet it is not
copy-on-write frindly. Add

lazy = true

in your config.

In such a way, your app will be initialized after each worker spawn
(and
not before and then copied)
---cut---

Additionally, I've added:

max-requests = 3000

in order to recycle workers after uwsgi has served 3000 requests, as
it seems to consume memory without releasing it otherwise.

Everything looks to be working perfectly fine now.

Infinite thanks for all your help!
Rama

-- 
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en.

Reply via email to