what is the harm/impact of singleton exception in Log file for Activity-End
we are getting below exception while using Activity-End in Pega 7.1.6. Is there any harm or impact on system because of this exception?
com.pega.pegarules.pub.runtime.ActivityTerminateException: This is a singleton exception object and the stack trace below does NOT reflect the actual point of failure. To see the actual trace, set Initialization/UniqueActivityTerminateExceptions = true at com.pega.pegarules.session.internal.mgmt.Executable.<clinit>(Executable.java:441) at com.pega.pegarules.session.internal.PRSessionProviderImpl.getExecutableInstance(PRSessionProviderImpl.java:1744) at com.pega.pegarules.generation.internal.cache.appcentric.RACacheAppCentricImpl.reloadCache(RACacheAppCentricImpl.java:1762) at .................
See SA-34920. The Activity-End throws an exception, and activities are not intended to throw exceptions. The error you are seeing is a mild complaint about that. As you don't want your application to depend upon invalid operations, see if you can find some other way to abort things.
Instead of doing an activity-end, could you make the last step in the activity be an error step and then jump to there? The exception itself shouldn't have any major impact, but it will clutter your logs. If you want to log the failure, you could add a log statement on your error step. That would make it more meaningful.
Activity-end is rather heavy-handed, as it aborts all levels of activities, and if you are at all unsure about the activities that called yours, it is safer to use exit-activity instead, and design your calling activity detect via the status (see StepStatusFail and related documentation) that your called activity encountered an issue.