Questions tagged as 'spring-boot'

2
answers

Difference between annotations @Component, @Repository and @Service in Spring?

The previous entries are very related, so my questions are as follows: 1- Can the annotations @Component, @Repository and @Service be used interchangeably in Spring or do they provide any particular functionality besides...
asked by 21.06.2018 / 02:49
3
answers

Set default schema = ALGO in oracle using Spring Boot and Spring JDBC

I am now working with Oracle and Spring JDBC, but I do not want to use the schema in my sql statements: Example: Select * from SCHEMA.table Is there any way to set the default schema in application.properties or application.yml?...
asked by 22.06.2016 / 19:10
1
answer

Differences between Spring boot and Spring MVC [closed]

I see that when executing a Spring boot application raises a server in 8080, I would like to know what is the difference between these two aspects, with a clear example maybe.     
asked by 17.11.2017 / 16:45
3
answers

Error NullPointerException in Java (Spring-boot)

I already know that this is a very common error and it happens when trying to access a NULL type object, the problem is that I do not know why it is NULL if I'm supposed to be instantiating it, I have a class called NoteController in the that in...
asked by 28.03.2018 / 21:35
1
answer

Configure Spring Boot with two DataSources

I am using Spring Boot 2.X with Hibernate 5.X to connect two MySQL databases (Bar and Foo). I want to be able to list the different entities, with all their attributes (ID, Name and relationships @OneToMany/@ManyToOne ), of each of the...
asked by 07.03.2018 / 17:31
1
answer

Create a project that contains @repository, @service and @controller

I do not know how to create a new project with spring initializr that contains @repository, @service, and @controller, so that the controller dependency is necessary check the following box, here a screenshot: but for the others that must...
asked by 28.04.2017 / 15:38
3
answers

spring boot does not serialize json

I am developing a web application with spring boot. When I make a query using a jparepositoy of the findAll type, I intend to obtain the list of users and their corresponding role. In the response obtained, all the properties of my entity...
asked by 19.07.2016 / 12:24
1
answer

Spring boot WebService Rest (CUSTOMIZE RESPONSE)

I want to customize the answer when it is a Status 405 Method Not Allowed { "timestamp": 1527270306717, "status": 405, "error": "Method Not Allowed", "exception": "org.springframework.web.HttpRequestMethodNotSupportedException"...
asked by 25.05.2018 / 19:58
1
answer

Error creating table using Spring Boot and postgres

Greetings to all! I am trying to create an application using Spring and Postgres. Currently I have 3 entities which are: User , Role and UserRole User import lombok.AllArgsConstructor; import lombok.Builder; import...
asked by 19.04.2018 / 21:53
0
answers

Problems when inserting in a second database (two schema mysql) Spring Boot

I have a problem when trying to insert, modify or delete a record (by requesting post, put and delete) in a second database. In the application I have two datasource defined for two schemas in a Mysql database. The problem is that in the firs...
asked by 19.11.2018 / 06:47