Fixed crash on stats API
Modified the event analyzer code as per new updated design. Untested code in stomp handler