Startup with pac4j-webflow is always abnormal when using cas embedded operation

when using cas-server-webapp-tomcat and cas-server-support-pac4j-webflow, when using embedded startup, a lot of related exceptions are reported that the class cannot be found, but when packaged into war, it is no problem to deploy in tomcat. I would like to ask how to solve the problem when embedded. Do you want to add dependencies bit by bit? here is my maven

   <build>
    <plugins>

        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
            <version>${springboot.version}</version>
            <configuration>
                <mainClass>${mainClassName}</mainClass>
                <addResources>true</addResources>
                <executable>${isExecutable}</executable>
                <layout>WAR</layout>
            </configuration>
            <executions>
                <execution>
                    <goals>
                        <goal>repackage</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-war-plugin</artifactId>
            <version>3.2.0</version>
            <configuration>
                <warName>cas-management</warName>
                <failOnMissingWebXml>false</failOnMissingWebXml>
                <recompressZippedFiles>false</recompressZippedFiles>
                <archive>
                    <compress>false</compress>
                    <manifestFile>${manifestFileToUse}</manifestFile>
                </archive>
                <overlays>
                    <overlay>
                        <groupId>org.apereo.cas</groupId>
                        <artifactId>cas-server-webapp-tomcat</artifactId>
                        <excludes>
                            <exclude>WEB-INF/classes/services/*</exclude>
                            <exclude>WEB-INF/classes/application.*</exclude>
                            <exclude>WEB-INF/classes/services/*.json</exclude>
                        </excludes>
                    </overlay>
                </overlays>
            </configuration>
        </plugin>

        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.8.0</version>
            <configuration>
                <release>${java.version}</release>
            </configuration>
        </plugin>
    </plugins>
    <finalName>cas-management-tomcat</finalName>
</build>

<dependencies>


    <dependency>
        <groupId>org.apereo.cas</groupId>
        <artifactId>cas-server-webapp-tomcat</artifactId>
        <version>${cas.version}</version>
        <type>war</type>
    </dependency>

    <dependency>
        <groupId>org.apereo.cas</groupId>
        <artifactId>cas-server-support-pac4j-webflow</artifactId>
        <version>${cas.version}</version>
    </dependency>

    <dependency>
        <groupId>com.fasterxml</groupId>
        <artifactId>classmate</artifactId>
        <version>1.4.0</version>
    </dependency>


</dependencies>

<properties>

    <cas.version>5.3.3</cas.version>
    <springboot.version>2.0.5.RELEASE</springboot.version>
    <mainClassName>org.springframework.boot.loader.WarLauncher</mainClassName>
    <isExecutable>false</isExecutable>
    <manifestFileToUse>${project.build.directory}/war/work/org.apereo.cas/cas-server-webapp-tomcat/META-INF/MANIFEST.MF</manifestFileToUse>
    <java.version>10</java.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

run-related exceptions:

Caused by: java.lang.ClassNotFoundException: javax.servlet.ServletException

other exceptions will be reported after adding the servlet dependency. Is my operation wrong?

Jul.22,2021
Menu