move JVMTI event handling into separate file