Search in sources :

Example 1 with JaxrsIntegrationProcessor

use of org.jboss.as.jaxrs.deployment.JaxrsIntegrationProcessor in project wildfly by wildfly.

the class JaxrsSubsystemAdd method performBoottime.

protected void performBoottime(final OperationContext context, ModelNode operation, Resource resource) throws OperationFailedException {
    final ServiceTarget serviceTarget = context.getServiceTarget();
    JaxrsLogger.JAXRS_LOGGER.resteasyVersion(ResteasyDeployment.class.getPackage().getImplementationVersion());
    context.addStep(new AbstractDeploymentChainStep() {

        public void execute(DeploymentProcessorTarget processorTarget) {
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.PARSE, Phase.PARSE_JAXRS_ANNOTATIONS, new JaxrsAnnotationProcessor());
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.DEPENDENCIES, Phase.DEPENDENCIES_JAXRS_SPRING, new JaxrsSpringProcessor(serviceTarget));
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.DEPENDENCIES, Phase.DEPENDENCIES_JAXRS, new JaxrsDependencyProcessor());
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.POST_MODULE, Phase.POST_MODULE_JAXRS_SCANNING, new JaxrsScanningProcessor());
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.POST_MODULE, Phase.POST_MODULE_JAXRS_COMPONENT, new JaxrsComponentDeployer());
            CapabilityServiceSupport capabilities = context.getCapabilityServiceSupport();
            if (capabilities.hasCapability(WELD_CAPABILITY_NAME)) {
                processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.POST_MODULE, Phase.POST_MODULE_JAXRS_CDI_INTEGRATION, new JaxrsCdiIntegrationProcessor());
            }
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.POST_MODULE, Phase.POST_MODULE_JAXRS_METHOD_PARAMETER, new JaxrsMethodParameterProcessor());
            processorTarget.addDeploymentProcessor(JaxrsExtension.SUBSYSTEM_NAME, Phase.INSTALL, Phase.INSTALL_JAXRS_DEPLOYMENT, new JaxrsIntegrationProcessor());
        }
    }, OperationContext.Stage.RUNTIME);
    JaxrsServerConfig serverConfig = createServerConfig(operation, context);
    JaxrsServerConfigService.install(serviceTarget, serverConfig);
}
Also used : JaxrsIntegrationProcessor(org.jboss.as.jaxrs.deployment.JaxrsIntegrationProcessor) JaxrsAnnotationProcessor(org.jboss.as.jaxrs.deployment.JaxrsAnnotationProcessor) JaxrsScanningProcessor(org.jboss.as.jaxrs.deployment.JaxrsScanningProcessor) ServiceTarget(org.jboss.msc.service.ServiceTarget) JaxrsSpringProcessor(org.jboss.as.jaxrs.deployment.JaxrsSpringProcessor) JaxrsComponentDeployer(org.jboss.as.jaxrs.deployment.JaxrsComponentDeployer) CapabilityServiceSupport(org.jboss.as.controller.capability.CapabilityServiceSupport) JaxrsDependencyProcessor(org.jboss.as.jaxrs.deployment.JaxrsDependencyProcessor) DeploymentProcessorTarget(org.jboss.as.server.DeploymentProcessorTarget) JaxrsCdiIntegrationProcessor(org.jboss.as.jaxrs.deployment.JaxrsCdiIntegrationProcessor) AbstractDeploymentChainStep(org.jboss.as.server.AbstractDeploymentChainStep) JaxrsMethodParameterProcessor(org.jboss.as.jaxrs.deployment.JaxrsMethodParameterProcessor)

Aggregations

CapabilityServiceSupport (org.jboss.as.controller.capability.CapabilityServiceSupport)1 JaxrsAnnotationProcessor (org.jboss.as.jaxrs.deployment.JaxrsAnnotationProcessor)1 JaxrsCdiIntegrationProcessor (org.jboss.as.jaxrs.deployment.JaxrsCdiIntegrationProcessor)1 JaxrsComponentDeployer (org.jboss.as.jaxrs.deployment.JaxrsComponentDeployer)1 JaxrsDependencyProcessor (org.jboss.as.jaxrs.deployment.JaxrsDependencyProcessor)1 JaxrsIntegrationProcessor (org.jboss.as.jaxrs.deployment.JaxrsIntegrationProcessor)1 JaxrsMethodParameterProcessor (org.jboss.as.jaxrs.deployment.JaxrsMethodParameterProcessor)1 JaxrsScanningProcessor (org.jboss.as.jaxrs.deployment.JaxrsScanningProcessor)1 JaxrsSpringProcessor (org.jboss.as.jaxrs.deployment.JaxrsSpringProcessor)1 AbstractDeploymentChainStep (org.jboss.as.server.AbstractDeploymentChainStep)1 DeploymentProcessorTarget (org.jboss.as.server.DeploymentProcessorTarget)1 ServiceTarget (org.jboss.msc.service.ServiceTarget)1