Rare Earth Juejin Tech Community
Aug 7, 2024 · Backend Development
Understanding and Implementing JavaAgent for Runtime Instrumentation
This article explains the concept, architecture, and practical implementation of JavaAgent for Java runtime instrumentation, covering its role, premain method, ClassFileTransformer usage, bytecode manipulation with ASM or Javassist, and step‑by‑step guidance to build, package, and attach a JavaAgent for method execution time monitoring.
BytecodeClassFileTransformerInstrumentation
0 likes · 10 min read