Springboot2 and eureka Integration chooses netty as Startup Container

recently there are a lot of major updates to springboot2, so I"m going to take a look at spring-webflux "s use of the built-in netty container as a startup container.
although I have just encountered some holes in my hands, I have seen the effect as I wish. This is the pom before I integrated spring-cloud-starter-netflix-eureka-server

    <dependencies>
        
        <!-- Spring Boot Web Flux  -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-webflux</artifactId>
        </dependency>
        
    </dependencies>

then I want to continue to introduce spring-cloud, and step on some pitfalls. However, I inadvertently see that the startup container in the startup log has been changed to tomcat, and the official setting mode has been tried. The introduction of spring-boot-starter-reactor-netty is not valid, but it is still tomcat startup

.

clipboard.png
this is the pom after I quote

    <dependencies>
        
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
        </dependency>
        
        <!-- Spring Boot Web Flux  -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-webflux</artifactId>
        </dependency>
        <!-- netty -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-reactor-netty</artifactId>
        </dependency>
        
    </dependencies>

spring-cloud-starter-netflix-eureka-server this reference will make my startup container tomcat, annotated.
I looked at the pom, of the reference and finally found his reference to spring-boot-starter-web in spring-cloud-netflix-eureka-server "s pom, which in turn refers to spring-boot-starter-tomcat.
I guess it is caused by this place, but I have not found a good solution to cover this startup. Is there any way to achieve my goal?


I haven't tried netty, but here's how to change jetty:

        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
            <exclusions>
                <exclusion>
                    <groupId>org.springframework.boot</groupId>
                    <artifactId>spring-boot-starter-tomcat</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-jetty</artifactId>
        </dependency>

first you need to exclude the tomcat container for springboot integration,

    <dependency>
        <groupId>org.springframework.cloud</groupId>
        <artifactId>spring-cloud-starter-netflix-eureka-server</artifactId>
        <exclusions>
            <exclusion>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-starter-tomcat</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    netty
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-reactor-netty</artifactId>
    </dependency>
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1bcf0f2-30c56.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1bcf0f2-30c56.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?