尝试从本地打开连接时获取异常。但如果在其他机器上运行,则可以正常工作。
例外:
java.sql.SQLException: Can't enable noDatetimeStringSync and useTimezone configuration properties at the same time
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1078)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:989)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:975)
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:920)
at com.mysql.jdbc.ConnectionImpl.initializeDriverProperties(ConnectionImpl.java:3512)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:823)
at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:47)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:411)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:416)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:317)
at java.sql.DriverManager.getConnection(DriverManager.java:582)
at java.sql.DriverManager.getConnection(DriverManager.java:185)
at com.amadeus.selenium.utils.external.nrecampaigner.PublishTestResults.openDBConnection(PublishTestResults.java:289)
at com.amadeus.selenium.utils.external.nrecampaigner.PublishTestResults.publishData(PublishTestResults.java:59)
at com.amadeus.selenium.runner.SeleniumSEPTest.postExecutionSEP(SeleniumSEPTest.java:593)
at com.amadeus.selenium.runner.junit.SEPJUnitListener.testFinished(SEPJUnitListener.java:26)
at org.junit.runner.notification.RunNotifier$7.notifyListener(RunNotifier.java:191)
at org.junit.runner.notification.RunNotifier$SafeNotifier.run(RunNotifier.java:61)
at org.junit.runner.notification.RunNotifier.fireTestFinished(RunNotifier.java:188)
at org.junit.internal.runners.model.EachTestNotifier.fireTestFinished(EachTestNotifier.java:39)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:277)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
at com.amadeus.selenium.runner.junit.SEPJunit4ClassRunner.runChild(SEPJunit4ClassRunner.java:31)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:49)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
问题不在任何其他机器上。了解时区同步,但我的机器和数据库都在同一时区! [只是不同的机器..但不应该是任何问题]