Package com.dynatrace.agent.events
Interface EventModifier
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A modifier function that is used to enrich a given event as
JSONObject. It receives context objects depending
on the type of the event or null if no context is available. The returned event can be a modified version of the
event JSON or null if the event should be dropped.- Since:
- 8.303
-
Method Summary
Modifier and TypeMethodDescriptionmodifyEvent(JSONObject event, Object[] eventContext) A modifier function that is used to enrich a given event asJSONObject.
-
Method Details
-
modifyEvent
A modifier function that is used to enrich a given event as
JSONObject.It receives context objects depending on the type of the event or null if no context is available. The returned event can be a modified version of the event JSON or null if the event should be dropped.
Lists the events that Dynatrace monitors and the context parameters that are provided for each event. Event Context parameters Description OkHttp request monitoring (success) [ Request,Response, null]RequestandResponsetypes from OkHttp frameworkOkHttp request monitoring (failed) [ Request, null,Throwable]Requesttype from OkHttp frameworkHttpURLConnection request monitoring null No context provided because information can't be accessed afterwards Dynatrace.sendEvent(JSONObject fields, Object[] eventContext)eventContextValue provided by parameter Manual web request monitoring, identify user, (manual) error reporting null No context defined Crash reporting [ Throwable,Thread]Provides the Threadwhere the crash occursCross-platform events null There is no data type conversion between different languages, so the context object is not defined - Parameters:
event- a deep copy of the current JSON eventeventContext- additional objects that contain contextual information for this event or null if there is none available- Returns:
- the modified event or null if the event should be dropped
-