There is a feature of Dynatrace Appmon for marking transaction as error error when ERROR.* expression appears in log. This configurable in Dynatrace for each System Profile. See screenshot attached. As current and Default setting is count the transaction as error when ERROR.* expression appears in log4j log. If you see the response code of each web service request, it is 200 - OK. (See below screenshot). This means, application is writing log as ERROR for exception raised but as this exception is handled, transaction is completing successfully and actually not failing.
Due to writing ERROR log message by application, Dynatrace is marking transaction as error but actually there is no issue as Error is handling by application but logging the ERROR message for audit. Same time we can fix this issue by simply removing ERROR.*| from configuration for System profile but this will apply to all where even exception is not handled.
Please suggest what is solution of this issue?
Logging with level ERROR, FATAL, SEVERE should be reserved for errors and failures. Consider adjusting the log level for non-impacting exceptions with level WARNING or INFO.
In addition, the built in error detection rules in AppMon mark a transaction as having errors, but not as failed. So it acknowledges that the transaction completed successfully, but it had errors (which it did). So, in my opinion, this works as expected.
That being said, if you still want to alter the error detection in AppMon, you could filter out this particular logger by name and message. So in the existing logging rule, just enable the two check-marks for logger name and message and set them to "Not equals" or "Not regex" and set the fields to something matching just this particular logger.
Thanks for suggestion! I got message from created support ticket as well (see below) and solved my issue.
"If you don't want to include specific error message, then you may enable "Log Message" in "Condition" settings, and set "not regex" rule to exclude such message"