Remove NEWRELIC_DISPATCHER env variable #822
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
It looks like this environment variable was originally added in 2012 to get the newrelic_rpm gem to automatically start. Since then, built-in methods for discovering the dispatcher in an environment were added (see here generally, and this commit for adding dispatcher detection for Puma specifically). As a result, I think this environment variable no longer needs to be set in Puma.
There was a change by @tomohiro merged to Puma a few months ago that changed this variable from
puma
toPuma
because something had stopped working with Rails 4.2 + New Relic + Heroku. I think that may have in response to this change that stopped reporting from the Puma master process--I set up a quick test of Rails 4.2 + New Relic + Heroku with the variable aspuma
instead ofPuma
and that appeared to successfully report data to New Relic, but I'm happy to investigate further if there was another issue going on with the harvest thread auto-starting logic. Overall though, it seems like this should be issue that we fix in newrelic_rpm and not in Puma :)