kandi background
Explore Kits

spring-cloud-netflix | Integration with Netflix OSS components | Microservice library

 by   spring-cloud Java Version: v1.4.6.RELEASE License: Apache-2.0

 by   spring-cloud Java Version: v1.4.6.RELEASE License: Apache-2.0

Download this library from

kandi X-RAY | spring-cloud-netflix Summary

spring-cloud-netflix is a Java library typically used in Architecture, Microservice, Spring Boot, Spring applications. spring-cloud-netflix has no bugs, it has no vulnerabilities, it has build file available, it has a Permissive License and it has high support. You can download it from GitHub, Maven.
this project provides netflix oss integrations for spring boot apps through autoconfiguration and binding to the spring environment and other spring programming model idioms. with a few simple annotations you can quickly enable and configure the common patterns inside your application and build large distributed systems with battle-tested netflix components. the patterns provided include service discovery (eureka). service discovery: eureka instances can be registered and clients can discover the instances using spring-managed beans. service discovery: an embedded eureka server can be created with declarative java configuration. to build the source you will need to install jdk 1.8. spring cloud uses maven for most build-related activities, and you should be able to get off the ground quite quickly by cloning the project you are interested in and typing. the projects that require middleware (i.e. redis) for testing generally require that a local instance of [docker](www.docker.com/get-started) is installed
Support
Support
Quality
Quality
Security
Security
License
License
Reuse
Reuse

kandi-support Support

  • spring-cloud-netflix has a highly active ecosystem.
  • It has 4536 star(s) with 2342 fork(s). There are 380 watchers for this library.
  • It had no major release in the last 12 months.
  • There are 72 open issues and 3047 have been closed. On average issues are closed in 56 days. There are 19 open pull requests and 0 closed requests.
  • It has a negative sentiment in the developer community.
  • The latest version of spring-cloud-netflix is v1.4.6.RELEASE
spring-cloud-netflix Support
Best in #Microservice
Average in #Microservice
spring-cloud-netflix Support
Best in #Microservice
Average in #Microservice

quality kandi Quality

  • spring-cloud-netflix has 0 bugs and 0 code smells.
spring-cloud-netflix Quality
Best in #Microservice
Average in #Microservice
spring-cloud-netflix Quality
Best in #Microservice
Average in #Microservice

securitySecurity

  • spring-cloud-netflix has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
  • spring-cloud-netflix code analysis shows 0 unresolved vulnerabilities.
  • There are 0 security hotspots that need review.
spring-cloud-netflix Security
Best in #Microservice
Average in #Microservice
spring-cloud-netflix Security
Best in #Microservice
Average in #Microservice

license License

  • spring-cloud-netflix is licensed under the Apache-2.0 License. This license is Permissive.
  • Permissive licenses have the least restrictions, and you can use them in most projects.
spring-cloud-netflix License
Best in #Microservice
Average in #Microservice
spring-cloud-netflix License
Best in #Microservice
Average in #Microservice

buildReuse

  • spring-cloud-netflix releases are available to install and integrate.
  • Deployable package is available in Maven.
  • Build file is available. You can build the component from source.
  • Installation instructions are not available. Examples and code snippets are available.
  • spring-cloud-netflix saves you 25515 person hours of effort in developing the same functionality from scratch.
  • It has 49690 lines of code, 4227 functions and 605 files.
  • It has low code complexity. Code complexity directly impacts maintainability of the code.
spring-cloud-netflix Reuse
Best in #Microservice
Average in #Microservice
spring-cloud-netflix Reuse
Best in #Microservice
Average in #Microservice
Top functions reviewed by kandi - BETA

kandi has reviewed spring-cloud-netflix and discovered the below as its top functions. This is intended to give you an instant insight into spring-cloud-netflix implemented functionality, and help decide if they suit your requirements.

  • Populate the apps map .
  • Creates instance info from Eureka instance config .
  • Starts the downloader .
  • Create a Jersey application .
  • Register the configuration .
  • The mapping JacksonHttpMessageConverter .
  • Starts the service .
  • Sends a heartbeat .
  • Gets the metadata .
  • Initialize Eureka server context .

spring-cloud-netflix Key Features

1. Features

2. Building 2.1. Basic Compile and Test 2.2. Documentation 2.3. Working with the code 2.3.1. Activate the Spring Maven profile 2.3.2. Importing into eclipse with m2eclipse 2.3.3. Importing into eclipse without m2eclipse

3. Contributing 3.1. Sign the Contributor License Agreement 3.2. Code of Conduct 3.3. Code Conventions and Housekeeping 3.4. Checkstyle 3.4.1. Checkstyle configuration 3.5. IDE setup 3.5.1. Intellij IDEA 3.6. Duplicate Finder 3.6.1. Duplicate Finder configuration

4. License

Service Discovery: Eureka instances can be registered and clients can discover the instances using Spring-managed beans

Service Discovery: an embedded Eureka server can be created with declarative Java configuration

Use the Spring Framework code format conventions. If you use Eclipse you can import formatter settings using the eclipse-code-formatter.xml file from the Spring Cloud Build project. If using IntelliJ, you can use the Eclipse Code Formatter Plugin to import the same file.

Make sure all new .java files to have a simple Javadoc class comment with at least an @author tag identifying you, and preferably at least a paragraph on what the class is for.

Add the ASF license header comment to all new .java files (copy from existing files in the project)

Add yourself as an @author to the .java files that you modify substantially (more than cosmetic changes).

Add some Javadocs and, if you change the namespace, some XSD doc elements.

A few unit tests would help a lot as well — someone has to do it.

If no-one else is using your branch, please rebase it against the current master (or other target branch in the main project).

When writing a commit message please follow these conventions, if you are fixing an existing issue please add Fixes gh-XXXX at the end of the commit message (where XXXX is the issue number).

Default Checkstyle rules

File header setup

Default suppression rules

Default Checkstyle rules

File header setup

Default suppression rules

Project defaults for Intellij that apply most of Checkstyle rules

Project style conventions for Intellij that apply most of Checkstyle rules

checkstyle.header.file - please point it to the Spring Cloud Build’s, spring-cloud-build-tools/src/main/resources/checkstyle-header.txt file either in your cloned repo or via the raw.githubusercontent.com/spring-cloud/spring-cloud-build/master/spring-cloud-build-tools/src/main/resources/checkstyle-header.txt URL.

checkstyle.suppressions.file - default suppressions. Please point it to the Spring Cloud Build’s, spring-cloud-build-tools/src/checkstyle/checkstyle-suppressions.xml file either in your cloned repo or via the raw.githubusercontent.com/spring-cloud/spring-cloud-build/master/spring-cloud-build-tools/src/checkstyle/checkstyle-suppressions.xml URL.

checkstyle.additional.suppressions.file - this variable corresponds to suppressions in your local project. E.g. you’re working on spring-cloud-contract. Then point to the project-root/src/checkstyle/checkstyle-suppressions.xml folder. Example for spring-cloud-contract would be: /home/username/spring-cloud-contract/src/checkstyle/checkstyle-suppressions.xml.

default

copy iconCopydownload iconDownload
$ ./mvnw install

Zuul unable to route to application registered in eureka server

copy iconCopydownload iconDownload
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-gateway</artifactId>
            <version>3.1.0</version>
        </dependency>
server:
  port: 8082

spring:
  application:
    name: gateway
  cloud:
    gateway:
      discovery:
        locator:
          enabled: true
          lower-case-service-id: true
      routes:
        - id: game
          uri: lb://game
          predicates:
            - Path=/game/**
        - id: trend
          uri: lb://trend
          predicates:
            - Path=/trend/**

eureka:
  client:
    serviceURL:
      defaultZone: http://localhost:8761/eureka
-----------------------
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-gateway</artifactId>
            <version>3.1.0</version>
        </dependency>
server:
  port: 8082

spring:
  application:
    name: gateway
  cloud:
    gateway:
      discovery:
        locator:
          enabled: true
          lower-case-service-id: true
      routes:
        - id: game
          uri: lb://game
          predicates:
            - Path=/game/**
        - id: trend
          uri: lb://trend
          predicates:
            - Path=/trend/**

eureka:
  client:
    serviceURL:
      defaultZone: http://localhost:8761/eureka

Maven: Classpath dependencies and starters?

copy iconCopydownload iconDownload
<dependencies>
    (... Other dependencies ...)
    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
        <version>3.0.3</version>
    </dependency>
    (... Other dependencies ...)
</dependencies>

How to inject custom Http client to Spring Cloud openfeign?

copy iconCopydownload iconDownload
@Bean
    public CloseableHttpClient client() {
 CloseableHttpClient httpClient=null;
         try {
                    //... Skipping code for brevity.  
                    //here creating "sslSocketFactory" used in the HttpClient builder below
                    httpClient = HttpClients.custom().setSSLSocketFactory(sslSocketFactory)
                    .setMaxConnTotal(10)
                    .setMaxConnPerRoute(10)
                    .build();
                
            }catch(IOException | KeyManagementException | UnrecoverableKeyException | NoSuchAlgorithmException | KeyStoreException | CertificateException e) {
                System.err.println("Exception during creation of HttpClient. : "+e.getMessage());
            }
        return httpClient;
    }
              
@Bean
    public feign.Client client() {
      
       feign.Client client=null;
        try {

      //... Skipping code for brevity.  
                    //here creating "sslSocketFactory" used in the HttpClient builder below
      client = new Client.Default(sslSocketFactory, new DefaultHostnameVerifier());
            
        }catch(IOException | KeyManagementException | UnrecoverableKeyException | NoSuchAlgorithmException | KeyStoreException | CertificateException e) {
            System.err.println("Exception during creation of HttpClient. : "+e.getMessage());
        }
}
-----------------------
@Bean
    public CloseableHttpClient client() {
 CloseableHttpClient httpClient=null;
         try {
                    //... Skipping code for brevity.  
                    //here creating "sslSocketFactory" used in the HttpClient builder below
                    httpClient = HttpClients.custom().setSSLSocketFactory(sslSocketFactory)
                    .setMaxConnTotal(10)
                    .setMaxConnPerRoute(10)
                    .build();
                
            }catch(IOException | KeyManagementException | UnrecoverableKeyException | NoSuchAlgorithmException | KeyStoreException | CertificateException e) {
                System.err.println("Exception during creation of HttpClient. : "+e.getMessage());
            }
        return httpClient;
    }
              
@Bean
    public feign.Client client() {
      
       feign.Client client=null;
        try {

      //... Skipping code for brevity.  
                    //here creating "sslSocketFactory" used in the HttpClient builder below
      client = new Client.Default(sslSocketFactory, new DefaultHostnameVerifier());
            
        }catch(IOException | KeyManagementException | UnrecoverableKeyException | NoSuchAlgorithmException | KeyStoreException | CertificateException e) {
            System.err.println("Exception during creation of HttpClient. : "+e.getMessage());
        }
}

Jhipster Spring Boot 2 instances of a microservice on different databases

copy iconCopydownload iconDownload
java -Dspring.profiles.active=dev -Dserver.port=7040 -jar microservice-0.0.1-SNAPSHOT.jar -Dspring-boot.run.arguments= --hazelcast.port=12741 --APP_INSTANCE_NAME=microservice --APP_NAME=Microservice --APP_CLIENT_NAME='MicroserviceApp' --mainflux.broker=10.172.192.26 --APP_SWAGGER_TITLE='Microservice API' --APP_SWAGGER_DESC='Microservice API documentation'
    eureka:
      client:
        enabled: true
        healthcheck:
          enabled: true
        fetch-registry: true
        register-with-eureka: true
        instance-info-replication-interval-seconds: 10
        registry-fetch-interval-seconds: 10
      instance:
        appname: ${APP_INSTANCE_NAME:microservice}
        instanceId: ${APP_INSTANCE_NAME:microservice}:${spring.application.instance-id:${random.value}}
        lease-renewal-interval-in-seconds: 5
        lease-expiration-duration-in-seconds: 10
        status-page-url-path: ${management.endpoints.web.base-path}/info
        health-check-url-path: ${management.endpoints.web.base-path}/health
        metadata-map:
          zone: primary # This is needed for the load balancer
          profile: ${spring.profiles.active}
          version: #project.version#
          git-version: ${git.commit.id.describe:}
          git-commit: ${git.commit.id.abbrev:}
          git-branch: ${git.branch:}
...
...
...
-----------------------
java -Dspring.profiles.active=dev -Dserver.port=7040 -jar microservice-0.0.1-SNAPSHOT.jar -Dspring-boot.run.arguments= --hazelcast.port=12741 --APP_INSTANCE_NAME=microservice --APP_NAME=Microservice --APP_CLIENT_NAME='MicroserviceApp' --mainflux.broker=10.172.192.26 --APP_SWAGGER_TITLE='Microservice API' --APP_SWAGGER_DESC='Microservice API documentation'
    eureka:
      client:
        enabled: true
        healthcheck:
          enabled: true
        fetch-registry: true
        register-with-eureka: true
        instance-info-replication-interval-seconds: 10
        registry-fetch-interval-seconds: 10
      instance:
        appname: ${APP_INSTANCE_NAME:microservice}
        instanceId: ${APP_INSTANCE_NAME:microservice}:${spring.application.instance-id:${random.value}}
        lease-renewal-interval-in-seconds: 5
        lease-expiration-duration-in-seconds: 10
        status-page-url-path: ${management.endpoints.web.base-path}/info
        health-check-url-path: ${management.endpoints.web.base-path}/health
        metadata-map:
          zone: primary # This is needed for the load balancer
          profile: ${spring.profiles.active}
          version: #project.version#
          git-version: ${git.commit.id.describe:}
          git-commit: ${git.commit.id.abbrev:}
          git-branch: ${git.branch:}
...
...
...

I am getting this error java.lang.NoClassDefFoundError: org/w3c/dom/ElementTraversal

copy iconCopydownload iconDownload
    <dependency>
        <groupId>xalan</groupId>
        <artifactId>xalan</artifactId>
        <version>2.7.2</version>
        <exclusions>
            <exclusion>
                <groupId>xml-apis</groupId>
                <artifactId>xml-apis</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>dom4j</groupId>
        <artifactId>dom4j</artifactId>
        <version>1.6.1</version>
        <exclusions>
            <exclusion>
                <artifactId>xml-apis</artifactId>
                <groupId>xml-apis</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>jaxen</groupId>
        <artifactId>jaxen</artifactId>
        <version>1.2.0</version>
        <exclusions>
            <exclusion>
                <artifactId>xerces</artifactId>
                <groupId>xercesImpl</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>org.apache.poi</groupId>
        <artifactId>poi-ooxml</artifactId>
        <version>5.0.0</version>
        <exclusions>
            <exclusion>
                <artifactId>xml-apis</artifactId>
                <groupId>xml-apis</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.io7m.xom</groupId>
        <artifactId>xom</artifactId>
        <version>1.2.10</version>
        <exclusions>
            <exclusion>
                <artifactId>xerces</artifactId>
                <groupId>xercesImpl</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>xml-apis</groupId>
        <artifactId>xml-apis</artifactId>
        <version>1.4.01</version>
    </dependency>
-----------------------
    <dependency>
        <groupId>xalan</groupId>
        <artifactId>xalan</artifactId>
        <version>2.7.2</version>
        <exclusions>
            <exclusion>
                <groupId>xml-apis</groupId>
                <artifactId>xml-apis</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>dom4j</groupId>
        <artifactId>dom4j</artifactId>
        <version>1.6.1</version>
        <exclusions>
            <exclusion>
                <artifactId>xml-apis</artifactId>
                <groupId>xml-apis</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>jaxen</groupId>
        <artifactId>jaxen</artifactId>
        <version>1.2.0</version>
        <exclusions>
            <exclusion>
                <artifactId>xerces</artifactId>
                <groupId>xercesImpl</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>org.apache.poi</groupId>
        <artifactId>poi-ooxml</artifactId>
        <version>5.0.0</version>
        <exclusions>
            <exclusion>
                <artifactId>xml-apis</artifactId>
                <groupId>xml-apis</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>com.io7m.xom</groupId>
        <artifactId>xom</artifactId>
        <version>1.2.10</version>
        <exclusions>
            <exclusion>
                <artifactId>xerces</artifactId>
                <groupId>xercesImpl</groupId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>xml-apis</groupId>
        <artifactId>xml-apis</artifactId>
        <version>1.4.01</version>
    </dependency>

Spring Boot App doesn't start when the first eureka server is down

copy iconCopydownload iconDownload
@Slf4j
@Configuration
public class EurekaMultiClientBoostrapConfig {
    @Bean
    @Primary
    public RestTemplateEurekaHttpClient configDiscoveryRestTemplateEurekaHttpClient(EurekaClientConfigBean config) {
        List<String> urls = EndpointUtils.getServiceUrlsFromConfig(config,
                EurekaClientConfigBean.DEFAULT_ZONE, true);
        for (String url : urls) {
            try {
                RestTemplateEurekaHttpClient client = (RestTemplateEurekaHttpClient) new RestTemplateTransportClientFactory()
                        .newClient(new DefaultEndpoint(url));
                client.getApplications(config.getRegion());
                log.info("Registered on Eureka host '{}' is successful.", url);
                return client;
            } catch (Exception e) {
                log.warn("Eureka host '{}' is unavailable(reason: {})", url, e.getMessage());
            }
        }
        throw new IllegalStateException("Failed to register on any eureka host.");
    }
org.springframework.cloud.bootstrap.BootstrapConfiguration=your.app.package.EurekaMultiClientBoostrapConfig
-----------------------
@Slf4j
@Configuration
public class EurekaMultiClientBoostrapConfig {
    @Bean
    @Primary
    public RestTemplateEurekaHttpClient configDiscoveryRestTemplateEurekaHttpClient(EurekaClientConfigBean config) {
        List<String> urls = EndpointUtils.getServiceUrlsFromConfig(config,
                EurekaClientConfigBean.DEFAULT_ZONE, true);
        for (String url : urls) {
            try {
                RestTemplateEurekaHttpClient client = (RestTemplateEurekaHttpClient) new RestTemplateTransportClientFactory()
                        .newClient(new DefaultEndpoint(url));
                client.getApplications(config.getRegion());
                log.info("Registered on Eureka host '{}' is successful.", url);
                return client;
            } catch (Exception e) {
                log.warn("Eureka host '{}' is unavailable(reason: {})", url, e.getMessage());
            }
        }
        throw new IllegalStateException("Failed to register on any eureka host.");
    }
org.springframework.cloud.bootstrap.BootstrapConfiguration=your.app.package.EurekaMultiClientBoostrapConfig

How to add dynamic header values to feign-client through Feign interceptor from current request?

copy iconCopydownload iconDownload
circuitBreakerFactory
                    .create("createUserProfile").run(
                            () -> {
                                    String resp = callerClient.callExternalService();
                                    return resp;
                                    
                            }, exception -> {
                                    logger.info(exception.getMessage());
                            }
                    );
   @Bean
   DispatcherServlet dispatcherServlet() {
       DispatcherServlet servlet = new DispatcherServlet();
       servlet.setThreadContextInheritable(true);
       return servlet;
   }
-----------------------
circuitBreakerFactory
                    .create("createUserProfile").run(
                            () -> {
                                    String resp = callerClient.callExternalService();
                                    return resp;
                                    
                            }, exception -> {
                                    logger.info(exception.getMessage());
                            }
                    );
   @Bean
   DispatcherServlet dispatcherServlet() {
       DispatcherServlet servlet = new DispatcherServlet();
       servlet.setThreadContextInheritable(true);
       return servlet;
   }

Zuul routing the requests through an external proxy server

copy iconCopydownload iconDownload
   test2:
      path: /proxied-test2/**
      serviceId: test2
      url: http://my.api.server.com 
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
zuul:
  routes
    test:
      path: /test/**
      serviceId: test
      url: http://my.api.server.com
    test2:
      path: /test2/**
      serviceId: test2
      url: http://localhost:9200/proxied-test2/
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
-----------------------
   test2:
      path: /proxied-test2/**
      serviceId: test2
      url: http://my.api.server.com 
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
zuul:
  routes
    test:
      path: /test/**
      serviceId: test
      url: http://my.api.server.com
    test2:
      path: /test2/**
      serviceId: test2
      url: http://localhost:9200/proxied-test2/
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
-----------------------
   test2:
      path: /proxied-test2/**
      serviceId: test2
      url: http://my.api.server.com 
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
zuul:
  routes
    test:
      path: /test/**
      serviceId: test
      url: http://my.api.server.com
    test2:
      path: /test2/**
      serviceId: test2
      url: http://localhost:9200/proxied-test2/
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
-----------------------
   test2:
      path: /proxied-test2/**
      serviceId: test2
      url: http://my.api.server.com 
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888
zuul:
  routes
    test:
      path: /test/**
      serviceId: test
      url: http://my.api.server.com
    test2:
      path: /test2/**
      serviceId: test2
      url: http://localhost:9200/proxied-test2/
-Dhttp.proxyHost=localhost -Dhttp.proxyPort=8888

How to pass Pageable to Feign Client in POST Request with additional @RequestBody

copy iconCopydownload iconDownload
@PostMapping("/search")
public Page<MeasureDto> searchMeasures(@RequestBody MeasureDto example, @RequestParam(required = true) Integer page) {
 
 // PageRequest.Of(numberPage, quantityRegisters) will send a Pageable, in this case bellow, number of page + number of records
    measureService.getMeasurePageable(example, PageRequest.of(page, 10)); 
 }
-----------------------
@PostMapping("/search")
public Page<HelloDto> searchHellos(@RequestHeader("apiKey") String apiKey, @RequestBody HelloDto example, @SpringQueryMap Pageable pageable);

package org.springframework.cloud.netflix.zuul does not exist

copy iconCopydownload iconDownload
<dependencies>
  <dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-netflix-core</artifactId>
    <version>1.3.0.RELEASE</version>
  </dependency>
</dependencies>

Community Discussions

Trending Discussions on spring-cloud-netflix
  • Spring Boot Microservice zuul Forwarding error
  • Zuul unable to route to application registered in eureka server
  • Maven: Classpath dependencies and starters?
  • Maven Fails To Find Dependency
  • How to inject custom Http client to Spring Cloud openfeign?
  • Jhipster Spring Boot 2 instances of a microservice on different databases
  • I am getting this error java.lang.NoClassDefFoundError: org/w3c/dom/ElementTraversal
  • Spring Boot App doesn't start when the first eureka server is down
  • EnableAuthorizationServer is working and is not deprecated
  • How to add dynamic header values to feign-client through Feign interceptor from current request?
Trending Discussions on spring-cloud-netflix

QUESTION

Spring Boot Microservice zuul Forwarding error

Asked 2022-Mar-22 at 12:00

I have created micro service using spring boot and implment zuul proxy so when I call url via zuul proxy and somehow my service is down I get com.netflix.zuul.exception.ZuulException

com.netflix.zuul.exception.ZuulException: Forwarding error at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.handleException(RibbonRoutingFilter.java:198) ~[spring-cloud-netflix-zuul-2.2.1.RELEASE.jar:2.2.1.RELEASE] at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.forward(RibbonRoutingFilter.java:173) ~[spring-cloud-netflix-zuul-2.2.1.RELEASE.jar:2.2.1.RELEASE] at org.springframework.cloud.netflix.zuul.filters.route.RibbonRoutingFilter.run(RibbonRoutingFilter.java:119) ~[spring-cloud-netflix-zuul-2.2.1.RELEASE.jar:2.2.1.RELEASE] at com.netflix.zuul.ZuulFilter.runFilter(ZuulFilter.java:117) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.FilterProcessor.processZuulFilter(FilterProcessor.java:193) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.FilterProcessor.runFilters(FilterProcessor.java:157) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.FilterProcessor.route(FilterProcessor.java:118) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.ZuulRunner.route(ZuulRunner.java:96) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.http.ZuulServlet.route(ZuulServlet.java:116) ~[zuul-core-1.3.1.jar:1.3.1] at com.netflix.zuul.http.ZuulServlet.service(ZuulServlet.java:81) ~[zuul-core-1.3.1.jar:1.3.1] at org.springframework.web.servlet.mvc.ServletWrappingController.handleRequestInternal(ServletWrappingController.java:166) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at org.springframework.cloud.netflix.zuul.web.ZuulController.handleRequest(ZuulController.java:45) [spring-cloud-netflix-zuul-2.2.1.RELEASE.jar:2.2.1.RELEASE] at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:52) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:1040) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:943) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:1006) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:898) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:634) [tomcat-embed-core-9.0.31.jar:9.0.31] at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:883) [spring-webmvc-5.2.4.RELEASE.jar:5.2.4.RELEASE] at javax.servlet.http.HttpServlet.service(HttpServlet.java:741) [tomcat-embed-core-9.0.31.jar:9.0.31]

ANSWER

Answered 2022-Mar-22 at 12:00

Zuul API gateway has been deprecated and now in maintenance mode. so it not recommended to use it.

You should use latest Spring Cloud Gatway in your project. if you want to use gateway

learn more about spring cloud gateway here :https://www.baeldung.com/spring-cloud-gateway

Source https://stackoverflow.com/questions/71570579

Community Discussions, Code Snippets contain sources that include Stack Exchange Network

Vulnerabilities

No vulnerabilities reported

Install spring-cloud-netflix

You can download it from GitHub, Maven.
You can use spring-cloud-netflix like any standard Java library. Please include the the jar files in your classpath. You can also use any IDE and you can run and debug the spring-cloud-netflix component as you would do with any other Java program. Best practice is to use a build tool that supports dependency management such as Maven or Gradle. For Maven installation, please refer maven.apache.org. For Gradle installation, please refer gradle.org .

Support

For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .

DOWNLOAD this Library from

Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from
over 430 million Knowledge Items
Find more libraries
Reuse Solution Kits and Libraries Curated by Popular Use Cases

Save this library and start creating your kit

Share this Page

share link
Consider Popular Microservice Libraries
Compare Microservice Libraries with Highest Support
Compare Microservice Libraries with Highest Security
Compare Microservice Libraries with Permissive License
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from
over 430 million Knowledge Items
Find more libraries
Reuse Solution Kits and Libraries Curated by Popular Use Cases

Save this library and start creating your kit

  • © 2022 Open Weaver Inc.