protected void addInstrumentation(BundleContext context) { ClassAdapterFactory factory = new BundleContextAdaptorFactory(); TransparencyClassSpec spec = configHelper.getOrCreateSpec("org.eclipse.osgi.framework.internal.core.BundleContextImpl"); spec.setCustomClassAdapter(factory); // Initialize and add the EquinoxFWClassLoader Factory Adaptor TransparencyClassSpec equinoxFwClassLoaderSpec = configHelper.getOrCreateSpec("org.eclipse.osgi.launch.Equinox"); ClassAdapterFactory equinoxClassLoaderFactory = new EquinoxFWClassloaderAdaptorFactory(); equinoxFwClassLoaderSpec.addCustomClassAdapter(equinoxClassLoaderFactory); ClassAdapterFactory baseDataAdaptorFactory = new BaseDataAdaptorFactory(); TransparencyClassSpec baseDataClassSpec = configHelper.getOrCreateSpec("org.eclipse.osgi.baseadaptor.BaseData"); baseDataClassSpec.setCustomClassAdapter(baseDataAdaptorFactory); } }
@Override protected void addInstrumentation(BundleContext context) { super.addInstrumentation(context); configHelper.addCustomAdapter("org.springframework.webflow.mvc.view.AbstractMvcView", AbstractMvcViewAdapter.FACTORY); }
configHelper.addIncludePattern("org.hibernate.cache.EhCache", false, false, false); configHelper.addIncludePattern("org.hibernate.cache.CacheKey", false, false, false); configHelper.addIncludePattern("org.hibernate.cache.EhCacheProvider", false, false, false); configHelper.addIncludePattern("org.hibernate.EntityMode", false, false, false); configHelper.addIncludePattern("org.hibernate.type.IntegerType", false, false, false); configHelper.addIncludePattern("org.hibernate.type.PrimitiveType", false, false, false); configHelper.addIncludePattern("org.hibernate.type.ImmutableType", false, false, false); configHelper.addIncludePattern("org.hibernate.type.NullableType", false, false, false); configHelper.addIncludePattern("org.hibernate.type.AbstractType", false, false, false); spec = configHelper.getOrCreateSpec("org.hibernate.cache.EhCache"); spec.addCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.cache.EhCacheProvider"); spec.addCustomClassAdapter(factory); configHelper.addExcludePattern("org.hibernate.engine.Cascade"); configHelper.addExcludePattern("org.hibernate.tuple.entity.AbstractEntityTuplizer"); configHelper.addExcludePattern("org.hibernate.engine.TwoPhaseLoad"); configHelper.addIncludePattern("org.hibernate.cache.ReadWriteCache", false, false, false); configHelper.addIncludePattern("org.hibernate.cache.ReadWriteCache$Item", false, false, false); configHelper.addIncludePattern("org.hibernate.cache.ReadWriteCache$Lock", false, false, false); configHelper .addAutolock("* org.hibernate.cache.ReadWriteCache$Lock.*(..)", ConfigLockLevel.AUTO_SYNCHRONIZED_WRITE); configHelper.addIncludePattern("org.hibernate.cache.entry.CacheEntry", false, false, false); configHelper.addIncludePattern("org.hibernate.cache.entry.CollectionCacheEntry", false, false, false);
private void instrumentFastHashMap() { configHelper.addIncludePattern("org.hibernate.util.FastHashMap"); // FastHashMap read methods are unsynchronized, so need to autosynchronize configHelper.addAutolock("* org.hibernate.util.FastHashMap.*(..)", ConfigLockLevel.AUTO_SYNCHRONIZED_READ); // FastHashMap write methods are synchronized, only need to be autolocked. configHelper.addAutolock("* org.hibernate.util.FastHashMap.clear(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.hibernate.util.FastHashMap.put(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.hibernate.util.FastHashMap.putAll(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.hibernate.util.FastHashMap.remove(..)", ConfigLockLevel.WRITE); }
protected void addInstrumentation(final BundleContext context) { TransparencyClassSpec spec = configHelper.getOrCreateSpec("org.terracotta.searchable.SearchableMapImpl","com.tc.object.applicator.PartialHashMapApplicator"); TransparencyClassSpec tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.PartialHashMapApplicator"); spec.moveToLogical(tableSpec); spec = configHelper.getOrCreateSpec("org.terracotta.searchable.AbstractSearchableMapImpl", "com.tc.object.applicator.SearchableMapApplicator"); spec = configHelper.getOrCreateSpec("org.terracotta.modules.searchable.eviction.TimeStampEntryMap"); tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.HashMapApplicator"); spec.moveToLogical(tableSpec); configHelper.getOrCreateSpec("org.terracotta.searchable.SmapManagement"); configHelper.getOrCreateSpec("org.terracotta.searchable.indexxfer.SMapClusteraware"); configHelper.addAutolock("* org.terracotta.searchable.serialization.ObjectStreamClassSerializer.getMappingFor(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.terracotta.searchable.AbstractSearchableMapImpl.buildDataStoreFromL2(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.terracotta.searchable.AbstractSearchableMapImpl.clear(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.terracotta.searchable.SearchableMapFactory.getOrCreateSearchableMap(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.terracotta.searchable.SearchableMapFactory.getSearchableMap(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* org.terracotta.searchable.SearchableMapFactory.getMapInfo(..)", ConfigLockLevel.READ); configHelper.addRoot("SearchableMapFactory", "org.terracotta.searchable.SearchableMapFactory.instance"); configHelper.getOrCreateSpec("org.terracotta.searchable.SearchMapInfo"); spec = configHelper.getOrCreateSpec("org.terracotta.modules.searchable.eviction.TimeStampInfo"); spec.setHonorTransient(true); configHelper.getOrCreateSpec("org.terracotta.modules.searchable.eviction.TimeStampEntry"); configHelper.getOrCreateSpec("org.terracotta.searchable.config.DefaultEvictionConfigImpl"); spec = configHelper.getOrCreateSpec("org.terracotta.searchable.config.DataStoreConfiguration"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.searchable.config.SearchableMapConfig"); spec.setHonorTransient(true);
configHelper.addCustomAdapter("org.terracotta.cache.TimestampedValue", new TimestampedValueAdapter()); configHelper.getOrCreateSpec("org.terracotta.coordination.CyclicBarrier"); configHelper.addWriteAutolock("* org.terracotta.coordination.CyclicBarrier.*(..)"); spec = configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedMap"); spec.addCustomClassAdapter(new NotClearableAdapter()); spec.addCustomClassAdapter(new TCMapAdapter()); configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedSet"); spec = configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ConcurrentDistributedMapDsoArray"); spec.setHonorTransient(true); spec.setCallMethodOnLoad("onLoad"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ConcurrentDistributedMapDso$TcmEntry"); spec = configHelper.getOrCreateSpec(ConcurrentDistributedMapDsoApplicator.CDM_DSO, ConcurrentDistributedMapDsoApplicator.CDM_DSO_APPLICATOR); spec.setUseNonDefaultConstructor(true); spec = configHelper.getOrCreateSpec("org.terracotta.collections.quartz.DistributedSortedSet"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.collections.quartz.DistributedSortedSet$Storage"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.cache.TerracottaDistributedCache"); spec.addCustomClassAdapter(new NotClearableAdapter()); spec.setPostCreateMethod("startEviction");
configHelper.addAutoLockExcludePattern("* com.tcclient.cache.CacheData.*(..)"); configHelper.addAutoLockExcludePattern("* com.tcclient.cache.CacheDataStore.*(..)"); configHelper.addAutoLockExcludePattern("* com.tcclient.cache.Lock.*(..)"); configHelper.addAutoLockExcludePattern("* com.tcclient.cache.Timestamp.*(..)"); configHelper.addAutoLockExcludePattern("* com.tcclient.ehcache..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.store.TimeExpiryMemoryStore.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.store.TimeExpiryMemoryStore$SpoolingTimeExpiryMap.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.Cache.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.Ehcache.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.Statistics.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.Status.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.bootstrap.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.config.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.constructs.asynchronous.*.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.constructs.blocking.*.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.constructs.concurrent.ConcurrencyUtil.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.constructs.concurrent.Sync.*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.distribution.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.event.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.hibernate.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.jcache.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.management.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.store.*..*(..)"); configHelper.addAutoLockExcludePattern("* net.sf.ehcache.util.*..*(..)"); configHelper.addAutolock("* net.sf.ehcache.constructs.concurrent.Mutex.acquire(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* net.sf.ehcache.constructs.concurrent.Mutex.attempt(..)", ConfigLockLevel.WRITE); configHelper.addAutolock("* net.sf.ehcache.constructs.concurrent.Mutex.release(..)", ConfigLockLevel.WRITE);
configHelper.addAutolock("* java.util.Collections$SynchronizedList.*(..)", ConfigLockLevel.WRITE); .getOrCreateSpec("com.ibatis.sqlmap.engine.mapping.result.loader.EnhancedLazyResultLoader$EnhancedLazyResultLoaderImpl"); configHelper .addAutolock( "* com.ibatis.sqlmap.engine.mapping.result.loader.EnhancedLazyResultLoader$EnhancedLazyResultLoaderImpl.loadObject(..)", ConfigLockLevel.WRITE); spec = configHelper.getOrCreateSpec(SQLException.class.getName()); spec.markPreInstrumented(); spec = configHelper.getOrCreateSpec("com.ibatis.sqlmap.engine.impl.SqlMapExecutorDelegate"); spec = configHelper.getOrCreateSpec("com.ibatis.sqlmap.engine.impl.SqlMapClientImpl"); spec.setCallConstructorOnLoad(true); spec.addTransient("localSqlMapSession"); configHelper.addIncludePattern("com.ibatis.sqlmap.engine.execution.SqlExecutor", false, false, false); spec = configHelper.getOrCreateSpec("com.ibatis.common.jdbc.SimpleDataSource"); spec.setCallConstructorOnLoad(true); spec.setCustomClassAdapter(factory); spec.addTransient("activeConnections"); spec.addTransient("idleConnections"); configHelper.addAutolock("* com.ibatis.common.jdbc.SimpleDataSource.*(..)", ConfigLockLevel.WRITE); configHelper.addIncludePattern("com.ibatis.sqlmap.engine.transaction.jdbc.JdbcTransactionConfig", false, false, false); configHelper.addIncludePattern("com.ibatis.sqlmap.engine.transaction.BaseTransactionConfig", false, false, false);
addExportedTcJarClass("com.tc.util.concurrent.CircularLossyQueue"); configHelper.addCustomAdapter("org.hibernate.impl.SessionFactoryImpl", SessionFactoryImplClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.stat.StatisticsImpl", StatisticsImplClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.event.def.DefaultLoadEventListener", DefaultLoadEventListenerClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.event.def.DefaultInitializeCollectionEventListener", DefaultInitializeCollectionEventListenerClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.persister.collection.AbstractCollectionPersister", AbstractCollectionPersisterClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.stat.TerracottaSecondLevelCacheStatistics_V32", TerracottaSecondLevelCacheStatisticsClassAdapter.FACTORY); configHelper.addCustomAdapter("org.hibernate.stat.TerracottaSecondLevelCacheStatistics_V33", TerracottaSecondLevelCacheStatisticsClassAdapter.FACTORY); configHelper.addCustomAdapter("org.terracotta.modules.hibernate.concurrency.stat.ConcurrentStatisticsImpl", ConcurrentStatisticsImplClassAdapter.FACTORY); .addCustomAdapter("org.terracotta.modules.hibernate.concurrency.stat.ConcurrentSecondLevelCacheStatistics", ConcurrentSecondLevelCacheStatisticsClassAdapter.FACTORY); TransparencyClassSpec spec = configHelper.getOrCreateSpec("org.terracotta.modules.hibernatecache.clustered.TerracottaHibernateCacheImpl"); spec.addCustomClassAdapter(new ClassAdapterFactory() { public ClassAdapter create(final ClassVisitor cv, final ClassLoader cl) {
configHelper.addCustomAdapter("org.terracotta.cache.TimestampedValue", new TimestampedValueAdapter()); configHelper.getOrCreateSpec("org.terracotta.coordination.CyclicBarrier"); configHelper.addWriteAutolock("* org.terracotta.coordination.CyclicBarrier.*(..)"); spec = configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedMap"); spec.addCustomClassAdapter(new NotClearableAdapter()); spec.addCustomClassAdapter(new TCMapAdapter()); configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedSet"); spec = configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ConcurrentDistributedMapDsoArray"); spec.setHonorTransient(true); spec.setCallMethodOnLoad("onLoad"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet$EntryIterator"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet$TcmEntry"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapKeySet"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapKeySet$KeyIterator"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.LazyCollection"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.LazySet"); spec = configHelper.getOrCreateSpec(ConcurrentDistributedMapDsoApplicator.CDM_DSO, ConcurrentDistributedMapDsoApplicator.CDM_DSO_APPLICATOR); spec.setUseNonDefaultConstructor(true);
configHelper.addCustomAdapter("org.terracotta.cache.TimestampedValue", new TimestampedValueAdapter()); configHelper.getOrCreateSpec("org.terracotta.coordination.CyclicBarrier"); configHelper.addWriteAutolock("* org.terracotta.coordination.CyclicBarrier.*(..)"); spec = configHelper.getOrCreateSpec("org.terracotta.async.AsyncCoordinator"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.async.ProcessingBucket"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.async.ProcessingBucketGroup"); spec.setHonorTransient(true); spec = configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedMap"); spec.addCustomClassAdapter(new NotClearableAdapter()); spec.addCustomClassAdapter(new TCMapAdapter()); configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedSet"); spec = configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ConcurrentDistributedMapDsoArray"); spec.setHonorTransient(true); spec.setCallMethodOnLoad("onLoad"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet$EntryIterator"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapEntrySet$TcmEntry"); configHelper.getOrCreateSpec("com.terracotta.toolkit.collections.ClusteredMapKeySet");
protected final void addInstrumentation(final BundleContext context) { super.addInstrumentation(context); configHelper.getOrCreateSpec("org.terracotta.modules.wan.collections.WANConcurrentMap"); TransparencyClassSpec spec = configHelper.getOrCreateSpec(WAN_DSO_CLASSNAME); TransparencyClassSpec csmspec = new TransparencyClassSpecImpl("java.util.HashMap", null, WAN_DSO_APPLICATOR_CLASSNAME); spec.moveToLogical(csmspec); spec.setUseNonDefaultConstructor(true); spec.setCallConstructorOnLoad(true); addExportedBundleClass(context.getBundle(), WAN_DSO_APPLICATOR_CLASSNAME); } }
spec = configHelper.getOrCreateSpec("org.hibernate.collection.AbstractPersistentCollection"); spec.addTransient("session"); factory = new AbstractPersistentCollectionClassAdapter.Factory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.AbstractPersistentCollection$IteratorProxy"); factory = new APCInnerClassAdapter.IteratorProxyAdapterFactory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.AbstractPersistentCollection$ListIteratorProxy"); factory = new APCInnerClassAdapter.ListIteratorProxyAdapterFactory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.AbstractPersistentCollection$SetProxy"); factory = new APCInnerClassAdapter.SetProxyAdapterFactory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.AbstractPersistentCollection$ListProxy"); factory = new APCInnerClassAdapter.ListProxyAdapterFactory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.PersistentSet"); spec.setHonorTransient(true); factory = new PersistentSetClassAdapter.Factory(); spec.setCustomClassAdapter(factory); spec = configHelper.getOrCreateSpec("org.hibernate.collection.PersistentBag"); factory = new PersistentBagClassAdapter.Factory(); spec.setCustomClassAdapter(factory);
protected void addCustomAdapter(String name, ClassAdapterFactory factory) { configHelper.addCustomAdapter(name, new VersionCheckingClassAdpaterFactory(version, factory)); }
protected void addInstrumentation(final BundleContext context) { // super.addExportedBundleClass(this.getExportedBundle(context, "org.terracotta.modules.map"), "com.tc.object.applicator.NonPartialHashtableApplicator"); // TransparencyClassSpec spec = configHelper.getOrCreateSpec("com.betting.api.terracotta.NonPartialHashtable", "com.tc.object.applicator.NonPartialHashtableApplicator"); // TransparencyClassSpec tableSpec = new TransparencyClassSpecImpl("java.util.Hashtable", null, "com.tc.object.applicator.NonPartialHashtableApplicator"); TransparencyClassSpec spec = configHelper.getOrCreateSpec("org.terracotta.maps.NPHashtable"); TransparencyClassSpec tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.HashMapApplicator"); spec.moveToLogical(tableSpec); spec = configHelper.getOrCreateSpec("org.terracotta.maps.NPHashMap"); tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.HashMapApplicator"); spec.moveToLogical(tableSpec); spec = configHelper.getOrCreateSpec("org.terracotta.maps.NPNCHashMap"); tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.HashMapApplicator"); spec.moveToLogical(tableSpec); spec = configHelper.getOrCreateSpec("org.terracotta.maps.NPNCHashtable"); tableSpec = new TransparencyClassSpecImpl("gnu.trove.THashMap", null, "com.tc.object.applicator.HashMapApplicator"); spec.moveToLogical(tableSpec); } }
@Override protected void addInstrumentation(BundleContext context) { addExportedBundleClass(getThisBundle(), IncludeTagSessionSupport.class.getName(), false); configHelper.addCustomAdapter("org.apache.struts.taglib.bean.IncludeTag", new IncludeTagAdapter()); super.addInstrumentation(context); }
@Override protected void addInstrumentation(final BundleContext context) { super.addInstrumentation(context); ClassAdapterFactory factory = new EhcacheCacheManagerClassAdapter(); TransparencyClassSpec spec = configHelper.getOrCreateSpec(CACHE_MANAGER_CLASS_NAME_DOTS); spec.setCustomClassAdapter(factory); }
protected final void addInstrumentation(final BundleContext context) { configHelper.addCustomAdapter( "org.apache.wicket.protocol.http.WebApplication", new WicketWebApplicationAdapter()); addExportedBundleClass(getThisBundle(), "org.terracotta.modules.wicket_1_3.TerracottaPageStore"); addExportedBundleClass(getThisBundle(), "org.terracotta.modules.wicket_1_3.TerracottaPageStore$PageMapStore"); addExportedBundleClass(getThisBundle(), "org.terracotta.modules.wicket_1_3.TerracottaPageStore$PageStore"); addExportedBundleClass(getThisBundle(), "org.terracotta.modules.wicket_1_3.TerracottaPageStore$PageKey"); } }
private void configureServerMap() { TransparencyClassSpec spec; spec = this.configHelper.getOrCreateSpec("org.terracotta.collections.ConcurrentDistributedServerMap"); spec.addCustomClassAdapter(new NotClearableAdapter()); spec.addCustomClassAdapter(new TCMapAdapter()); spec.setCallMethodOnLoad("onLoad"); spec = this.configHelper.getOrCreateSpec("org.terracotta.collections.EnterpriseConcurrentDistributedMap"); spec.setHonorTransient(true); spec.addCustomClassAdapter(new NotClearableAdapter()); .getOrCreateSpec("com.terracotta.toolkit.collections.ConcurrentDistributedServerMapDsoArray"); spec.setHonorTransient(true); spec.setCallMethodOnLoad("onLoad"); spec = this.configHelper.getOrCreateSpec(CDSM_DSO_CLASSNAME, CDSM_DSO_APPLICATOR_CLASSNAME); spec.setUseNonDefaultConstructor(true); spec.setCallConstructorOnLoad(true); spec = this.configHelper.getOrCreateSpec("org.terracotta.collections.servermap.ServerMapLocalStoreFactoryConfig"); spec = this.configHelper.getOrCreateSpec("org.terracotta.collections.servermap.ServerMapLocalStoreConfig"); spec = this.configHelper.getOrCreateSpec("org.terracotta.collections.servermap.DefaultServerMapLocalStoreFactory");
protected void addInstrumentation(BundleContext context) { super.addInstrumentation(context); Bundle bundle = getExportedBundle(context, getExportedBundleName()); ClassAdapterFactory factory = new CacheManagerAdapterFactory(configHelper, "net.sf.ehcache.CacheManager", "net.sf.ehcache.CacheManagerTC", bundle); TransparencyClassSpec spec = configHelper.getOrCreateSpec("net.sf.ehcache.CacheManager"); spec.setCustomClassAdapter(factory); addClassReplacement(bundle, CACHE_CLASS_NAME_DOTS, CACHETC_CLASS_NAME_DOTS); addClassReplacement(bundle, "net.sf.ehcache.Cache$1", "net.sf.ehcache.CacheTC$1"); factory = new CacheAdapterFactory(); spec = configHelper.getOrCreateSpec("net.sf.ehcache.Cache"); spec.setCustomClassAdapter(factory); if (null == bundle) { throw new RuntimeException("Couldn't find bundle with symbolic name '" + getExportedBundleName() + "' during the instrumentation configuration of the bundle '" + context.getBundle().getSymbolicName() + "'."); } addExportedBundleClass(bundle, "net.sf.ehcache.config.ConfigurationHelperTC"); }