Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 62286200BF0 for ; Thu, 24 Nov 2016 12:27:00 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 60AB8160B1F; Thu, 24 Nov 2016 11:27:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 77A79160B11 for ; Thu, 24 Nov 2016 12:26:59 +0100 (CET) Received: (qmail 68645 invoked by uid 500); 24 Nov 2016 11:26:58 -0000 Mailing-List: contact commits-help@cayenne.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cayenne.apache.org Delivered-To: mailing list commits@cayenne.apache.org Received: (qmail 68618 invoked by uid 99); 24 Nov 2016 11:26:58 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Nov 2016 11:26:58 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 9038C2C03DD for ; Thu, 24 Nov 2016 11:26:58 +0000 (UTC) Date: Thu, 24 Nov 2016 11:26:58 +0000 (UTC) From: "ASF GitHub Bot (JIRA)" To: commits@cayenne.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CAY-2153) Modeler. Exception in save action after reverse engineering some complex DB schema MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Thu, 24 Nov 2016 11:27:00 -0000 [ https://issues.apache.org/jira/browse/CAY-2153?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15693023#comment-15693023 ] ASF GitHub Bot commented on CAY-2153: ------------------------------------- GitHub user stariy95 opened a pull request: https://github.com/apache/cayenne/pull/141 CAY-2153 Modeler. Exception in save action after reverse engineering some complex DB schema After reverse engineering is done all data map is checked for invalid references from Obj to Db attributes Additionally some defensive code added to bypass invalid db path state in ObjAttribute: - correct check for this state in ObjAttribute validator - returning null in ObjAttributeWrapper in modeler - unconditional saving of db attribute path to XML (this one is questionable though) You can merge this pull request into a Git repository by running: $ git pull https://github.com/stariy95/cayenne CAY-2153 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cayenne/pull/141.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #141 ---- commit bd522367354b0943178a9fc3a77be9ad0381f3e5 Author: Nikita Timofeev Date: 2016-11-24T11:24:57Z CAY-2153 After reverse engineering is done all data map is checked for invalid references from Obj to Db attributes Additionally some defensive code added to bypass invalid db path state in ObjAttribute: - correct check for this state in ObjAttribute validator - returning null in ObjAttributeWrapper in modeler - unconditional saving of db attribute path to XML (this one is questionable though) ---- > Modeler. Exception in save action after reverse engineering some complex DB schema > ---------------------------------------------------------------------------------- > > Key: CAY-2153 > URL: https://issues.apache.org/jira/browse/CAY-2153 > Project: Cayenne > Issue Type: Bug > Components: Modeler > Affects Versions: 4.0.M4 > Reporter: Nikita Timofeev > Assignee: Nikita Timofeev > > No test schema available for this exception only stack trace was reported. > CayenneModeler Info > Version: 4.0.M4-SNAPSHOT > Build Date: Nov 14 2016 06:17:32 > Exception: > ================================= > org.apache.cayenne.exp.ExpressionException: [v.4.0.M4-SNAPSHOT Nov 14 2016 06:17:32] Can't resolve path component: [test_item.testDbPath]. > at org.apache.cayenne.map.Entity$PathIterator.next(Entity.java:428) > at org.apache.cayenne.map.Entity$PathIterator.next(Entity.java:375) > at org.apache.cayenne.map.ObjAttribute.getDbAttribute(ObjAttribute.java:180) > at org.apache.cayenne.project.validation.ObjAttributeValidator.validate(ObjAttributeValidator.java:131) > at org.apache.cayenne.project.validation.DefaultProjectValidator$ValidationVisitor.visitObjAttribute(DefaultProjectValidator.java:199) > at org.apache.cayenne.project.validation.DefaultProjectValidator$ValidationVisitor.visitObjEntity(DefaultProjectValidator.java:209) > at org.apache.cayenne.project.validation.DefaultProjectValidator$ValidationVisitor.visitDataMap(DefaultProjectValidator.java:127) > at org.apache.cayenne.project.validation.DefaultProjectValidator$ValidationVisitor.visitDataChannelDescriptor(DefaultProjectValidator.java:110) > at org.apache.cayenne.project.validation.DefaultProjectValidator$ValidationVisitor.visitDataChannelDescriptor(DefaultProjectValidator.java:92) > at org.apache.cayenne.configuration.DataChannelDescriptor.acceptVisitor(DataChannelDescriptor.java:111) > at org.apache.cayenne.project.validation.DefaultProjectValidator.validate(DefaultProjectValidator.java:89) > at org.apache.cayenne.modeler.action.SaveAsAction.performAction(SaveAsAction.java:164) > at org.apache.cayenne.modeler.action.SaveAsAction.performAction(SaveAsAction.java:158) > at org.apache.cayenne.modeler.util.CayenneAction.actionPerformed(CayenneAction.java:162) > at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022) > at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2348) > at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402) > at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259) > at javax.swing.AbstractButton.doClick(AbstractButton.java:376) > at com.apple.laf.ScreenMenuItem.actionPerformed(ScreenMenuItem.java:125) > at java.awt.MenuItem.processActionEvent(MenuItem.java:669) > at java.awt.MenuItem.processEvent(MenuItem.java:628) > at java.awt.MenuComponent.dispatchEventImpl(MenuComponent.java:351) > at java.awt.MenuComponent.dispatchEvent(MenuComponent.java:339) > at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:761) > at java.awt.EventQueue.access$500(EventQueue.java:97) > at java.awt.EventQueue$3.run(EventQueue.java:709) > at java.awt.EventQueue$3.run(EventQueue.java:703) > at java.security.AccessController.doPrivileged(Native Method) > at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76) > at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:86) > at java.awt.EventQueue$4.run(EventQueue.java:731) > at java.awt.EventQueue$4.run(EventQueue.java:729) > at java.security.AccessController.doPrivileged(Native Method) > at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:76) > at java.awt.EventQueue.dispatchEvent(EventQueue.java:728) > at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201) > at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116) > at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101) > at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93) > at java.awt.EventDispatchThread.run(EventDispatchThread.java:82) -- This message was sent by Atlassian JIRA (v6.3.4#6332)