Questions tagged as 'spring'

2
answers

How to create a Postgresql stored procedure from a Java code

Searching the internet for a solution to create a database on a Postgresql server for my Spring project, I found the following topic in StackOverflow: link where the following Stored procedure exists for this task: DO $do$ BEGIN IF EX...
asked by 07.05.2014 / 16:01
2
answers

___ ___ erkimt Unable to build entity manager factory (JPA Hibernate) ______ qstntxt ___

I am trying to make a connection with Hibernate and JPA, but when trying to create the connection or persist some data it executes the following error:

  

Dec 04, 2018 2:02:45 PM org.hibernate.ejb.HibernatePersistence   WARN: logDeprecation HHH015016: Encountered to deprecated   javax.persistence.spi.PersistenceProvider   [org.hibernate.ejb.HibernatePersistence]; use   [org.hibernate.jpa.HibernatePersistenceProvider] instead. Dec 04, 2018   2:02:45 PM org.hibernate.ejb.HibernatePersistence logDeprecation WARN:   HHH015016: Encountered to deprecated   javax.persistence.spi.PersistenceProvider   [org.hibernate.ejb.HibernatePersistence]; use   [org.hibernate.jpa.HibernatePersistenceProvider] instead. Dec 04, 2018   2:02:45 PM org.hibernate.ejb.HibernatePersistence logDeprecation WARN:   HHH015016: Encountered to deprecated   javax.persistence.spi.PersistenceProvider   [org.hibernate.ejb.HibernatePersistence]; use   [org.hibernate.jpa.HibernatePersistenceProvider] instead. Dec 04, 2018   2:02:45 PM org.hibernate.jpa.internal.util.LogHelper   INFO: HHH000204: LogPersistenceUnitInformation   PersistenceUnitInfo [name: context ...] Dec 04, 2018 2:02:45 PM   INFO: HHH000412: hibernate Core   {4.3.0.Final} Dec 04, 2018 2:02:45 PM org.hibernate.cfg.Environment    INFO: HHH000206: hibernate.properties not found Dec 04, 2018   INFO: 2:02:45 PM org.hibernate.cfg.Environment buildBytecodeProvider   HHH000021: Bytecode provider name: javassist Dec 04, 2018 2:02:45 PM   org.hibernate.annotations.common.reflection.java.JavaReflectionManager    INFO: HCANN000001: Hibernate Commons Annotations   {4.0.4.Final} Dec 04, 2018 2:02:45 PM   org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl   configure INFO: HHH000402: Using Hibernate built-in connection pool   (not for production use!) Unable to build entity manager factory

My pom.xml

%pre%

My persistence.xml

%pre%

My Main class

%pre%     
______ azszpr348573 ___

I am trying to make a connection with Hibernate and JPA, but when trying to create the connection or persist some data it executes the following error:    Dec 04, 2018 2:02:45 PM org.hibernate.ejb.HibernatePersistence   WARN: logDeprecation H...
asked by 04.12.2018 / 18:06
2
answers

Transaction control application rest in spring

I was studying a bit about the @Transactional annotation (Spring version), and I had a question. According to a publication made in DevMedia , the way more correct "to use is noting in our business method, because there can have several acti...
asked by 25.05.2018 / 19:09
1
answer

Upload and files using API Rest

I'm creating an end-point to output a file in the format (.txt), but my entity is not just the file. There are other attributes, so I need to send json this way to the server: { "nomeCliente" : "teste", "arquivo": // aqui eu enviaria o arquiv...
asked by 20.03.2018 / 18:12
1
answer

3 doubts of new user post with spring boot

I have the following doubts when saving a user to an api using spring boot. 1) Is the best way to check if email already exists? 2) In case I am sending the id of the user just saved, but it is not being sent as json, it is only sending th...
asked by 01.04.2018 / 04:16
1
answer

Spring boot modules via maven do not interact

I'm using Spring Boot to create a web service RESTFul and a SOAP, each in a module but both in a single project. So I decided to separate my domain layer into a third module since it is the same for both types of web services and so I could reus...
asked by 23.03.2018 / 14:55
1
answer

Annotation @Version

Using the @Version Annotation, shows this error when trying to update.    18: 25: 16.650 [http-nio-8080-exec-84] ERROR   br.com.netsoft.controller.todos.AutomationMonetariaItemController -   Row was updated or deleted by another transaction (...
asked by 07.01.2018 / 13:49
1
answer

RestController Spring, how to limit the number of requests! [closed]

Dear friends, I have an API Rest with RestController of Spring, it receives hundreds of concurrent posts, and with each post, I need to query and store data in the database. The problem is that this is generating an absurd processing on...
asked by 08.12.2017 / 06:04
1
answer

When I make a request in my API Rest with Spring boot, it is coming with one more item

I have already debugged and the result is a correct list, but when I make the request in the Postman, there is one more item. Looks like an accountant. Can someone tell me what this is and how to pull it off? Thisismycontroller.importjavax.s...
asked by 30.11.2017 / 02:34
1
answer

Error requesting GET, JavaScript, Angular, Spring, Java

I'm having an error opening the screen with the search results in the database. The error is in the image below. Debugging, data is coming from the database. In the other image, the Server Log appears MyNeighborhoods@Entity@Table(nam...
asked by 25.09.2017 / 15:10