protected void activate ( ) throws Exception { // If the ProbeProxy class is available, check it's version String runtimeVersion = getRuntimeClassVersion ( ) ; if ( runtimeVersion != null && ! runtimeVersion . equals ( getCurrentVersion ( ) ) ) { // TODO: Use a compatibility check instead throw new IllegalStateException ( "Incompatible proxy code (version " + runtimeVersion + ")" ) ; } // Find or create the proxy jar if the runtime code isn't loaded if ( runtimeVersion == null ) { JarFile proxyJar = getBootProxyJarIfCurrent ( ) ; if ( proxyJar == null ) { proxyJar = createBootProxyJar ( ) ; } instrumentation . appendToBootstrapClassLoaderSearch ( proxyJar ) ; } // Hook up the proxies activateProbeProxyTarget ( ) ; activateClassAvailableProxyTarget ( ) ; }
Activate this declarative services component . Bundles that are currently active will be examined for monitoring metadata and registered as appropriate .