org.springframework.cloud.netflix.zuul.filters.RouteLocator Java Examples

The following examples show how to use org.springframework.cloud.netflix.zuul.filters.RouteLocator. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ZuulConfiguration.java    From heimdall with Apache License 2.0 5 votes vote down vote up
@Override
public HeimdallHandlerMapping zuulHandlerMapping(RouteLocator routes) {

	HeimdallHandlerMapping handlerMapping = new HeimdallHandlerMapping(proxyRouteLocator(), zuulController());
	handlerMapping.setErrorController(this.errorController);
	return handlerMapping;
}
 
Example #2
Source File: AbstractRateLimitFilter.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 5 votes vote down vote up
AbstractRateLimitFilter(final RateLimitProperties properties, final RouteLocator routeLocator,
                        final UrlPathHelper urlPathHelper, final RateLimitUtils rateLimitUtils) {
    this.properties = properties;
    this.routeLocator = routeLocator;
    this.urlPathHelper = urlPathHelper;
    this.rateLimitUtils = rateLimitUtils;
}
 
Example #3
Source File: RateLimitPostFilter.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 5 votes vote down vote up
public RateLimitPostFilter(final RateLimitProperties properties, final RouteLocator routeLocator,
                           final UrlPathHelper urlPathHelper, final RateLimiter rateLimiter,
                           final RateLimitKeyGenerator rateLimitKeyGenerator, final RateLimitUtils rateLimitUtils) {
    super(properties, routeLocator, urlPathHelper, rateLimitUtils);
    this.rateLimiter = rateLimiter;
    this.rateLimitKeyGenerator = rateLimitKeyGenerator;
}
 
Example #4
Source File: RateLimitPreFilter.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 5 votes vote down vote up
public RateLimitPreFilter(final RateLimitProperties properties, final RouteLocator routeLocator,
                          final UrlPathHelper urlPathHelper, final RateLimiter rateLimiter,
                          final RateLimitKeyGenerator rateLimitKeyGenerator, final RateLimitUtils rateLimitUtils,
                          final ApplicationEventPublisher eventPublisher) {
    super(properties, routeLocator, urlPathHelper, rateLimitUtils);
    this.rateLimiter = rateLimiter;
    this.rateLimitKeyGenerator = rateLimitKeyGenerator;
    this.eventPublisher = eventPublisher;
}
 
Example #5
Source File: RateLimitAutoConfiguration.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 5 votes vote down vote up
@Bean
public ZuulFilter rateLimiterPostFilter(final RateLimiter rateLimiter, final RateLimitProperties rateLimitProperties,
                                        final RouteLocator routeLocator, final RateLimitKeyGenerator rateLimitKeyGenerator,
                                        final RateLimitUtils rateLimitUtils) {
    return new RateLimitPostFilter(rateLimitProperties, routeLocator, URL_PATH_HELPER, rateLimiter,
            rateLimitKeyGenerator, rateLimitUtils);
}
 
Example #6
Source File: RateLimitAutoConfiguration.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 5 votes vote down vote up
@Bean
public ZuulFilter rateLimiterPreFilter(final RateLimiter rateLimiter, final RateLimitProperties rateLimitProperties,
                                       final RouteLocator routeLocator, final RateLimitKeyGenerator rateLimitKeyGenerator,
                                       final RateLimitUtils rateLimitUtils, final ApplicationEventPublisher eventPublisher) {
    return new RateLimitPreFilter(rateLimitProperties, routeLocator, URL_PATH_HELPER, rateLimiter,
            rateLimitKeyGenerator, rateLimitUtils, eventPublisher);
}
 
Example #7
Source File: GatewayConfiguration.java    From tutorials with MIT License 4 votes vote down vote up
@Bean
public AccessControlFilter accessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties){
    return new AccessControlFilter(routeLocator, jHipsterProperties);
}
 
Example #8
Source File: GatewaySwaggerResourcesProvider.java    From tutorials with MIT License 4 votes vote down vote up
public GatewaySwaggerResourcesProvider(RouteLocator routeLocator) {
    this.routeLocator = routeLocator;
}
 
Example #9
Source File: AccessControlFilter.java    From tutorials with MIT License 4 votes vote down vote up
public AccessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    this.routeLocator = routeLocator;
    this.jHipsterProperties = jHipsterProperties;
}
 
Example #10
Source File: GatewayResource.java    From tutorials with MIT License 4 votes vote down vote up
public GatewayResource(RouteLocator routeLocator, DiscoveryClient discoveryClient) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
}
 
Example #11
Source File: GatewayConfiguration.java    From jhipster-registry with Apache License 2.0 4 votes vote down vote up
@Bean
public AccessControlFilter accessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    return new AccessControlFilter(routeLocator, jHipsterProperties);
}
 
Example #12
Source File: GatewaySwaggerResourcesProvider.java    From tutorials with MIT License 4 votes vote down vote up
public GatewaySwaggerResourcesProvider(RouteLocator routeLocator, DiscoveryClient discoveryClient) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
}
 
Example #13
Source File: AccessControlFilter.java    From tutorials with MIT License 4 votes vote down vote up
public AccessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    this.routeLocator = routeLocator;
    this.jHipsterProperties = jHipsterProperties;
}
 
Example #14
Source File: AccessControlFilter.java    From jhipster-registry with Apache License 2.0 4 votes vote down vote up
public AccessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    this.routeLocator = routeLocator;
    this.jHipsterProperties = jHipsterProperties;
}
 
Example #15
Source File: BaseRateLimitPreFilterTest.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 4 votes vote down vote up
private RouteLocator routeLocator() {
    return new TestRouteLocator(Collections.singletonList("ignored"),
        asList(createRoute("serviceA"), createRoute("serviceB")));
}
 
Example #16
Source File: RoutesResource.java    From jhipster-registry with Apache License 2.0 4 votes vote down vote up
public RoutesResource(RouteLocator routeLocator, DiscoveryClient discoveryClient, ZuulProperties zuulProperties) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
    this.zuulProperties = zuulProperties;
}
 
Example #17
Source File: ZuulUpdaterService.java    From jhipster-registry with Apache License 2.0 4 votes vote down vote up
public ZuulUpdaterService(RouteLocator routeLocator, ZuulProperties zuulProperties,
                          ApplicationEventPublisher publisher) {
    this.routeLocator = routeLocator;
    this.zuulProperties = zuulProperties;
    this.publisher = publisher;
}
 
Example #18
Source File: RateLimitAutoConfigurationTest.java    From spring-cloud-zuul-ratelimit with Apache License 2.0 4 votes vote down vote up
@Bean
public RouteLocator routeLocator() {
    return mock(RouteLocator.class);
}
 
Example #19
Source File: GatewayConfiguration.java    From tutorials with MIT License 4 votes vote down vote up
@Bean
public AccessControlFilter accessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties){
    return new AccessControlFilter(routeLocator, jHipsterProperties);
}
 
Example #20
Source File: GatewayResource.java    From tutorials with MIT License 4 votes vote down vote up
public GatewayResource(RouteLocator routeLocator, DiscoveryClient discoveryClient) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
}
 
Example #21
Source File: ProxyRedirectFilter.java    From spring-cloud-netflix-zuul-websocket with Apache License 2.0 4 votes vote down vote up
public ProxyRedirectFilter(RouteLocator routeLocator, UrlPathHelper urlPathHelper) {
	this.routeLocator = routeLocator;
	this.urlPathHelper = urlPathHelper;
}
 
Example #22
Source File: ProxyRedirectFilter.java    From spring-cloud-netflix-zuul-websocket with Apache License 2.0 4 votes vote down vote up
public ProxyRedirectFilter(RouteLocator routeLocator) {
	this(routeLocator, new UrlPathHelper());
}
 
Example #23
Source File: ZuulWebSocketConfiguration.java    From spring-cloud-netflix-zuul-websocket with Apache License 2.0 4 votes vote down vote up
@Bean
public ProxyRedirectFilter proxyRedirectFilter(RouteLocator routeLocator) {
    return new ProxyRedirectFilter(routeLocator);
}
 
Example #24
Source File: AccessControlFilter.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
public AccessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    this.routeLocator = routeLocator;
    this.jHipsterProperties = jHipsterProperties;
}
 
Example #25
Source File: RegistryConfiguration.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
@Bean
public AccessControlFilter accessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties){
    return new AccessControlFilter(routeLocator, jHipsterProperties);
}
 
Example #26
Source File: ZuulUpdaterService.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
public ZuulUpdaterService(RouteLocator routeLocator, ZuulProperties zuulProperties,
                          ApplicationEventPublisher publisher) {
    this.routeLocator = routeLocator;
    this.zuulProperties = zuulProperties;
    this.publisher = publisher;
}
 
Example #27
Source File: RoutesResource.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
public RoutesResource(RouteLocator routeLocator, DiscoveryClient discoveryClient, ZuulProperties zuulProperties) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
    this.zuulProperties = zuulProperties;
}
 
Example #28
Source File: GatewayConfiguration.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
@Bean
public AccessControlFilter accessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties){
    return new AccessControlFilter(routeLocator, jHipsterProperties);
}
 
Example #29
Source File: GatewaySwaggerResourcesProvider.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
public GatewaySwaggerResourcesProvider(RouteLocator routeLocator, DiscoveryClient discoveryClient) {
    this.routeLocator = routeLocator;
    this.discoveryClient = discoveryClient;
}
 
Example #30
Source File: AccessControlFilter.java    From jhipster-microservices-example with Apache License 2.0 4 votes vote down vote up
public AccessControlFilter(RouteLocator routeLocator, JHipsterProperties jHipsterProperties) {
    this.routeLocator = routeLocator;
    this.jHipsterProperties = jHipsterProperties;
}