Patent ID: 7484209

Claim:
A method for execution by at least one processor, the method comprising: communicating with a first interface to identify classes and selecting at least one method of said classes for instrumentation; installing hooks in the selected at least one method with instrumentation tools, said instrumentation tools reading and writing the classes in order to produce modified classes; inserting instrumentation code in a bytecode representation of the selected at least one method without modifying a source code of the selected at least one method, said hooks enabling said inserting of the instrumentation code; generating a wrapper method with said instrumentation tools that contain the instrumentation code and a call to the bytecode representation of the at least one method, wherein the instrumentation code comprises bytecodes; executing the bytecodes during execution of the at least one method; and generating a call, by the executed bytecodes, to a second interface wherein the call comprises information regarding the instrumented at least one method; wherein generating a wrapper method comprises: renaming the at least one method from an original name to a new name; creating a wrapper method with the original name; inserting bytecodes into the wrapper method that when executed generate the call to the interface; and inserting bytecodes into the wrapper method that when executed call the renamed at least one method.