|
[ https://issues.apache.org/jira/browse/OFBIZ-9839?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16207992#comment-16207992 ] Jacques Le Roux commented on OFBIZ-9839: ---------------------------------------- Hi Yash, Did the tests pass at your end? Because here I get that: {code} C:\projectsASF\ofbiz>svn up && g cleanAll eclipse loadAll testIntegration [...] 2017-10-17 19:03:00,982 |main |EntitySaxReader |E| An error occurred saving the data, rolling back transaction (true) org.xml.sax.SAXException: Cannot store value with incomplete primary key with more than 1 primary key field: [GenericEntity:SecurityGroupPermission][groupId,SUPER(java.lang.String)][permissionId,ASSETMAINT_AD MIN(java.lang.String)] at org.apache.ofbiz.entity.util.EntitySaxReader.endElement(EntitySaxReader.java:397) ~[ofbiz.jar:?] at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source) ~[xercesImpl-2.9.1.jar:?] at javax.xml.parsers.SAXParser.parse(SAXParser.java:195) ~[?:1.8.0_112] at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:231) [ofbiz.jar:?] at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:205) [ofbiz.jar:?] at org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:263) [ofbiz.jar:?] at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadData(EntityDataLoadContainer.java:436) [ofbiz.jar:?] at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadDataForDelegator(EntityDataLoadContainer.java:183) [ofbiz.jar:?] at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.init(EntityDataLoadContainer.java:115) [ofbiz.jar:?] at org.apache.ofbiz.base.container.ContainerLoader.loadContainer(ContainerLoader.java:135) [ofbiz.jar:?] at org.apache.ofbiz.base.container.ContainerLoader.loadContainersFromConfigurations(ContainerLoader.java:100) [ofbiz.jar:?] at org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:70) [ofbiz.jar:?] at org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:229) [ofbiz.jar:?] at org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71) [ofbiz.jar:?] at org.apache.ofbiz.base.start.Start.main(Start.java:85) [ofbiz.jar:?] 2017-10-17 19:03:00,991 |main |TransactionUtil |I| Transaction rolled back org.apache.ofbiz.base.start.StartupException: Cannot init() dataload-container (org.apache.ofbiz.entity.GenericEntityException: [loadData]: Error loading XML Resource "file:/C:/projectsASF/ofbiz/plugins/asset maint/data/AssetMaintSecurityPermissionSeedData.xml"; Error was: A transaction error occurred reading data (A transaction error occurred reading data) ([loadData]: Error loading XML Resource "file:/C:/project sASF/ofbiz/plugins/assetmaint/data/AssetMaintSecurityPermissionSeedData.xml"; Error was: A transaction error occurred reading data (A transaction error occurred reading data))) at org.apache.ofbiz.base.container.ContainerLoader.loadContainer(ContainerLoader.java:137) at org.apache.ofbiz.base.container.ContainerLoader.loadContainersFromConfigurations(ContainerLoader.java:100) at org.apache.ofbiz.base.container.ContainerLoader.load(ContainerLoader.java:70) at org.apache.ofbiz.base.start.StartupControlPanel.loadStartupLoaders(StartupControlPanel.java:229) at org.apache.ofbiz.base.start.StartupControlPanel.start(StartupControlPanel.java:71) at org.apache.ofbiz.base.start.Start.main(Start.java:85) Caused by: org.apache.ofbiz.base.container.ContainerException: org.apache.ofbiz.entity.GenericEntityException: [loadData]: Error loading XML Resource "file:/C:/projectsASF/ofbiz/plugins/assetmaint/data/AssetM aintSecurityPermissionSeedData.xml"; Error was: A transaction error occurred reading data (A transaction error occurred reading data) ([loadData]: Error loading XML Resource "file:/C:/projectsASF/ofbiz/plugin s/assetmaint/data/AssetMaintSecurityPermissionSeedData.xml"; Error was: A transaction error occurred reading data (A transaction error occurred reading data)) at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadData(EntityDataLoadContainer.java:444) at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadDataForDelegator(EntityDataLoadContainer.java:183) at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.init(EntityDataLoadContainer.java:115) at org.apache.ofbiz.base.container.ContainerLoader.loadContainer(ContainerLoader.java:135) ... 5 more Caused by: org.apache.ofbiz.entity.GenericEntityException: [loadData]: Error loading XML Resource "file:/C:/projectsASF/ofbiz/plugins/assetmaint/data/AssetMaintSecurityPermissionSeedData.xml"; Error was: A tr ansaction error occurred reading data (A transaction error occurred reading data) at org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:270) at org.apache.ofbiz.entityext.data.EntityDataLoadContainer.loadData(EntityDataLoadContainer.java:436) ... 8 more Caused by: org.xml.sax.SAXException: A transaction error occurred reading data org.xml.sax.SAXException: Cannot store value with incomplete primary key with more than 1 primary key field: [GenericEntity:SecurityGroupPermission][groupId,SUPER(java.lang.String)][permissionId,ASSETMAINT_AD MIN(java.lang.String)] at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:246) at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:205) at org.apache.ofbiz.entity.util.EntityDataLoader.loadData(EntityDataLoader.java:263) ... 9 more Caused by: org.xml.sax.SAXException: Cannot store value with incomplete primary key with more than 1 primary key field: [GenericEntity:SecurityGroupPermission][groupId,SUPER(java.lang.String)][permissionId,AS SETMAINT_ADMIN(java.lang.String)] at org.apache.ofbiz.entity.util.EntitySaxReader.endElement(EntitySaxReader.java:397) at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source) at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source) at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source) at javax.xml.parsers.SAXParser.parse(SAXParser.java:195) at org.apache.ofbiz.entity.util.EntitySaxReader.parse(EntitySaxReader.java:231) ... 11 more :ofbiz --load-data FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':ofbiz --load-data'. > Process 'command 'C:\Program Files\Java\jdk1.8.0_112\bin\java.exe'' finished with non-zero exit value 1 * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. BUILD FAILED Total time: 2 mins 38.409 secs {code} > Using try-with-resources with JDBC objects > ------------------------------------------ > > Key: OFBIZ-9839 > URL: https://issues.apache.org/jira/browse/OFBIZ-9839 > Project: OFBiz > Issue Type: Improvement > Components: framework > Affects Versions: Trunk > Reporter: Pradhan Yash Sharma > Assignee: Jacques Le Roux > Attachments: OFBIZ-9839.patch, OFBIZ-9839.patch > > > Proposal to use try with resources for SQL objects like ResultSet and other objects. SQL classes have AutoCloseable interface. -- This message was sent by Atlassian JIRA (v6.4.14#64029) |
| Free forum by Nabble | Edit this page |
