newrelic / deployment-marker-action

Github Action for recording a Deployment Marker in New Relic
https://github.com/marketplace/actions/new-relic-application-deployment-marker
Apache License 2.0
58 stars 23 forks source link

Question or feature request: Why we can't use service name instead of GUID? #58

Open vitalykarasik opened 5 months ago

vitalykarasik commented 5 months ago

The action requests "The entity GUID to apply the deployment marker" for each deploy event. It means I have to collect a list of GUIDs for all services across all environments and use them in my workflow.

But we already have a 'service name' in both NewRelic and GH workflow. So why don't use it instead of GUID for calling this action?

oleksandr-kinship commented 1 week ago

@vitalykarasik have you got any answer? have the same question, +1

vitalykarasik commented 1 week ago

@vitalykarasik have you got any answer? have the same question, +1

@oleksandr-kinship unfortunately, no. I'm just adding GUID for each service into its CI/CD workflow - hardcoded :-(

oleksandr-kinship commented 1 week ago

@vitalykarasik have you got any answer? have the same question, +1

@oleksandr-kinship unfortunately, no. I'm just adding GUID for each service into its CI/CD workflow - hardcoded :-(

That upset to have to use antipatterns. Thanks. for quick answer!

oleksandr-kinship commented 6 days ago

Hello @vitalykarasik, bit think about how it could be integrated without minimal hardcode for big amount of applications, so I think I have found the most straightforward solution - write reusable action that will call NR api to get guid first, then use this output in deployment marker arguments. As base for get_uid can be used this action, just use another cli call

newrelic apm application search \
            --name ${NEW_RELIC_APM_NAME}

then this possible to grep/jq guid from response.