部署问题,即使在pom中也找不到类

问题描述 投票:0回答:1

[当我尝试运行我的应用程序时,出现以下错误消息:

cannot Deploy pro_jpa
deploy is failing=Error occurred during deployment: Exception while deploying the app [pro_jpa] : java.lang.NoClassDefFoundError: com/google/common/cache/CacheLoader. Please see server.log for more details.

所以我将此添加到pom:

<!-- https://mvnrepository.com/artifact/com.google.guava/guava -->
    <dependency>
        <groupId>com.google.guava</groupId>
        <artifactId>guava</artifactId>
        <version>10.0.1</version>
    </dependency>

但是,即使它应该将所需的jar添加到应用中,也无法解决问题。

我还试图将guava.jar添加到服务器库中,但它没有任何改变。

如果有人有主意,谢谢。

java eclipse glassfish noclassdeffounderror classnotfoundexception
1个回答
0
投票
添加到依赖项:

运行时

© www.soinside.com 2019 - 2024. All rights reserved.