private InjectionAwareInstanceProvider(
     final InstanceProvider delegate, final Endpoint endpoint, final DeploymentUnit unit) {
   this.delegate = delegate;
   endpointName = endpoint.getShortName();
   endpointClass = endpoint.getTargetBeanName();
   componentPrefix = unit.getServiceName().append("component");
 }
Esempio n. 2
0
 public static void install(
     final ServiceTarget serviceTarget, final Endpoint endpoint, final DeploymentUnit unit) {
   final ServiceName serviceName = getServiceName(unit, endpoint.getShortName());
   final EndpointService service = new EndpointService(endpoint, serviceName);
   final ServiceBuilder<Endpoint> builder = serviceTarget.addService(serviceName, service);
   builder.addDependency(
       DependencyType.REQUIRED,
       SecurityDomainService.SERVICE_NAME.append(getDeploymentSecurityDomainName(endpoint)),
       SecurityDomainContext.class,
       service.getSecurityDomainContextInjector());
   builder.addDependency(
       DependencyType.REQUIRED,
       WSServices.REGISTRY_SERVICE,
       EndpointRegistry.class,
       service.getEndpointRegistryInjector());
   builder.addDependency(
       DependencyType.REQUIRED,
       WSServices.PORT_COMPONENT_LINK_SERVICE,
       WebAppController.class,
       service.getPclWebAppControllerInjector());
   builder.addDependency(
       DependencyType.OPTIONAL,
       MBEAN_SERVER_NAME,
       MBeanServer.class,
       service.getMBeanServerInjector());
   builder.setInitialMode(Mode.ACTIVE);
   builder.install();
 }
Esempio n. 3
0
 public static void uninstall(final Endpoint endpoint, final DeploymentUnit unit) {
   final ServiceName serviceName = getServiceName(unit, endpoint.getShortName());
   WSServices.getContainerRegistry().getRequiredService(serviceName).setMode(Mode.REMOVE);
 }