-
Notifications
You must be signed in to change notification settings - Fork 600
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bin/newrelic collides with newrelic-cli #2240
Comments
I can see how this isn't desirable behavior. I think it might make the most sense for us to rename I'm going to relabel this as an enhancement and mark it for our next major release. Thanks for bringing this to our attention! |
This one impacts us as well, and I'm happy to make these changes and submit a PR. Just wanted to check on how you handle deprecations like this on the project: Would it make sense to leave the existing binstub with a deprecation notice on the renaming for a major release, and then follow up with the removal in a future major version? |
That would be much appreciated, thank you! You've described our ideal deprecation process. Somewhere around the deprecated code, could you add the comment, |
Sounds good! I noticed that there's another older version included in there from a previous rename: https://github.com/newrelic/newrelic-ruby-agent/blob/dev/lib/new_relic/cli/command.rb#L63 Would that one be okay to remove in this PR, or would you like me to leave that one for y'all to manage? It looks like it's been deprecated for quite awhile 😅 |
Hey @dinsley,
Despite the "major version" comment, I think that it is ok for you to go ahead and remove that one. Given what that code does, its age, and the fact that it's outside of public API territory for the agent itself, I support its removal. If anyone ends up wanting to use the old name and the latest agent version, I'll be happy to add it back later. Thanks again for taking a look at it! |
I've opened a PR here as the first step to resolve the name collision: #2307 I did have a question around the general future approach of the deployment notices with the Ruby RPM. It seems like the The CLI can be quite a pain to get installed/working in some environments like Heroku where a custom build pack is required. (but totally doable) Are there any plans to extend the deployment notification portion of the commands here to the new change tracking API that is recommended here? or is the preferred route eventually to do away with having to manage the individual agent implementations of recording deployments/changes? |
Thanks, @dinsley. I have created #2313 to express the need for targetting the new endpoint. We last touched the logic for signaling a deployment with #1461.
I have not seen such a preference formed yet, so we'll plan to update the agent itself to handle the new endpoint until we hear otherwise. We don't want anyone frustrated or confused by deprecation warnings when using the latest version of the agent. If you'd like to add any thoughts to #2313 or submit a PR related to it, we'd absolutely welcome them.
If there's anything we can do in documentation, code within the Ruby agent repo, or code elsewhere (Heroku buildpack, separate smaller tool, executable gist with an md5 sum, etc.), we'd love to explore whatever works best for you. Thanks as always for sharing your experiences - it really helps us better understand and cater to users. |
Awesome, thank you! I'll look at creating a PR for #2313 for this one as it should be pretty straight-forward. For our needs just getting the new change tracking API in place in the agent would be good enough, we don't currently have a huge need for anything else in the CLI at the moment. There's a few pre-existing Heroku build-packs out there for the New Relic CLI tooling (I had prototyped one out awhile ago), but it would be much better to have one maintained officially, as the risk with using build-packs can be quite high if a third-party wants to do some damage. I think it's something that could probably also be offered automatically through the Heroku add-ons API and automatically provisioned through their API (https://devcenter.heroku.com/articles/platform-api-reference#buildpack-installations), for those that are using New Relic that way. Users who have provisioned and set it up manually outside of Heroku's marketplace could just use the same build-pack then too. |
Description
As a user, if I install and use both the newrelic-cli package from homebrew and have an app with the newrelic-ruby-agent, I will experience a collision where I can only use one of these tools unless I directly point to it. Given the tools differ in purpose and available commands, this is highly frustrating. Because the name of the application bin in either package is not configurable, I am specifying this as a "bug" but is maybe more of a change request.
Expected Behavior
I would expect the tools to either be identical packages that provide all functionality, or for one to be name spaced so I can specify which one to use without typing a full path.
Steps to Reproduce
brew install newrelic-cli
gem install newrelic_rpm
newrelic apm nrql query--format Text --query 'FROM Log SELECT err.name,err.message WHERE name=\'federated-graphql\' AND syslog.structured.data LIKE \'[containerName=ecs-federated-graphql-staging-%]\''
Your Environment
The text was updated successfully, but these errors were encountered: