public void addComponent(final ComponentConfiguration componentConfiguration) { if(componentConfiguration.getViews().size() < 2) { if(componentConfiguration.getViews().size() == 0) { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), null)); } else { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), componentConfiguration.getViews().get(0).getViewServiceName())); } } }
@Override public void configure(DeploymentPhaseContext context, ComponentDescription description, ComponentConfiguration configuration) { EjbSuspendInterceptor interceptor = null; ImmediateInterceptorFactory factory = null; for (ViewConfiguration view: configuration.getViews()) { EJBViewConfiguration ejbView = (EJBViewConfiguration) view; if (INTERFACES.contains(ejbView.getMethodIntf())) { if (factory == null) { interceptor = new EjbSuspendInterceptor(); factory = new ImmediateInterceptorFactory(interceptor); } view.addViewInterceptor(factory, InterceptorOrder.View.GRACEFUL_SHUTDOWN); } } configuration.getCreateDependencies().add(new DependencyConfigurator<EJBComponentCreateService>() { @Override public void configureDependency(ServiceBuilder<?> serviceBuilder, EJBComponentCreateService service) { serviceBuilder.addDependency(ControlPointService.serviceName(topLevelName, entryPoint), ControlPoint.class, service.getControlPointInjector()); } }); } });
@Override public void configure(DeploymentPhaseContext context, ComponentDescription description, ComponentConfiguration configuration) { StartupCountdown countdown = context.getDeploymentUnit().getAttachment(Attachments.STARTUP_COUNTDOWN); for (ViewConfiguration view : configuration.getViews()) { EJBViewConfiguration ejbView = (EJBViewConfiguration) view; if (INTFS.contains(ejbView.getMethodIntf())) { ejbView.addViewInterceptor(new ImmediateInterceptorFactory(new StartupAwaitInterceptor(countdown)), InterceptorOrder.View.STARTUP_AWAIT_INTERCEPTOR); } } } });
for (final ViewConfiguration viewConfiguration : configuration.getViews()) { final List<Method> viewMethods = viewConfiguration.getProxyFactory().getCachedMethods(); for (final Method viewMethod : viewMethods) {
for(ViewConfiguration view : configuration.getViews()) { view.addViewInterceptor(requestFactory, InterceptorOrder.View.CDI_REQUEST_SCOPE);
configurator.configure(context, configuration, view, viewConfiguration); configuration.getViews().add(viewConfiguration);
List<ViewConfiguration> views = componentConfiguration.getViews(); if (views != null) { for (ViewConfiguration view : views) {
for (ViewConfiguration viewConfiguration : configuration.getViews()) { final ServiceName serviceName = viewConfiguration.getViewServiceName(); final ViewService viewService = new ViewService(viewConfiguration);
public void addComponent(final ComponentConfiguration componentConfiguration) { if(componentConfiguration.getViews().size() < 2) { if(componentConfiguration.getViews().size() == 0) { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), null)); } else { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), componentConfiguration.getViews().get(0).getViewServiceName())); } } }
public void addComponent(final ComponentConfiguration componentConfiguration) { if(componentConfiguration.getViews().size() < 2) { if(componentConfiguration.getViews().size() == 0) { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), null)); } else { componentsByClass.put(componentConfiguration.getComponentClass(), new ComponentManagedReferenceFactory(componentConfiguration.getComponentDescription().getStartServiceName(), componentConfiguration.getViews().get(0).getViewServiceName())); } } }
/** * Construct a new instance. * * @param componentConfiguration the component configuration */ public MessageDrivenComponentCreateService(final ComponentConfiguration componentConfiguration, final ApplicationExceptions ejbJarConfiguration) { super(componentConfiguration, ejbJarConfiguration); final MessageDrivenComponentDescription componentDescription = (MessageDrivenComponentDescription) componentConfiguration.getComponentDescription(); this.resourceAdapterName = this.stripDotRarSuffix(componentDescription.getResourceAdapterName()); // see MessageDrivenComponentDescription.<init> this.messageListenerInterface = componentConfiguration.getViews().get(0).getViewClass(); this.activationProps = componentDescription.getActivationProps(); this.moduleClassLoader = componentConfiguration.getModuleClassLoader(); }
for (final ViewConfiguration viewConfiguration : configuration.getViews()) { final List<Method> viewMethods = viewConfiguration.getProxyFactory().getCachedMethods(); for (final Method viewMethod : viewMethods) {
configurator.configure(context, configuration, view, viewConfiguration); configuration.getViews().add(viewConfiguration);
configurator.configure(context, configuration, view, viewConfiguration); configuration.getViews().add(viewConfiguration);
configurator.configure(context, configuration, view, viewConfiguration); configuration.getViews().add(viewConfiguration);
List<ViewConfiguration> views = componentConfiguration.getViews(); if (views != null) { for (ViewConfiguration view : views) {
for (ViewConfiguration viewConfiguration : configuration.getViews()) { final ServiceName serviceName = viewConfiguration.getViewServiceName(); final ViewService viewService = new ViewService(viewConfiguration);
for (ViewConfiguration viewConfiguration : configuration.getViews()) { final ServiceName serviceName = viewConfiguration.getViewServiceName(); final ViewService viewService = new ViewService(viewConfiguration);
for (ViewConfiguration viewConfiguration : configuration.getViews()) { final ServiceName serviceName = viewConfiguration.getViewServiceName(); final ViewService viewService = new ViewService(viewConfiguration);