Alerting
Questions about alerting and problem detection in Dynatrace.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Getting started with custom deployment events

eric_h
Newcomer

I would like to start using the Events API (v2) to post CUSTOM_DEPLOYMENT events to Dynatrace, from our CI/CD pipelines. The ultimate goal is to add this information to Dynatrace so it's useful to Davis and users to correlate deployments with issues that occur.

I am having difficulty with a couple of things, though.

1) How do I use the entitySelector? I see various examples, e.g. Events API v2 - POST an event — Dynatrace Docs, but I cannot find a good explanation of how to use it. In our case, our apps mostly run on Azure VM Scale Sets. So maybe I could use this to associate the Scale Set (I do know the scale set name during the deployment). If so, what would be the syntax for the entitySelector be?

2) Is there any other good way to associate the deployment with other things in Dynatrace? For instance, we tag a lot of objects in Dynatrace. Could I somehow "tag" this custom event as well? If so, how exactly would I do so?

1 REPLY 1

Julius_Loman
DynaMight Legend
DynaMight Legend

@eric_h there can be many entities in Dynatrace, with entitySelector you can select entities of one type and not just for tagging.

Typically, you want to send deployment events to process groups, but it's not limited to a particular entity. For sending events, please rember a single entitySelector can select just entities of a single type. You need to call the postEvent API endpoint multiple types with different entitySelector for sending events to different types.

See an example here also have a look at the following video - Unleash the power of Events APIv2 – Integrate your DevOps Tools.
 

Dynatrace Ambassador | Alanata a.s., Slovakia, Dynatrace Master Partner
How to Reduce MTTR (Mean Time to Repair), Improve Collaboration between app support and development, and Automate Release Validation are the three key takeaways of this observability clinic. Learn from Arijan (AJ) Zenuni, Technical Product Specialist at #Dynatrace, how to integrate Dynatrace with

Featured Posts