Refine search
@Override public final StartException missingTransactionManager() { final StartException result = new StartException(String.format(getLoggingLocale(), missingTransactionManager$str())); final StackTraceElement[] st = result.getStackTrace(); result.setStackTrace(Arrays.copyOfRange(st, 1, st.length)); return result; } private static final String invalidAuthentication = "WFLYAG0110: Error obtaining credentials from authentication context for datasource '%s'";
@Override public void start(StartContext context) throws StartException { if (IIOPLogger.ROOT_LOGGER.isDebugEnabled()) { IIOPLogger.ROOT_LOGGER.debugf("Starting service %s", context.getController().getName().getCanonicalName()); final SocketBinding socketBinding = iiopSocketBindingInjector.getOptionalValue(); final SocketBinding sslSocketBinding = this.iiopSSLSocketBindingInjector.getOptionalValue(); InetSocketAddress address = this.iiopSocketBindingInjector.getValue().getSocketAddress(); properties.setProperty(ORBConstants.SERVER_HOST_PROPERTY, address.getAddress().getHostAddress()); properties.setProperty(ORBConstants.SERVER_PORT_PROPERTY, String.valueOf(address.getPort())); ServiceTarget target = context.getChildTarget(); CorbaServiceUtil.bindObject(target, "ORB", this.orb); } catch (Exception e) { throw new StartException(e);
@Override public void start(StartContext context) throws StartException { final AssociationService associationService = associationServiceInjectedValue.getValue(); final Endpoint endpoint = endpointValue.getValue(); Executor executor = executorService.getOptionalValue(); if (executor != null) { associationService.setExecutor(executor); } RemoteEJBService remoteEJBService = RemoteEJBService.create( associationService.getAssociation(), remotingTransactionServiceInjectedValue.getValue() ); remoteEJBService.serverUp(); // Register an EJB channel open listener OpenListener channelOpenListener = remoteEJBService.getOpenListener(); try { registration = endpoint.registerService(EJB_CHANNEL_NAME, channelOpenListener, this.channelCreationOptions); } catch (ServiceRegistrationException e) { throw new StartException(e); } }
public synchronized void start(StartContext context) throws StartException { try { final Context namingContext = new NamingContext(namingStore.getValue(), new Hashtable<String, Object>()); remoteNamingService = new RemoteNamingService(namingContext); remoteNamingService.start(endpoint.getValue()); } catch (Exception e) { throw new StartException("Failed to start remote naming service", e); } }
started = true; preStart(context); serverService.getValue().registerListener(this); try { openListener = createOpenListener(); HttpHandler handler = serverService.getValue().getRoot(); for(HandlerWrapper wrapper : listenerHandlerWrappers) { handler = wrapper.wrap(handler); final InetSocketAddress socketAddress = binding.getValue().getSocketAddress(); if (socketAddress != null) sb.append(" ").append(socketAddress); throw new StartException(sb.toString()); } else { throw UndertowLogger.ROOT_LOGGER.couldNotStartListener(name, e); }; getUndertowService().registerStatisticsListener(statisticsChangeListener); final ServiceContainer container = context.getController().getServiceContainer(); this.stoppingWrapper = new HandlerWrapper() { @Override
@Override public void start(final StartContext context) throws StartException { if (this.startAsynchronously) { Runnable task = () -> { try { this.service.start(context); context.complete(); } catch (StartException e) { context.failed(e); } catch (Throwable e) { context.failed(new StartException(e)); } }; try { this.executor.getValue().execute(task); } catch (RejectedExecutionException e) { task.run(); } finally { context.asynchronous(); } } else { this.service.start(context); } }
ComponentView componentView = paComponentViewInjector.getOptionalValue(); if(componentView != null) { reference = componentView.createInstance(); processApplication = (ProcessApplicationInterface) reference.getInstance(); } else { processApplication = noViewProcessApplication.getValue(); referencedProcessEngines.add(value.getProcessEngineInjector().getValue()); context.getChildTarget().addService(serviceName, managedProcessApplication).install(); throw new StartException(e);
@Override public void run() { try { startContext(); startContext.complete(); } catch (Throwable e) { startContext.failed(new StartException(e)); } } });
public void start(final StartContext context) throws StartException { context.asynchronous(); executorInjector.getValue().submit(new Runnable() { public void run() { try { performDeployment(); context.complete(); } catch (StartException e) { context.failed(e); } catch (Throwable e) { context.failed(new StartException(e)); } } }); }
@Override public void start(final StartContext ctx) throws StartException { WSLogger.ROOT_LOGGER.starting(name); try { wsctx = EndpointPublisherHelper.doPublishStep(hostInjector.getValue(), ctx.getChildTarget(), deploymentUnit); } catch (Exception e) { throw new StartException(e); } }
@Override public void start(StartContext context) throws StartException { this.server = newServer(); try { this.server.host(this.bindingInjector.getValue().getAddress()); this.server.port(this.bindingInjector.getValue().getPort()); this.server.pipelineConfigurator(this.pipelineConfiguratorInjector.getValue()); this.server.start(); } catch (Exception e) { context.failed(new StartException(e)); } }
@Override public void start(final StartContext ctx) throws StartException { WSLogger.ROOT_LOGGER.starting(name); try { wsctxConsumer.accept(wsctx = EndpointPublisherHelper.doPublishStep(hostSupplier.get(), ctx.getChildTarget(), deploymentUnit)); } catch (Exception e) { throw new StartException(e); } }
private static InstancesService putIfAbsent(ServiceRegistry registry, ServiceName name, ServiceBuilder builder) throws StartException { for (; ; ) { try { ServiceController sc = registry.getService(name); if (sc == null) { sc = builder.install(); } return (InstancesService) sc.getService(); } catch (DuplicateServiceException ignored) { } catch (Exception e) { throw new StartException(e); } } }
@Override public void start(StartContext context) throws StartException { // Global configuration. final CoreEnvironmentBean coreEnvironmentBean = arjPropertyManager.getCoreEnvironmentBean(); if(coreEnvironmentBean.getProcessImplementationClassName() == null) { UuidProcessId id = new UuidProcessId(); coreEnvironmentBean.setProcessImplementation(id); } try { coreEnvironmentBean.setNodeIdentifier(nodeIdentifier); } catch (CoreEnvironmentBeanException e) { throw new StartException(e.getCause()); } // Setup the socket process id if there is a binding SocketBinding binding = socketProcessBindingInjector.getOptionalValue(); if(binding != null) { int port = binding.getPort(); coreEnvironmentBean.setSocketProcessIdPort(port); } }
@Override public void transition(ServiceController<?> controller, ServiceController.Transition transition) { if (transition.enters(ServiceController.State.START_FAILED)) { StartException exception = controller.getStartException(); Throwable cause = exception.getCause(); testableArchiveService.setError(cause); } } });
public ModuleSpec getModuleSpec() throws ModuleLoadException { if (startException != null) throw new ModuleLoadException(startException.getCause()); return moduleSpec; } }
@Override public void start(StartContext context) throws StartException { ROOT_LOGGER.debugf("started DirectConnectionFactoryActivatorService %s", context.getController().getName()); String aoClass = null; Connector cmd = mdr.getValue().getResourceAdapter(raId); if (cmd.getVersion() == Connector.Version.V_10) { throw ConnectorLogger.ROOT_LOGGER.adminObjectForJCA10(resourceAdapter, jndiName); activator.setCreateBinderService(false); activator.setBindInfo(bindInfo); ServiceTarget serviceTarget = context.getChildTarget(); adminObjectServiceBuilder.setInitialMode(ServiceController.Mode.ACTIVE).install(); } catch (Exception e) { throw new StartException(e);
@Override public void start(StartContext startContext) throws StartException { //todo: this is a bit of a hack, as the proxy handler may be wrapped by a request controller handler for graceful shutdown ProxyHandler proxyHandler = (ProxyHandler) (this.proxyHandler.getValue() instanceof GlobalRequestControllerHandler ? ((GlobalRequestControllerHandler)this.proxyHandler.getValue()).getNext() : this.proxyHandler.getValue()); final LoadBalancingProxyClient client = (LoadBalancingProxyClient) proxyHandler.getProxyClient(); try { SSLContext sslContext = this.sslContext.getOptionalValue(); if (sslContext == null) { SecurityRealm securityRealm = this.securityRealm.getOptionalValue(); if (securityRealm != null) { sslContext = securityRealm.getSSLContext(); } } if (sslContext == null) { client.addHost(getUri(), instanceId, null, OptionMap.create(UndertowOptions.ENABLE_HTTP2, enableHttp2)); } else { OptionMap.Builder builder = OptionMap.builder(); builder.set(Options.USE_DIRECT_BUFFERS, true); OptionMap combined = builder.getMap(); XnioSsl xnioSsl = new UndertowXnioSsl(Xnio.getInstance(), combined, sslContext); client.addHost(getUri(), instanceId, xnioSsl, OptionMap.create(UndertowOptions.ENABLE_HTTP2, enableHttp2)); } } catch (URISyntaxException e) { throw new StartException(e); } }
/** * Creates a new NamingServer and sets the naming context to use the naming server. * * @param context The start context * @throws StartException If any errors occur setting up the naming server */ public void start(StartContext context) throws StartException { ROOT_LOGGER.startingService(); try { NamingContext.setActiveNamingStore(namingStore.getValue()); } catch (Throwable t) { throw new StartException(NamingLogger.ROOT_LOGGER.failedToStart("naming service"), t); } }
addCallbacks(false); ServiceRegistry registry = context.getController().getServiceContainer(); InstancesService.addInstance(registry, context.getChildTarget(), getLifecycleState(), getBean()); final BeanMetaDataConfig beanConfig = getBeanConfig(); final ServiceName name = BeanMetaDataConfig.toBeanName(beanConfig.getName(), next); final ServiceTarget serviceTarget = context.getChildTarget(); final ServiceBuilder serviceBuilder = serviceTarget.addService(name, nextPhase); registerAliases(serviceBuilder, next); throw new StartException(t);