Category "spring-boot"

Spring Boot shutdown hook

How can I register/add a custom shutdown routine that shall fire when my Spring Boot application shuts down? Scenario: I deploy my Spring Boot application to a

Mono class in Java: what is, and when to use?

I have this following code: import org.springframework.http.MediaType; import org.springframework.stereotype.Component; import org.springframework.web.reactive

Connecting Mongodb Atlas from Spring boot

I i am new to the Mongodb with Spring Boot.And i have MONGODB ATLAS URI Connection String mongodb://userName:<PASSWORD>@icarat-shard-00-00-7lopx.mongodb.

How to generate json data from Json Schema Programmatically in Java

I am trying to create Body-parameter(JSON) for my POST Api , which is a JSON request . All I have is the JSON Schema . I am trying to come up with a list of dif

How to resolve the Exception from WebTestClient?

How can I achieve the following with WebTestClient? @Autowired private MockMvc mvc; mvc.perform(req) .andExpect(status) .andReturn().getResolve

Why I get 404 error in spring boot post request using Thymeleaf

I user spring boot to create an integral calculator. I got a strange 404 error while I try to handle post request. Here is my controller class that should handl

Exception in thread "main" java.time.DateTimeException: Invalid value for MonthOfYear (valid values 1 - 12): 0 when i am using Google Map jar

I am working on Geo Fencing So I am using Google Dependencies "android-maps-utils" and "geopackage-android-map" I installed these jar in my system and using t

Use WebSphere MQ as the messaging layer for Springboot applications

I need to use WebSphere MQ as the messaging layer for my Springboot apps. Using RabbitMQ, Kafka or activeMQ is straight forward with Springboot and there are to

Using @TestConfiguration doesn't work as Context for @SpringBootTest

I've written an integration test that uses @SpringBootTest annotation. Since my app has many beans, I want to load in the integration test only the beans that a

Possibly consider using a shorter maxLifetime value - hikari connection pool spring boot

After starting my SpringBoot application, getting an exception on few minutes of the server startup. Did not use any HikariPool Configuration externally, Spring

Spring cache and Spring data redis

Spring cache + Spring redis: Spring provides a caching abstraction package spring-boot-starter-cache which basically provides method level annotations to cache

@DataMongoTest is creating a null MongoTemplate

I have been trying to follow the instructions in the link below to try to add an automatically configured Embedded MongoDB Instance for Cucumber Integration tes

Handling custom error code in spring cloud load balancer

In my current project, one of our microservices calls a REST Api of an another microservice and in an error scenario it returns a custom(469) error code. I'm us

What does joinPoint.proceed() do?

It is my first approaching to AOP. I've a spring-boot application with one Aspect, a Logger. Searching i reach to the conclusion that the @Around method execute

Plugin [id: 'org.springframework.boot', version: '2.2.4.RELEASE'] was not found in any of the following sources:

I have just downloaded the springboot project from http://start.spring.io/. After running it I got this error. * What went wrong: Plugin [id: 'org.springframewo

SpringBoot Web MVC Application cannot resolve JSP views

I am trying to implement a web application using Springboot. but when I request methods I get 404 Error. Springboot cannot find Jsp files. this is my Controller

Junit (4.12) is not executing after spring-boot 2.6.2 migration

I have migrated from Spring to Spring-boot version 2.6.2. mvn clean install is successful but none of the junit(version 4.12) is executing. After few research I

which dependency is overriding version of a transitive dependency (Maven)

I'm using the below dependency: <dependency> <groupId>com.azure</groupId> <artifactId>azure-identity</artifactId> <versio

Caused by: org.hibernate.HibernateException: Access to DialectResolutionInfo cannot be null when 'hibernate.dialect' not set.

I am getting exception even after setting hibernate.dialect property. I am using hibernate 5.0.11 with spring boot 1.4.2 and mysql version as 5.7 application.p

Error in multipart file upload: Failed to parse multipart servlet request; nested exception is java.io.IOException

We have an API to upload document. We got a very strange error and we got this error for the first time on our server. This is the API structure. @PatchMapping(