Forgot to add:
Use sender code set and sender code id to restrict the events from this logic. If use *, the event will hit pre-processing FM and it doesn't matter who is reporting the event. For example, if you manually report from TM document, it still goes through the pre-processing logic which is not required.
Thanks,
Vishnu