运行 war spring 野蝇上的 roo 2.0.0 RC1
Run war spring roo 2.0.0 RC1 on wildfly
我在 运行设置 spring roo 在 wildfly 10 上生成的 .war 时遇到问题
在创建项目的roo shell中执行如下命令:
项目设置 --topLevelPackage com.example --java 8 --packaging WAR
添加路径
server.contextPath=/teste
运行宁之后:
Mvn 包
它生成一个 .war 可以使用
Java-jar xxxxx-exec.war
正确启动并被浏览器访问。
当我在文件夹部署中播放它时,wildfly 不会旋转。
我发现我必须删除 tomcat 内置的 spring boot:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
然后添加:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
</dependency>
然后我创建了一个新的 .war 并尝试在 wildfly 中 运行,但它没有再次 运行,不是因为错误或其他原因,它说它开始了,但是当我尝试访问 url 时,它显示禁止。
抱歉我的英语不好,我是巴西人,我正在使用 google 翻译。
为了能够在 Wildfly
服务器中部署 Spring 启动应用程序,您需要从 [=] 扩展 @SpringBootApplication
.java class 12=] 并实现 configure
方法。
通过这些简单的步骤,您将能够在 tomcat、jboss、wildfly 等
中部署和 运行 您的应用程序
要了解有关您应该应用的更改的更多信息,请阅读 http://docs.spring.io/spring-boot/docs/1.5.4.RELEASE/reference/htmlsingle/#howto-create-a-deployable-war-file
希望对您有所帮助,
我在 运行设置 spring roo 在 wildfly 10 上生成的 .war 时遇到问题 在创建项目的roo shell中执行如下命令: 项目设置 --topLevelPackage com.example --java 8 --packaging WAR
添加路径 server.contextPath=/teste
运行宁之后: Mvn 包
它生成一个 .war 可以使用 Java-jar xxxxx-exec.war
正确启动并被浏览器访问。 当我在文件夹部署中播放它时,wildfly 不会旋转。 我发现我必须删除 tomcat 内置的 spring boot:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-tomcat</artifactId>
</exclusion>
</exclusions>
</dependency>
然后添加:
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<scope>provided</scope>
</dependency>
然后我创建了一个新的 .war 并尝试在 wildfly 中 运行,但它没有再次 运行,不是因为错误或其他原因,它说它开始了,但是当我尝试访问 url 时,它显示禁止。
抱歉我的英语不好,我是巴西人,我正在使用 google 翻译。
为了能够在 Wildfly
服务器中部署 Spring 启动应用程序,您需要从 [=] 扩展 @SpringBootApplication
.java class 12=] 并实现 configure
方法。
通过这些简单的步骤,您将能够在 tomcat、jboss、wildfly 等
中部署和 运行 您的应用程序要了解有关您应该应用的更改的更多信息,请阅读 http://docs.spring.io/spring-boot/docs/1.5.4.RELEASE/reference/htmlsingle/#howto-create-a-deployable-war-file
希望对您有所帮助,