From: Devin Ben-Hur <dbenhur@whitepages.com>
To: unicorn list <mongrel-unicorn@rubyforge.org>
Cc: "Yeung, Jeffrey" <Jeffrey.Yeung@polycom.com>
Subject: Re: Unicorn_rails ignores USR2 signal
Date: Tue, 20 Mar 2012 19:27:41 -0700 [thread overview]
Message-ID: <4F693C9D.7020702@whitepages.com> (raw)
In-Reply-To: <E8D9E7CCC2621343A0A3BB45E8DEDFA91C6869D9F3@CRPMBOXPRD04.polycom.com>
On 3/20/12 4:09 PM, Yeung, Jeffrey wrote:
> I have been unable to narrow down the cause of the conflict so far. The list of Ruby gems (and gem versions) on the affected deployment are identical to the ones on another deployment where Unicorn is upgrading just fine (with preloaded app). Grep'ing for USR2 in the gem installations did not reveal anything, unfortunately. Since then, I haven't been able to spend further time investigating. Not sure where else to look, really, but I'm open to further suggestions.
Jeffery,
To uncover the culprit, you might try monkey-patching Kernel.trap and
Signal.trap so it logs the last few entries in caller when it's called
with USR2.
Put something like this really early in you app bootstrap:
[Kernel,Signal].each |klass|
class << klass
alias :orig_trap :trap
def trap *args, &block
if args.first.to_s =~ /USR2$/i || args.first.to_i == 31
$stderr.puts "Caught someone trapping USR2 caller is:",
caller.last(2)
end
orig_trap *args, &block
end
end
end
_______________________________________________
Unicorn mailing list - mongrel-unicorn@rubyforge.org
http://rubyforge.org/mailman/listinfo/mongrel-unicorn
Do not quote signatures (like this one) or top post when replying
next prev parent reply other threads:[~2012-03-21 2:42 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-09 21:48 Unicorn_rails ignores USR2 signal Yeung, Jeffrey
2012-03-09 22:24 ` Eric Wong
2012-03-09 22:39 ` Yeung, Jeffrey
2012-03-10 0:02 ` Eric Wong
2012-03-10 1:07 ` Yeung, Jeffrey
2012-03-10 1:30 ` Eric Wong
2012-03-12 21:21 ` Eric Wong
2012-03-12 22:39 ` Yeung, Jeffrey
2012-03-12 22:44 ` Eric Wong
2012-03-20 19:57 ` Eric Wong
2012-03-20 23:09 ` Yeung, Jeffrey
2012-03-21 2:27 ` Devin Ben-Hur [this message]
2012-03-30 22:16 ` Yeung, Jeffrey
2012-03-30 22:51 ` Alex Sharp
2013-05-08 18:15 ` Ryan Jones (RyanonRails)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://yhbt.net/unicorn/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F693C9D.7020702@whitepages.com \
--to=dbenhur@whitepages.com \
--cc=Jeffrey.Yeung@polycom.com \
--cc=mongrel-unicorn@rubyforge.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhbt.net/unicorn.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).