spring-boot-maven-plugin

Spring boot spring-boot:run in eclipse does not kill background java process

谁说胖子不能爱 提交于 2021-02-10 14:21:13
问题 I am running a spring boot web application through eclipse. In eclipse, I have configured spring-boot:run maven goal. When run, the server starts up properly within the eclipse and I can invoke myactions. When I want to stop the server, I just stop it by clicking on RED icon in Console window. The process seems to be stopped but server runs in the background and the java process can be seen as active in TaskManager. Any idea, what could have been wrong ? Why the background process in not

ClientHttpRequestInterceptor not called in springboot

自古美人都是妖i 提交于 2021-02-08 08:28:18
问题 I am trying to add logging to my application using ClientHttpRequestInterceptor.My interceptor is not being called. Not sure what is going wrong here - Here is my code - @Component @Slf4j public final class RestTemplateInterceptor implements ClientHttpRequestInterceptor { protected static final LoggingAspect aspect = new LoggingAspect(); private final RequestContext requestContext; private boolean logResponseBody = true; public RestTemplateInterceptor(RequestContext requestContext) { this

Spring Boot With Maven Shade Plugin - Controllers not mapped (404 Error)

半城伤御伤魂 提交于 2021-02-07 11:47:31
问题 For my Spring boot application with embedded tomcat, due to some limitation I need to do away with spring-boot-maven-plugin and need to use maven-shade-plugin . With maven package command I could successfully create the jar file. However, all my controllers stopped working and gives me 404 error. Also static content placed in my resources folder are not being served anymore. Always getting 404 error. my pom.xml <dependencyManagement> <dependencies> <dependency> <!-- Import dependency

Maven Spring Boot Cannot Push Docker Image

喜你入骨 提交于 2021-01-28 14:38:20
问题 Using Spring Boot 2.4.0, I'm trying to configure the spring-boot:build-image task to push an image to my private GitHub container registry. I used these instructions to configure my POM as follows: <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <image> <name>ghcr.io/abc/${project.artifactId}:${project.version}</name> <publish>true</publish> </image> <docker> <publishRegistry> <username>abc</username> <token>mytoken</token

Maven Spring Boot Cannot Push Docker Image

霸气de小男生 提交于 2021-01-28 14:31:08
问题 Using Spring Boot 2.4.0, I'm trying to configure the spring-boot:build-image task to push an image to my private GitHub container registry. I used these instructions to configure my POM as follows: <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <image> <name>ghcr.io/abc/${project.artifactId}:${project.version}</name> <publish>true</publish> </image> <docker> <publishRegistry> <username>abc</username> <token>mytoken</token

Install package in Docker image created by Spring Boot Maven plugin

|▌冷眼眸甩不掉的悲伤 提交于 2021-01-05 07:23:25
问题 My Spring Boot project contains the Spring Boot Maven Plugin which I use for building a Docker image by running mvn spring-boot:build-image . <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <executions> <execution> <phase>package</phase> <goals> <goal>build-image</goal> </goals> </execution> </executions> </plugin> When deploying this image to a Docker stack I need to run a healthcheck using the curl command but unfortunately curl is not

Install package in Docker image created by Spring Boot Maven plugin

本秂侑毒 提交于 2021-01-05 07:21:08
问题 My Spring Boot project contains the Spring Boot Maven Plugin which I use for building a Docker image by running mvn spring-boot:build-image . <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <executions> <execution> <phase>package</phase> <goals> <goal>build-image</goal> </goals> </execution> </executions> </plugin> When deploying this image to a Docker stack I need to run a healthcheck using the curl command but unfortunately curl is not

Building docker image with spring boot 2.4.1 failes with “Missing 'io.buildpacks.stack.id' stack label”

大城市里の小女人 提交于 2021-01-01 08:14:58
问题 I'm, trying to build a docker image with ./mvnw -DskipTests spring-boot:build-image using spring boot 2.4.1 and java 11 (openjdk version "11.0.9" 2020-10-20 LTS) on RHEL7. I do this on a host behind a strict firewall so I have to fetch the build- and runimage from a private repo. I have configured the spring-boot-maven-plugin to use this repo: <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <docker> <builderRegistry>

Building docker image with spring boot 2.4.1 failes with “Missing 'io.buildpacks.stack.id' stack label”

大兔子大兔子 提交于 2021-01-01 08:13:32
问题 I'm, trying to build a docker image with ./mvnw -DskipTests spring-boot:build-image using spring boot 2.4.1 and java 11 (openjdk version "11.0.9" 2020-10-20 LTS) on RHEL7. I do this on a host behind a strict firewall so I have to fetch the build- and runimage from a private repo. I have configured the spring-boot-maven-plugin to use this repo: <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <configuration> <docker> <builderRegistry>

Spring Boot + Elastic Beanstalk .ebextensions in JAR

旧时模样 提交于 2020-12-01 09:30:26
问题 I have a very standard Spring Boot application (with a application.properties properties file located in standard /src/main/resources folder) which I'm deploying on AWS Elastic Beanstalk as a "fat JAR". It works quite nicely but there is an issue with image uploading on the server. After some investigation it seems that the NGINX configuration needs to be tweaked (increase client_max_body_size to something so it can accept uploads up to 10MB ) and therefore I have added an .ebextensions