Hi
I am following this blog and implemented the same workflow which identifies the entity having resource outage, it generate problem by creating event by js code.This event generations is creating problem for the prediction with entity details but that problem is getting closed after minutes automatically. Can somebody please help me to understand why?
Also is there way to add more details to problem like problem description of custom fields and also can we set how long problem should remain problem.
I believe you will need to amend your code to supply the timeout parameter. The default value is 15 minutes unless you specify another value. This will set the timeout value to control how long the event will stay active without being refreshed (up to 6 hours). Please note that you can also keep the problem open by sending the same payload again (such as from a subsequent execution of the workflow).
An error of type UNCAUGHT_EXCEPTION occurred in an imported library: 400: Constraints violated.
at EventsClient.createEvent (file:///opt/sdk_modules/@dynatrace-sdk/client-classic-environment-v2/esm/index.js:8056:17)
at eventLoopTick (ext:core/01_core.js:175:7)
Your amended code passes the paramter dt.davis.timeout within the properties object. This is incorrect per the documentation. The parameter should be passed as ‘timeout’ (excluding quotation marks) in the main section.