Skip to content

Tag: spring-boot

Spring not calling the default constructor

I have made a simple spring boot application: Here I have put @Component annotation on the Student class. So I can get the student object from the application context. But the id and name are not initialized as per the default constructor. What could be the reason for this? Does spring not call the default co…

JMS, consume a message from a topic only once

I have a requirement to establish a point to point communication with publisher and consumer in my application. What I’m given is a topic. So I should make sure the message in the topic will be consumed only once and only one instance should consume it. (There are multiple instances of the consumer.) I …

Bean that could not be found Spring Boot

I have a problem when trying to start my Spring Boot application with tokenization. This is my service class: This is my config class: And I get the following error when I try to run my Application: I dont understand why i get this error. Answer I solved it. The problem was that the package where the config l…

Application failed after added swagger configuration

I’m using spring boot and I want to add swagger configuration, the problem is after I run the application I get this error: In my class I added this methods: In my pom.xml I added this dependencies: I can’t understand what is wrong, I followed online solution asking me to add @EnableSwagger2WebMv …