Skip to content

Commit 423f0da

Browse files
committed
Configure MySQL connector to not try to use SSL.
This removes the following warning from the logs: 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. Fix #420
1 parent 581f592 commit 423f0da

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/resources/application-prod.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
spring.profiles: prod
22

3-
spring.datasource.url: jdbc:mysql://localhost:3306/mystamps?logger=com.mysql.jdbc.log.Slf4JLogger
3+
spring.datasource.url: jdbc:mysql://localhost:3306/mystamps?logger=com.mysql.jdbc.log.Slf4JLogger&useSSL=false
44
spring.datasource.username: mystamps
55
spring.datasource.password: q1
66
spring.datasource.driver-class-name: com.mysql.jdbc.Driver

src/main/resources/application-travis.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
spring.profiles: travis
22

3-
spring.datasource.url: jdbc:mysql://localhost:3306/mystamps?logger=com.mysql.jdbc.log.Slf4JLogger
3+
spring.datasource.url: jdbc:mysql://localhost:3306/mystamps?logger=com.mysql.jdbc.log.Slf4JLogger&useSSL=false
44
spring.datasource.username: travis
55
spring.datasource.password:
66
spring.datasource.driver-class-name: com.mysql.jdbc.Driver

0 commit comments

Comments
 (0)