首页 新闻 会员 周边 捐助

项目启动有时候老是启动不了怎么回事,

0
悬赏园豆:5 [已解决问题] 解决于 2022-03-29 10:25

default profiles: default
11:00:45.769 [main] WARN o.s.b.w.s.c.AnnotationConfigServletWebServerApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [com.inspur.beijing.visualized.VisualizedApplication]; nested exception is java.io.FileNotFoundException: class path resource [com/inspur/beijing/common/base/BaseController.class] cannot be opened because it does not exist
11:00:45.772 [main] INFO o.s.b.a.l.ConditionEvaluationReportLoggingListener -

Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
11:00:45.784 [main] ERROR o.s.boot.SpringApplication - Application run failed
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to parse configuration class [com.inspur.beijing.visualized.VisualizedApplication]; nested exception is java.io.FileNotFoundException: class path resource [com/inspur/beijing/common/base/BaseController.class] cannot be opened because it does not exist
at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:188)

以上是错误信息

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>beijing-brain-platform</artifactId>
<groupId>com.inspur.beijing</groupId>
<version>1.0.0</version>
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>beijing-brain-visualized</artifactId>

<properties>
    <java.version>1.8</java.version>
    <mybatis-plus.version>3.3.1</mybatis-plus.version>
    <kingbase.version>8.2.0</kingbase.version>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.compiler.source>8</maven.compiler.source>
    <maven.compiler.target>8</maven.compiler.target>
    <dynamic.version>3.2.0</dynamic.version>
</properties>

<dependencies>
    <dependency>
        <groupId>com.inspur.beijing</groupId>
        <artifactId>beijing-brain-common</artifactId>
        <version>1.0.0</version>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter</artifactId>
    </dependency>
    <dependency>
        <groupId>com.baomidou</groupId>
        <artifactId>mybatis-plus-boot-starter</artifactId>
        <version>${mybatis-plus.version}</version>
    </dependency>
    <dependency>
        <groupId>com.kingbase8</groupId>
        <artifactId>kingbase8</artifactId>
        <version>${kingbase.version}</version>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-freemarker</artifactId>
    </dependency>

    <dependency>
        <groupId>org.jsoup</groupId>
        <artifactId>jsoup</artifactId>
        <version>1.10.2</version>
    </dependency>
    <dependency>
        <groupId>org.apache.commons</groupId>
        <artifactId>commons-lang3</artifactId>
    </dependency>
    <!-- jfinal 核心包 -->
    <dependency>
        <groupId>com.jfinal</groupId>
        <artifactId>jfinal</artifactId>
        <version>2.2</version>
    </dependency>
    <dependency>
        <groupId>com.jfinal</groupId>
        <artifactId>cos</artifactId>
        <version>26Dec2008</version>
    </dependency>

    <!-- https://mvnrepository.com/artifact/com.baomidou/dynamic-datasource-spring-boot-starter -->
    <dependency>
        <groupId>com.baomidou</groupId>
        <artifactId>dynamic-datasource-spring-boot-starter</artifactId>
        <version>${dynamic.version}</version>
    </dependency>
    <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-data-redis</artifactId>
    </dependency>
    <dependency>
        <groupId>org.redisson</groupId>
        <artifactId>redisson</artifactId>
    </dependency>

</dependencies>
<build>
    <finalName>beijing-brain-visualized2.0-16-9-1.0.0</finalName>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>
    </plugins>
</build>

</project>

这个是pom文件
上网搜了说可能是依赖版本的问题,也有可能是注解的问题,但他有时候好好的,有时候一点都跑不起来,我人都快麻了

sunny-JJ的主页 sunny-JJ | 初学一级 | 园豆:-3
提问于:2022-03-23 11:04
< >
分享
最佳答案
0

重启,清缓存,如果代码没有变化的话,

收获园豆:5
人间春风意 | 老鸟四级 |园豆:2784 | 2022-03-23 19:19

这种情况都是有原因的,找找,可能是哪一部分写的不行,拖死了

人间春风意 | 园豆:2784 (老鸟四级) | 2022-03-23 19:20

@人间春风意: 刚接手的项目,主要是我技术不太行,结构也简单,就很烦

sunny-JJ | 园豆:-3 (初学一级) | 2022-03-24 18:37

@灬从〇开始: 什么类型的项目?一般不都是依赖下载好,测试区的配置文件配好,直接跑

人间春风意 | 园豆:2784 (老鸟四级) | 2022-03-24 18:55
其他回答(1)
0

.FileNotFoundException: class path resource [com/inspur/beijing/common/base/BaseController.class] cannot be opened because it does not exist

楠木大叔 | 园豆:2083 (老鸟四级) | 2022-03-23 12:35
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册