spring-boot-maven-plugin

spring-boot-maven-plugin >= 1.4.0 jar structure changes

泪湿孤枕 提交于 2019-12-02 02:34:43
问题 I have a spring-boot project where all integration tests are in separate module which starts the application module using spring-boot-maven-plugin during the integration-test phase and executes the suite against it. This construct worked fine until its been upgraded to 1.4.0.RELEASE. Now I get a ClassNotFoundException . After I checked the "1.4.0" jar structure I figured out that its different than the "1.3.6" one and all the packages are no more on top level but in BOOT-INF etc. folders (see

spring-boot-maven-plugin >= 1.4.0 jar structure changes

て烟熏妆下的殇ゞ 提交于 2019-12-02 02:01:33
I have a spring-boot project where all integration tests are in separate module which starts the application module using spring-boot-maven-plugin during the integration-test phase and executes the suite against it. This construct worked fine until its been upgraded to 1.4.0.RELEASE. Now I get a ClassNotFoundException . After I checked the "1.4.0" jar structure I figured out that its different than the "1.3.6" one and all the packages are no more on top level but in BOOT-INF etc. folders (see screen shots below) and the class loader can no more find the package defined in the "mainClass". Does

SpringBoot fully executable jar without dependencies inside

旧街凉风 提交于 2019-11-30 14:06:33
问题 NOTE: Please, before marking this question as a duplicate make sure you know the difference between executable JAR and fully executable SpringBoot JAR. The official Spring Boot documentation describes how to build fully executable JAR. Then generated JAR file can be linked from /etc/init.d/ and started/stopped/restarted/statused as a normal unix service without additional scripts or tools like JSVC. But the generated JAR contains all libraries and can be big enough in size (in my case 70Mb+).

resources in a Spring Boot application are missing from jar file when using Spring Boot Maven Plugin

百般思念 提交于 2019-11-30 05:10:33
I am using Spring-Boot v1.3.0.M5 with Maven v3.3.3. I used to be able to run my Spring Boot (boot) application from the console with this command. mvn clean package spring-boot:run However, I've had to revise my pom.xml to account for different environment builds. In particular, I am using Maven profiles to modify the properties files of boot application. Now when I run the previously mentioned command, the boot application fails to run and complains with the following exception. Caused by: java.lang.NumberFormatException: For input string: "${MULTIPART.MAXREQUESTSIZE}" I have a properties

“cannot find symbol” error in maven

こ雲淡風輕ζ 提交于 2019-11-29 12:16:55
问题 I see a lot of questions on stackoverflow on this. But still I'm not able to know what is the issue in my way of building projects. I've two spring boot projects: we-data and we-web. we-web is dependent on we-data. we-data compiles fine on maven. But we-web gives me above error. we-data pom: <?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:/

Spring Boot Maven Plugin - No BOOT-INF directory

无人久伴 提交于 2019-11-29 04:50:22
Between version 1.3.8.RELEASE of the spring-boot-maven-plugin and version 1.4.0.RELEASE - there has been a change in the generated package structure (if you extract the uber jar file) 1.3.8.RELEASE com, lib, META-INF and org directories 1.4.0.RELEASE has a BOOT-INF, META-INF and org directories Basically from 1.4.0.RELEASE onwards - all the classes and libs are in the BOOT-INF directory. Due to this - when you try to run a Spring Boot project on Amazon Lambda - it says that there is a jar not found as it cannot read the new Spring Boot Uber jar structure My question is - is it possible in the

resources in a Spring Boot application are missing from jar file when using Spring Boot Maven Plugin

隐身守侯 提交于 2019-11-29 02:57:31
问题 I am using Spring-Boot v1.3.0.M5 with Maven v3.3.3. I used to be able to run my Spring Boot (boot) application from the console with this command. mvn clean package spring-boot:run However, I've had to revise my pom.xml to account for different environment builds. In particular, I am using Maven profiles to modify the properties files of boot application. Now when I run the previously mentioned command, the boot application fails to run and complains with the following exception. Caused by:

Using Maven properties in application.properties in Spring Boot

荒凉一梦 提交于 2019-11-28 04:24:10
I'm trying to load properties from pom.xml into application.properties. I want to create two profiles: dev and prod to use different database urls. I'm using Jenkins as CI, in all my apps (Spring MVC mainly, without Boot project) are using maven profiles to deploy to Tomcat. There is any posibility to do this using maven properties? I tried something like that: spring.datasource.url=${jdbc.url} Before you do it, consider externalizing the properties file out of your deployable package. This way you can deploy the same compilation on every environment. It will save your Jenkins some work that

Spring Boot Maven Plugin - No BOOT-INF directory

梦想与她 提交于 2019-11-27 03:34:43
问题 Between version 1.3.8.RELEASE of the spring-boot-maven-plugin and version 1.4.0.RELEASE - there has been a change in the generated package structure (if you extract the uber jar file) 1.3.8.RELEASE com, lib, META-INF and org directories 1.4.0.RELEASE has a BOOT-INF, META-INF and org directories Basically from 1.4.0.RELEASE onwards - all the classes and libs are in the BOOT-INF directory. Due to this - when you try to run a Spring Boot project on Amazon Lambda - it says that there is a jar not

Using Maven properties in application.properties in Spring Boot

你说的曾经没有我的故事 提交于 2019-11-27 00:27:44
问题 I'm trying to load properties from pom.xml into application.properties. I want to create two profiles: dev and prod to use different database urls. I'm using Jenkins as CI, in all my apps (Spring MVC mainly, without Boot project) are using maven profiles to deploy to Tomcat. There is any posibility to do this using maven properties? I tried something like that: spring.datasource.url=${jdbc.url} 回答1: Before you do it, consider externalizing the properties file out of your deployable package.