[英]unable to launch springboot application deployed on websphere 8.5.5
I have made a java application with spring boot 1.4.3.release (starter parent dependency) and hibernate 5.0.12 along with a database connection to Oracle 11g which is to be deployed on Websphere 8.5.5.我制作了一个带有 spring boot 1.4.3.release(starter parent 依赖项)和 hibernate 5.0.12 的 java 应用程序,以及到要部署在 Websphere 8.5.5 上的 Oracle 11g 的数据库连接。 The problem is that the war file of the above app gets deployed on websphere but on starting it error is shown as per the below image.
问题是上述应用程序的 war 文件被部署在 websphere 上,但在启动时错误如下图所示。
I have also tried checking for any issues with Hibernate version and JPA problems.我还尝试检查 Hibernate 版本和 JPA 问题的任何问题。
The list of dependencies I have added:我添加的依赖项列表:
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.4.3.RELEASE</version>
</parent>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<java.version>1.8</java.version>
</properties>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
<scope>provided</scope>
</dependency>
<!-- hot swapping, disable cache for template, enable live reload -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
</dependency>
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi</artifactId>
<version>3.15</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jpa</artifactId>
</dependency>
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.15</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>1.3.2</version>
</dependency>
<dependency>
<groupId>com.googlecode.json-simple</groupId>
<artifactId>json-simple</artifactId>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
</dependency>
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc6</artifactId>
<version>11.2.0.3</version>
</dependency>
<!-- Optional, for bootstrap -->
<dependency>
<groupId>org.webjars</groupId>
<artifactId>bootstrap</artifactId>
<version>3.3.7</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>
</dependencies>
<build>
<finalName>oracleapp</finalName>
<plugins>
<!-- Package as an executable jar/war -->
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
Please help me out.请帮帮我。
Given below is the project structure下面给出的是项目结构
The problem you are having is an issue of where your Main class is located at.您遇到的问题是您的 Main 类位于何处。 You need to move it to the root package, where it can see all other packages.
您需要将它移动到根包,在那里它可以看到所有其他包。 Something like the following structure.
类似于以下结构。
src/main/java
-> SpringBootWebApplication (which I believe is your Main class)
-> All other packages
This will allow your main to find the files you are looking for.这将使您的主文件找到您要查找的文件。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.