@Override public synchronized void start(StartContext startContext) throws StartException { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoaderInjectedValue.getValue())); this.configuration = configuration; this.factory = factory; }
@Override public void start(final StartContext context) throws StartException { factory = new RiverMarshallerFactory(); configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoader.getValue())); managedReference = dataSourceInjectedValue.getValue().getReference(); dataSource = (DataSource) managedReference.getInstance(); final InputStream stream = DatabaseTimerPersistence.class.getClassLoader().getResourceAsStream("timer-sql.properties"); sql = new Properties(); try { sql.load(stream); } catch (IOException e) { throw new StartException(e); } finally { safeClose(stream); } extractDialects(); investigateDialect(); checkDatabase(); if (refreshInterval > 0) { refreshTask = new RefreshTask(); timerInjectedValue.getValue().schedule(refreshTask, refreshInterval, refreshInterval); } }
private void doStart() { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoader.getValue())); configuration.setVersion(3); this.configuration = configuration; this.factory = factory; if (pathRelativeTo != null) { callbackHandle = pathManager.getValue().registerCallback(pathRelativeTo, PathManager.ReloadServerCallback.create(), PathManager.Event.UPDATED, PathManager.Event.REMOVED); } baseDir = new File(pathManager.getValue().resolveRelativePathEntry(path, pathRelativeTo)); if (!baseDir.exists()) { if (createIfNotExists) { if (!baseDir.mkdirs()) { throw EJB3_TIMER_LOGGER.failToCreateTimerFileStoreDir(baseDir); } } else { throw EJB3_TIMER_LOGGER.timerFileStoreDirNotExist(baseDir); } } if (!baseDir.isDirectory()) { throw EJB3_TIMER_LOGGER.invalidTimerFileStoreDir(baseDir); } }
EJBServerChannel(final RemotingTransactionServer transactionServer, final Channel channel, final int version, final MessageTracker messageTracker) { this.transactionServer = transactionServer; this.channel = channel; this.version = version; this.messageTracker = messageTracker; final MarshallingConfiguration configuration = new MarshallingConfiguration(); if (version < 3) { configuration.setClassTable(ProtocolV1ClassTable.INSTANCE); configuration.setObjectTable(ProtocolV1ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV1ObjectResolver(channel.getConnection(), true)); configuration.setVersion(2); } else { configuration.setObjectTable(ProtocolV3ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV3ObjectResolver(channel.getConnection(), true)); configuration.setVersion(4); } marshallerFactory = new RiverMarshallerFactory(); this.configuration = configuration; }
final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(serviceModuleLoaderInjectedValue.getValue()));
@Override public synchronized void start(StartContext startContext) throws StartException { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoaderInjectedValue.getValue())); this.configuration = configuration; this.factory = factory; }
@Override public synchronized void start(StartContext startContext) throws StartException { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoaderInjectedValue.getValue())); this.configuration = configuration; this.factory = factory; }
@Override public synchronized void start(final StartContext context) { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(moduleLoader.getValue())); this.configuration = configuration; this.factory = factory; if (pathRelativeTo != null) { callbackHandle = pathManager.getValue().registerCallback(pathRelativeTo, PathManager.ReloadServerCallback.create(), PathManager.Event.UPDATED, PathManager.Event.REMOVED); } baseDir = new File(pathManager.getValue().resolveRelativePathEntry(path, pathRelativeTo)); if (!baseDir.exists()) { if (createIfNotExists) { if (!baseDir.mkdirs()) { throw MESSAGES.failToCreateTimerFileStoreDir(baseDir); } } else { throw MESSAGES.timerFileStoreDirNotExist(baseDir); } } if (!baseDir.isDirectory()) { throw MESSAGES.invalidTimerFileStoreDir(baseDir); } }
EJBServerChannel(final RemotingTransactionServer transactionServer, final Channel channel, final int version, final MessageTracker messageTracker) { this.transactionServer = transactionServer; this.channel = channel; this.version = version; this.messageTracker = messageTracker; final MarshallingConfiguration configuration = new MarshallingConfiguration(); if (version < 3) { configuration.setClassTable(ProtocolV1ClassTable.INSTANCE); configuration.setObjectTable(ProtocolV1ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV1ObjectResolver(channel.getConnection(), true)); configuration.setVersion(2); } else { configuration.setObjectTable(ProtocolV3ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV3ObjectResolver(channel.getConnection(), true)); configuration.setVersion(4); } marshallerFactory = new RiverMarshallerFactory(); this.configuration = configuration; }
EJBServerChannel(final RemotingTransactionServer transactionServer, final Channel channel, final int version, final MessageTracker messageTracker) { this.transactionServer = transactionServer; this.channel = channel; this.version = version; this.messageTracker = messageTracker; final MarshallingConfiguration configuration = new MarshallingConfiguration(); if (version < 3) { configuration.setClassTable(ProtocolV1ClassTable.INSTANCE); configuration.setObjectTable(ProtocolV1ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV1ObjectResolver(channel.getConnection(), true)); configuration.setVersion(2); } else { configuration.setObjectTable(ProtocolV3ObjectTable.INSTANCE); configuration.setObjectResolver(new ProtocolV3ObjectResolver(channel.getConnection(), true)); configuration.setVersion(4); } marshallerFactory = new RiverMarshallerFactory(); this.configuration = configuration; }
public synchronized void start(final StartContext startContext) throws StartException { final RiverMarshallerFactory factory = new RiverMarshallerFactory(); final MarshallingConfiguration configuration = new MarshallingConfiguration(); configuration.setClassResolver(ModularClassResolver.getInstance(serviceModuleLoaderInjectedValue.getValue()));