Restart TG apps for high mem-usage
Yaakov Nemoy
loupgaroublond at gmail.com
Mon Nov 26 05:59:37 UTC 2007
On Nov 26, 2007 12:08 AM, Toshio Kuratomi <a.badger at gmail.com> wrote:
> Yaakov Nemoy wrote:
> > On Nov 25, 2007 4:00 PM, Toshio Kuratomi <a.badger at gmail.com> wrote:
> Not if the app doesn't. From a brief test, TG apps do not do this.
>
> The script is asking supervisor to shutdown the application. supervisor
> sends a TERM to the TG app (we can configure it to send something other
> than TERM if we want but I don't see any documentation that leads me to
> believe it will be different with a HUP or QUIT). At that point it
> looks like a TG app will immediately shutdown and rollback any current
> transactions.
It's got my vote then
> smolt is on shaky ground if it's not using transactions correctly... At
> the beginning of the month when smolt was getting hit hard we did pretty
> much this same thing except manually instead of via a script when we
> noticed that smolt was giving timeouts and taking up 1G+ of RAM. I
> think the current smolt code is using SQLAlchemy, correct? It's pretty
> easy to use transactions so that you don't leave the db in an
> inconsistent state with that configuration. Using the session's
> implicit transaction flushed just before the return should do the safe
> thing. You can look through the code later and find additional places
> where you can safely flush the transaction if there's a need.
We do use transactions where we can, but since most of the code is not
tested at all, let alone stress tested, i can't vouch for it doing The
Right Thing.
(Winter break is only a few weeks away)
-Yaakov
More information about the Fedora-infrastructure-list
mailing list