Search in sources :

Example 1 with ApiPolicyChainResolver

use of io.gravitee.gateway.handlers.api.policy.api.ApiPolicyChainResolver in project gravitee-gateway by gravitee-io.

the class ApiReactorHandler method afterPropertiesSet.

@Override
public void afterPropertiesSet() {
    contextPath = reactable().contextPath() + '/';
    apiPolicyResolver = new ApiPolicyChainResolver();
    PolicyChainResolver securityPolicyResolver = new SecurityPolicyChainResolver();
    PolicyChainResolver planPolicyResolver = new PlanPolicyChainResolver();
    policyResolvers = new ArrayList<PolicyChainResolver>() {

        {
            applicationContext.getAutowireCapableBeanFactory().autowireBean(securityPolicyResolver);
            applicationContext.getAutowireCapableBeanFactory().autowireBean(planPolicyResolver);
            applicationContext.getAutowireCapableBeanFactory().autowireBean(apiPolicyResolver);
            add(securityPolicyResolver);
            add(planPolicyResolver);
            add(apiPolicyResolver);
        }
    };
}
Also used : PlanPolicyChainResolver(io.gravitee.gateway.handlers.api.policy.plan.PlanPolicyChainResolver) PolicyChainResolver(io.gravitee.gateway.policy.PolicyChainResolver) PlanPolicyChainResolver(io.gravitee.gateway.handlers.api.policy.plan.PlanPolicyChainResolver) SecurityPolicyChainResolver(io.gravitee.gateway.security.core.SecurityPolicyChainResolver) ApiPolicyChainResolver(io.gravitee.gateway.handlers.api.policy.api.ApiPolicyChainResolver) ApiPolicyChainResolver(io.gravitee.gateway.handlers.api.policy.api.ApiPolicyChainResolver) SecurityPolicyChainResolver(io.gravitee.gateway.security.core.SecurityPolicyChainResolver)

Aggregations

ApiPolicyChainResolver (io.gravitee.gateway.handlers.api.policy.api.ApiPolicyChainResolver)1 PlanPolicyChainResolver (io.gravitee.gateway.handlers.api.policy.plan.PlanPolicyChainResolver)1 PolicyChainResolver (io.gravitee.gateway.policy.PolicyChainResolver)1 SecurityPolicyChainResolver (io.gravitee.gateway.security.core.SecurityPolicyChainResolver)1