Crashing .psgi is not logged (with --preload-app) #65

Open
karenetheridge opened this Issue Apr 1, 2013 · 3 comments

Comments

Projects
None yet
2 participants
@karenetheridge

Reproduction steps:

create app.psgi containing:

my $app = die 'this app cannot be created!';

then:

starman --preload-app --error-log error.log app.psgi

The error log does not capture any details about the death (indeed it is totally empty). It should be obvious in the log that the app crashed, but it is not.

I'm not sure if this is really an issue with Plack::Runner or Net::Server::* ? Just doing plackup app.psgi properly dumps the error to the console.

@karenetheridge

This comment has been minimized.

Show comment Hide comment
@karenetheridge

karenetheridge Apr 1, 2013

closing as I cannot reproduce exactly what I saw on production -- my situation was that the app.psgi contained Foo->new->to_app, but the object died during instantiation -- and start_server was in front of starman. I saw nothing at all in the error.log - the process was repeatedly dying and being restarted with no diagnostics at all.

closing as I cannot reproduce exactly what I saw on production -- my situation was that the app.psgi contained Foo->new->to_app, but the object died during instantiation -- and start_server was in front of starman. I saw nothing at all in the error.log - the process was repeatedly dying and being restarted with no diagnostics at all.

@karenetheridge karenetheridge reopened this Apr 1, 2013

@karenetheridge

This comment has been minimized.

Show comment Hide comment
@karenetheridge

karenetheridge Apr 1, 2013

reopening, now that I've got a reliable repro case -- the error is logged only if --preload-app is not used.

When --preload-app is included, there is an error to the console but not to the error log. When start_server is put in front of starman, the console output is not captured anywhere, so there is now no information indicating the source of the error (and it's not even that obvious that the app is continually being restarted/crashed/restarted).

reopening, now that I've got a reliable repro case -- the error is logged only if --preload-app is not used.

When --preload-app is included, there is an error to the console but not to the error log. When start_server is put in front of starman, the console output is not captured anywhere, so there is now no information indicating the source of the error (and it's not even that obvious that the app is continually being restarted/crashed/restarted).

@autarch

This comment has been minimized.

Show comment Hide comment
@autarch

autarch Jul 8, 2013

I'm seeing a related problem where a child will segfault and we get no notice of that whatsoever, whether or not --preload-app is enabled. I'm going to look into this further and see if I can come up with a fix. We've had various problems with Starman's logging in the past and I'd really like to make it more robust.

autarch commented Jul 8, 2013

I'm seeing a related problem where a child will segfault and we get no notice of that whatsoever, whether or not --preload-app is enabled. I'm going to look into this further and see if I can come up with a fix. We've had various problems with Starman's logging in the past and I'd really like to make it more robust.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment