Interrupting download of process_bug.cgi

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Interrupting download of process_bug.cgi

M Cowperthwaite
Let's say I make a modification to a bug that has a very large CC list.
If I hit the back-button in my browser while Bugzilla is generating the
list of recipients of bugmail, is that going to interrupt the
notification process?  I would assume it won't, but for years I've been
waiting until the entire list is displayed, in case I'm assuming wrong.

--
Michael Cowperthwaite

To send mail, remove 'Z's from the poster's email address.
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Interrupting download of process_bug.cgi

Max Kanat-Alexander
On Fri, 2005-05-20 at 10:23 -0500, M Cowperthwaite wrote:
> Let's say I make a modification to a bug that has a very large CC list.
> If I hit the back-button in my browser while Bugzilla is generating the
> list of recipients of bugmail, is that going to interrupt the
> notification process?  I would assume it won't, but for years I've been
> waiting until the entire list is displayed, in case I'm assuming wrong.

        Well, to be honest... it's not *supposed* to interrupt anything when
you close your browser. We have some code in Bugzilla specifically to
make things work that way.

        However, on bugzilla.mozilla.org, I've still seen some times where
process_bug didn't send out all email if I closed the browser. We're not
quite sure what causes it.

        So, to be safe, I always leave the window open until it's done.

        -Max
--
http://www.everythingsolved.com/
Everything Solved: Experts at Bugzilla... and everything else, too.

_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Interrupting download of process_bug.cgi

Dave Miller
Max Kanat-Alexander wrote:

> On Fri, 2005-05-20 at 10:23 -0500, M Cowperthwaite wrote:
>
>>Let's say I make a modification to a bug that has a very large CC list.
>>If I hit the back-button in my browser while Bugzilla is generating the
>>list of recipients of bugmail, is that going to interrupt the
>>notification process?  I would assume it won't, but for years I've been
>>waiting until the entire list is displayed, in case I'm assuming wrong.
>
> Well, to be honest... it's not *supposed* to interrupt anything when
> you close your browser. We have some code in Bugzilla specifically to
> make things work that way.
>
> However, on bugzilla.mozilla.org, I've still seen some times where
> process_bug didn't send out all email if I closed the browser. We're not
> quite sure what causes it.

Actually, we did figure it out recently...  a couple years ago a change
was checked into apache to make CGI reaping more efficient...  and if
your process doesn't exit within 3 seconds of the SIGTERM (which we're
watching for and ignoring in order to finish the process_bug first), it
sends a SIGKILL (which we have no way to override).

So the short answer is yes, if you close the browser window, or
otherwise abort the connection, the notification process dies if it
doesn't finish within three seconds.

Our best fix for this is to get the notification moved into a separate
process instead of doing it while the user waits.  Hopefully we'll get
it doing that eventually.

--
Dave Miller                                   http://www.justdave.net/
System Administrator, Mozilla Foundation       http://www.mozilla.org/
Project Leader, Bugzilla Bug Tracking System  http://www.bugzilla.org/
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Interrupting download of process_bug.cgi

Joel Peshkin
In reply to this post by Max Kanat-Alexander
David Miller wrote:

>
> Actually, we did figure it out recently...  a couple years ago a change
> was checked into apache to make CGI reaping more efficient...  and if
> your process doesn't exit within 3 seconds of the SIGTERM (which we're
> watching for and ignoring in order to finish the process_bug first), it
> sends a SIGKILL (which we have no way to override).
>
> So the short answer is yes, if you close the browser window, or
> otherwise abort the connection, the notification process dies if it
> doesn't finish within three seconds.
>
> Our best fix for this is to get the notification moved into a separate
> process instead of doing it while the user waits.  Hopefully we'll get
> it doing that eventually.
>

Why not react to SIGTERM by forking and having the child close STDIN and
let the parent exit before the SIGKILL happens?
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools
Reply | Threaded
Open this post in threaded view
|

Re: Interrupting download of process_bug.cgi

Dave Miller
Joel Peshkin wrote:

> David Miller wrote:
>
>> So the short answer is yes, if you close the browser window, or
>> otherwise abort the connection, the notification process dies if it
>> doesn't finish within three seconds.
>>
>> Our best fix for this is to get the notification moved into a separate
>> process instead of doing it while the user waits.  Hopefully we'll get
>> it doing that eventually.
>
> Why not react to SIGTERM by forking and having the child close STDIN and
> let the parent exit before the SIGKILL happens?

Because we support Windows now, and you can't do that on Windows. ;)

--
Dave Miller                                   http://www.justdave.net/
System Administrator, Mozilla Foundation       http://www.mozilla.org/
Project Leader, Bugzilla Bug Tracking System  http://www.bugzilla.org/
_______________________________________________
mozilla-webtools mailing list
[hidden email]
http://mail.mozilla.org/listinfo/mozilla-webtools