-
Type: Bug
-
Status: Resolved
-
Priority: Minor
-
Resolution: Fixed
-
Affects Version/s: 7.4-SNAPSHOT
-
Fix Version/s: 7.4
-
Component/s: Annotations
-
Tags:
On MySQL when writing an annotation (now in core, since NXP-9300), we have, for instance for AnnotationRepositoryTest:
org.nuxeo.ecm.core.api.NuxeoException: Could not insert: INSERT INTO `relation` (`id`, `targetstring`, `predicate`, `source`, `targeturi`, `sourceuri`, `target`) VALUES (?, ?, ?, ?, ?, ?, ?) at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.insertSimpleRows(JDBCRowMapper.java:555) at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.writeCreates(JDBCRowMapper.java:457) at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.write(JDBCRowMapper.java:427) at org.nuxeo.ecm.core.storage.sql.SoftRefCachingRowMapper.write(SoftRefCachingRowMapper.java:352) at org.nuxeo.ecm.core.storage.sql.SessionImpl.doFlush(SessionImpl.java:357) at org.nuxeo.ecm.core.storage.sql.SessionImpl.flush(SessionImpl.java:330) at org.nuxeo.ecm.core.storage.sql.SessionImpl.save(SessionImpl.java:309) at org.nuxeo.ecm.core.storage.sql.ra.ConnectionImpl.save(ConnectionImpl.java:173) at org.nuxeo.ecm.core.storage.sql.coremodel.SQLSession.save(SQLSession.java:133) at org.nuxeo.ecm.core.api.AbstractSession.save(AbstractSession.java:1359) at org.nuxeo.ecm.platform.annotations.repository.service.AnnotatedDocumentEventListenerImpl.notifyEvent(AnnotatedDocumentEventListenerImpl.java:107) at org.nuxeo.ecm.platform.annotations.repository.service.AnnotatedDocumentEventListenerImpl.afterAnnotationCreated(AnnotatedDocumentEventListenerImpl.java:63) at org.nuxeo.ecm.platform.annotations.repository.core.AnnotationEventListener.afterAnnotationCreated(AnnotationEventListener.java:45) at org.nuxeo.ecm.platform.annotations.proxy.AnnotationServiceProxy.addAnnotation(AnnotationServiceProxy.java:90) at org.nuxeo.ecm.platform.annotations.service.AnnotationRepositoryTest.testAnnotateDocuments(AnnotationRepositoryTest.java:92) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:497) at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47) at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12) at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44) at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17) at org.nuxeo.runtime.test.runner.FeaturesRunner$15.evaluate(FeaturesRunner.java:472) at org.nuxeo.runtime.test.runner.FeaturesRunner$BeforeMethodRunStatement.evaluate(FeaturesRunner.java:351) at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:26) at org.nuxeo.runtime.test.runner.FeaturesRunner$BeforeSetupStatement.evaluate(FeaturesRunner.java:367) at org.nuxeo.runtime.test.runner.FeaturesRunner$AfterMethodRunStatement.evaluate(FeaturesRunner.java:398) at org.nuxeo.runtime.test.runner.FeaturesRunner$AfterTeardownStatement.evaluate(FeaturesRunner.java:417) at org.nuxeo.runtime.test.runner.FeaturesRunner$RulesFactory$1.evaluate(FeaturesRunner.java:530) at org.nuxeo.runtime.test.runner.RuntimeDeployment$DeploymentStatement.evaluate(RuntimeDeployment.java:265) at org.nuxeo.runtime.test.runner.RuntimeFeature$2$1.evaluate(RuntimeFeature.java:124) at org.junit.rules.RunRules.evaluate(RunRules.java:20) at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271) at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70) 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.nuxeo.runtime.test.runner.FeaturesRunner$AfterClassStatement.evaluate(FeaturesRunner.java:290) at org.nuxeo.runtime.test.runner.FeaturesRunner$RulesFactory$1.evaluate(FeaturesRunner.java:530) at org.nuxeo.runtime.test.runner.FeaturesRunner$BeforeClassStatement.evaluate(FeaturesRunner.java:273) at org.junit.rules.RunRules.evaluate(RunRules.java:20) at org.junit.runners.ParentRunner.run(ParentRunner.java:309) at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:86) at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:459) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:675) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:382) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:192) Caused by: java.sql.BatchUpdateException: Data truncation: Data too long for column 'targetstring' at row 1 at com.mysql.jdbc.PreparedStatement.executeBatchSerially(PreparedStatement.java:2028) at com.mysql.jdbc.PreparedStatement.executeBatch(PreparedStatement.java:1451) at org.nuxeo.ecm.core.storage.sql.jdbc.JDBCRowMapper.insertSimpleRows(JDBCRowMapper.java:540) ... 51 more Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'targetstring' at row 1 at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3607) at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3541) at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:2002) at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2163) at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2624) at com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:2127) at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2427) at com.mysql.jdbc.PreparedStatement.executeBatchSerially(PreparedStatement.java:1980) ... 53 more
This test has targetString values with ~100 and ~300 chars.
- depends on
-
NXP-9300 Annotation should use VCS relation graph instead of Jena
- Resolved