Pessoal para resolver o erro abaixo eu tive que inckuir isto na url:"useSSL=false" Estou usando este jar do mysql mysql mysql-connector-java 5.1.38
Nas classe JPAConfiguration
Meu método ficou assim
@Bean
public DataSource dataSource() {
DriverManagerDataSource dataSource = new DriverManagerDataSource();
dataSource.setUsername("root");
dataSource.setPassword("root");
dataSource.setUrl("jdbc:mysql://127.0.0.1:3306/casadocodigo?useSSL=false");
dataSource.setDriverClassName("com.mysql.jdbc.Driver");
return dataSource;
}
Sun Jan 16 11:58:07 BRT 2022 WARN: Establishing SSL connection without server's identity verification is not recommended. According to MySQL 5.5.45+, 5.6.26+ and 5.7.6+ requirements SSL connection must be established by default if explicit option isn't set. For compliance with existing applications not using SSL the verifyServerCertificate property is set to 'false'. You need either to explicitly disable SSL by setting useSSL=false, or set useSSL=true and provide truststore for server certificate verification. com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
The last packet successfully received from the server was 390 milliseconds ago. The last packet sent successfully to the server was 383 milliseconds ago.