protected static void initializePortal(MithraObjectDeserializer objectFactory, Cache cache, MithraConfigurationManager.Config config) { initializeIndicies(cache); isFullCache = cache.isFullCache(); isOffHeap = cache.isOffHeap(); MithraObjectPortal portal; if (config.isParticipatingInTx()) { portal = new MithraTransactionalPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, (MithraObjectPersister) objectFactory); } else { portal = new MithraReadOnlyPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, (MithraObjectPersister) objectFactory); } config.initializePortal(portal); objectPortal.destroy(); objectPortal = portal; }
protected static void initializePortal(MithraObjectDeserializer objectFactory, Cache cache, MithraConfigurationManager.Config config) { initializeIndicies(cache); isFullCache = cache.isFullCache(); isOffHeap = cache.isOffHeap(); MithraObjectPortal portal; if (config.isParticipatingInTx()) { portal = new MithraTransactionalPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, (MithraObjectPersister) objectFactory); } else { portal = new MithraReadOnlyPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, (MithraObjectPersister) objectFactory); } portal.setIndependent(true); config.initializePortal(portal); objectPortal.destroy(); objectPortal = portal; }
protected static void initializeClientPortal(MithraObjectDeserializer objectFactory, Cache cache, MithraConfigurationManager.Config config) { initializeIndicies(cache); isFullCache = cache.isFullCache(); isOffHeap = cache.isOffHeap(); MithraObjectPortal portal; if (config.isParticipatingInTx()) { portal = new MithraTransactionalPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, new RemoteMithraObjectPersister(config.getRemoteMithraService(), getFinderInstance(), false)); } else { portal = new MithraReadOnlyPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, new RemoteMithraObjectPersister(config.getRemoteMithraService(), getFinderInstance(), false)); } config.initializePortal(portal); objectPortal.destroy(); objectPortal = portal; }
protected static void initializeClientPortal(MithraObjectDeserializer objectFactory, Cache cache, MithraConfigurationManager.Config config) { initializeIndicies(cache); isFullCache = cache.isFullCache(); isOffHeap = cache.isOffHeap(); MithraObjectPortal portal; if (config.isParticipatingInTx()) { portal = new MithraTransactionalPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, new RemoteMithraObjectPersister(config.getRemoteMithraService(), getFinderInstance(), false)); } else { portal = new MithraReadOnlyPortal(objectFactory, cache, getFinderInstance(), config.getRelationshipCacheSize(), config.getMinQueriesToKeep(), null, null, null, 0, new RemoteMithraObjectPersister(config.getRemoteMithraService(), getFinderInstance(), false)); } portal.setIndependent(true); config.initializePortal(portal); objectPortal.destroy(); objectPortal = portal; }