24 May 2022 11:10 AM
When a process needs restarting for injection to complete, there's no way of us knowing until we manually check via the UI or an API call. Is there a way to alert on this issue so we know when processes are not correctly monitored.
Solved! Go to Solution.
24 May 2022 12:53 PM
hi, I'd be very interested to know how to find this out, by pure coincidence we've noticed this issue on a couple of processes - See below
Process isn't monitored
Process is ready to be monitored, waiting for injection status...
If there is some way to be informed of this status, I would appreciate it.
24 May 2022 01:35 PM
Hi @Kulraj_Atwal,
You can check your processes that need to be restart with Processes API - GET all processes which returns under MonitoringState a Boolean element called restartRequired.
You can set alert into dynatrace with Events API v2 - POST an event
In order to run it automatically every minute you can create Active Gate extension (v1).
HTH
Yos
24 May 2022 01:58 PM
Problem with that is that (apart from creating the extension) is that it also shows true for processes that are injected but need a restart due to the agent being updated.
24 May 2022 02:28 PM
Good point @Kulraj_Atwal
To eliminate those you can check if the agent version of the process instance is different then the one on the host. 🙄
HTH
Yos
24 May 2022 02:58 PM
Thanks @Yosi_Neuman, worst case we may have to develop that solution.
Although being as we pay Dynatrace so much i was hoping they might develop something we can all use to alert on it ootb 🙂
25 May 2022 04:50 PM
Please check the attached AG extension.
** Please be aware that its a quick and dirty one ,which checked only on sand box environment **
It browses all processes and if there is a a process marked as restartRequired its look for the Host OA version and compere it with the process OA version, if the versions are not equals CUSTOM_ALERT is set with 'Need to restart' message, if the version are equals AVAILABILITY_EVENT is set with 'Must restart" message.
Both events are set for 2 minutes timeout so it will close automatically after restartRequired is change to False.
Here is one problem open after upgrading OA and not restating the Outlook
HTH
Yos
26 May 2022 06:43 PM
Thanks @Yosi_Neuman i will have a look at this and report back.
21 Dec 2023 03:24 AM
Hi @Yosi_Neuman ,
I tested your .py file. It ran but showed no results. Can you let me know if the results of running the tool will produce any report files?
Thank you for your help.
21 Dec 2023 07:49 AM
Hi @CuongNTM
The attached zip file was made to be load and run as ActiveGate extension which will run the code every minute and open CUSTOM_ALERT or AVAILABILITY_EVENT which will generate a problem.
You can collect information about all the problems with Rest API to a different tool and produce a report from the pulled data.
Another way to tackle your need can be with the /monitoringstate API @Julius_Loman mentioned
HTH
Yos
21 Dec 2023 08:03 AM
Hi @Yosi_Neuman ,
Thank you for your help. I will learn more about what you mentioned. If there is a more useful tool, can you recommend it to me?
21 Dec 2023 08:23 AM
Hi @CuongNTM
Don't think right now there is another way to do that
Yos
25 May 2022 09:26 AM
How would you work with this status below?
Process isn't monitored
Process is ready to be monitored, waiting for injection status...
Is there any way to list only these processes via API and create an alert for them?
25 May 2022 10:45 AM
IMO Its a combination of expectedMonitoringState and actualMonitoringState elements under monitoringState
Process isn't monitored = expectedMonitoringState = OFF
Process is ready to be monitored, waiting for injection status = actualMonitoringState = OFF & expectedMonitoringState = ON
HTH
Yos
30 Aug 2022 11:35 AM
Hi @Yosi_Neuman,
This is a good suggestion however the process/topology api is deprecated and to be replaced by the v2 entity api. The v2 entity api does not return those properties when you query processes so unless the v2 api is changed this solution isn't viable.
Thanks
Jack
30 Aug 2022 12:21 PM
Hi @Jack_Stuart
Process API is not listed (yet) as deprecated one in Deprecated APIs
IMO its still OK to use it till Entity API will show also this information.
Yos
30 Aug 2022 12:51 PM
Thanks @Yosi_Neuman. My bad, I misinterpreted the yellow banner. Do you have any suggestions on how we would use the entity api to show the information? it doesn't look to get returned in the entities properties.
30 Aug 2022 02:36 PM
Hi @Jack_Stuart
Sorry, as you noticed I also did not find a way to get this information, regarding the state of the process, from entity api. 🙄
Yos
26 May 2022 05:18 AM
Alerts on availability using the alerting profiles.
26 May 2022 10:49 AM
Yeah those 2 links dont answer my question, thanks though 🙂
30 Aug 2022 01:07 PM
Is there any way to list only these processes via API and create an alert for them?
Process isn't monitored
Process is ready to be monitored, waiting for injection status...
Any tips how to do it?
30 Aug 2022 02:26 PM
Please look at my answer below its includes an active gate extension that you can play with and change in order to get what you are looking for.
HTH
Yos
16 Apr 2023 04:21 PM - edited 16 Apr 2023 04:44 PM
@jiri_stefanek / @Yosi_Neuman there is a new API (/monitoringstate) which, I guess, will replace the legacy process groups API v1 for querying the states. I guess it still needs some improvements, but it looks promising.
16 Apr 2023 04:48 PM
This is what happens when dynatrace is keep evolving all the time
In other words: The enemy of the good is better
Thanks @Julius_Loman !!
Yos
03 Apr 2024 09:46 PM
Has there been any out of the box development on tracking process needing restart for injection to complete? Do we still need to build a custom extension to monitor this or has there been a dynatrace app built to do just that? Thanks.