netgloo / spring-boot-samples

Spring Boot samples by Netgloo
http://netgloo.com
MIT License
1.52k stars 1.91k forks source link

use Spring 2.0.3 write an example #20

Open jiangjihui opened 6 years ago

jiangjihui commented 6 years ago

Hello, Nice work. I want to know how to use integrate JPA in Spring Boot, using Hibernate as JPA implementation and MySQL as database in SpringBoot 2.0.3,can you write an example for it?

ps:it may have a great differences to use SpringBoot 2.0.3.

ghost commented 6 years ago

+1 I also can't get it to work :(

raszkiewicz commented 4 years ago

+1 Same problem. Hibernate Search 5.7.x complains when search is performed. Switching to 5.8.x - not able to start that project.

muratia commented 4 years ago

Which version of MySQL are you using?

raszkiewicz commented 4 years ago

@muratia 8.0.15

muratia commented 4 years ago

Initially, the connection string must have all these parameters jdbc:mysql://localhost:3306/database?verifyServerCertificate=false&useSSL=false&requireSSL=false&useLegacyDatetimeCode=false&serverTimezone=UTC&allowPublicKeyRetrieval=true

raszkiewicz commented 4 years ago

I have it like ?autoReconnect=true&characterEncoding=UTF-8&verifyServerCertificate=false&useSSL=false&requireSSL=false

It works fine for 5.7.x when creating indexes but then it complains when does the search. I have found that 5.7.x is not compatible with SpringBoot 2.2 Hibernate ORM version so switched to 5.8.x but that will not start at all.