Toplink Workbench Exceptions …….

When I tried to open a Toplink project (project.mwp) generated by Toplink 9.0.3 in the newer version 9.0.4, I got the following errors during the conversion process. What should I do to correct this issue? Many thanks for the help.
Throwable Class Name:
oracle.toplink.exceptions.DescriptorException
Message:
Exception Description: The method [isStub] on the object [oracle.toplink.workbench.model.meta.MWClass] triggered an exception.
Internal Exception: java.lang.reflect.InvocationTargetException
Target Invocation Exception: java.lang.NullPointerException
Mapping: oracle.toplink.mappings.DirectToFieldMapping[stub-->class.stub]
Descriptor: XMLDescriptor(oracle.toplink.workbench.model.meta.MWClass --> [DatabaseTable(class)])
Stack trace:
Local Exception Stack:
Exception [TOPLINK-99] (OracleAS TopLink - 10g (9.0.4) (Build 031126)): oracle.toplink.exceptions.DescriptorException
Exception Description: The method [isStub] on the object [oracle.toplink.workbench.model.meta.MWClass] triggered an exception.
Internal Exception: java.lang.reflect.InvocationTargetException
Target Invocation Exception: java.lang.NullPointerException
Mapping: oracle.toplink.mappings.DirectToFieldMapping[stub-->class.stub]
Descriptor: XMLDescriptor(oracle.toplink.workbench.model.meta.MWClass --> [DatabaseTable(class)])
     at oracle.toplink.exceptions.DescriptorException.targetInvocationWhileGettingValueThruMethodAccessor(DescriptorException.java:1371)
     at oracle.toplink.internal.descriptors.MethodAttributeAccessor.getAttributeValueFromObject(MethodAttributeAccessor.java:47)
     at oracle.toplink.mappings.DatabaseMapping.getAttributeValueFromObject(DatabaseMapping.java:304)
     at oracle.toplink.mappings.DirectToFieldMapping.buildClone(DirectToFieldMapping.java:61)
     at oracle.toplink.internal.descriptors.ObjectBuilder.populateAttributesForClone(ObjectBuilder.java:1493)
     at oracle.toplink.publicinterface.UnitOfWork.cloneAndRegisterNewObject(UnitOfWork.java:580)
     at oracle.toplink.publicinterface.UnitOfWork.internalRegisterObject(UnitOfWork.java:2261)
     at oracle.toplink.publicinterface.UnitOfWork.registerObject(UnitOfWork.java:3093)
     at oracle.toplink.mappings.CollectionMapping.buildElementClone(CollectionMapping.java:148)
     at oracle.toplink.mappings.CollectionMapping.buildCloneForPartObject(CollectionMapping.java:107)
     at oracle.toplink.internal.indirection.NoIndirectionPolicy.cloneAttribute(NoIndirectionPolicy.java:43)
     at oracle.toplink.mappings.ForeignReferenceMapping.buildClone(ForeignReferenceMapping.java:160)
     at oracle.toplink.internal.descriptors.ObjectBuilder.populateAttributesForClone(ObjectBuilder.java:1493)
     at oracle.toplink.mappings.AggregateMapping.buildClonePart(AggregateMapping.java:132)
     at oracle.toplink.mappings.AggregateMapping.buildClone(AggregateMapping.java:110)
     at oracle.toplink.internal.descriptors.ObjectBuilder.populateAttributesForClone(ObjectBuilder.java:1493)
     at oracle.toplink.publicinterface.UnitOfWork.cloneAndRegisterNewObject(UnitOfWork.java:580)
     at oracle.toplink.publicinterface.UnitOfWork.internalRegisterObject(UnitOfWork.java:2261)
     at oracle.toplink.publicinterface.UnitOfWork.registerObject(UnitOfWork.java:3093)
     at oracle.toplink.workbench.ui.WorkbenchSession.registerProject(WorkbenchSession.java:551)
     at oracle.toplink.workbench.ui.WorkbenchSession.addProject(WorkbenchSession.java:151)
     at oracle.toplink.workbench.ui.WorkbenchSession.addNewProject(WorkbenchSession.java:138)
     at oracle.toplink.workbench.ui.MainView.addNewProject(MainView.java:265)
     at oracle.toplink.workbench.filesystem.MWFileFactory.openImp(MWFileFactory.java:206)
     at oracle.toplink.workbench.filesystem.MWFileFactory.open(MWFileFactory.java:158)
     at oracle.toplink.tsceditor.persistence.PersistenceManager.open(PersistenceManager.java:747)
     at oracle.toplink.tsceditor.ui.persistence.DefaultUIPersistence.open(DefaultUIPersistence.java:181)
     at oracle.toplink.tsceditor.ui.persistence.UIPersistenceManager.open(UIPersistenceManager.java:625)
     at oracle.toplink.tsceditor.ui.persistence.UIPersistenceManager$OpenFile.execute(UIPersistenceManager.java:1095)
     at oracle.toplink.tsceditor.utility.Thread.run(Thread.java:114)
Caused by: java.lang.reflect.InvocationTargetException
     at sun.reflect.GeneratedMethodAccessor107.invoke(Unknown Source)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
     at java.lang.reflect.Method.invoke(Unknown Source)
     at oracle.toplink.internal.descriptors.MethodAttributeAccessor.getAttributeValueFromObject(MethodAttributeAccessor.java:40)
     ... 28 more
Caused by: java.lang.NullPointerException
     at oracle.toplink.workbench.model.meta.MWClass.superclassIsDefaultValue(MWClass.java:1275)
     at oracle.toplink.workbench.model.meta.MWClass.isStub(MWClass.java:1236)
     ... 32 more

oracle.toplink.workbench.framework.OpenException: Exception [TOPLINK-98] (Oracle TopLink - 10g Developer Preview 3 (10.1.3.0 ) (Build 041012)): oracle.toplink.exceptions.DescriptorException
Exception Description: The underlying descriptor callback method [legacy45PostBuild], with parameter (DescriptorEvent), triggered an exception.
Internal Exception: java.lang.reflect.InvocationTargetException
Target Invocation Exception: java.lang.NullPointerException
Descriptor: XMLDescriptor(oracle.toplink.workbench.mappingsmodel.project.relational.MWRelationalProject --> [DatabaseTable(BldrProject)])
     at oracle.toplink.workbench.mappingsplugin.MWPlugin.open(MWPlugin.java:262)
     at oracle.toplink.workbench.framework.internal.FrameworkApplication.open(FrameworkApplication.java:605)
     at oracle.toplink.workbench.framework.internal.FrameworkNodeManager.openCallback(FrameworkNodeManager.java:325)
     at oracle.toplink.workbench.framework.internal.RunnableProjectLoader.run2(RunnableProjectLoader.java:81)
     at oracle.toplink.workbench.framework.internal.RunnableProjectLoader.run(RunnableProjectLoader.java:68)
     at java.lang.Thread.run(Thread.java:534)
Caused by: Exception [TOPLINK-98] (Oracle TopLink - 10g Developer Preview 3 (10.1.3.0 ) (Build 041012)): oracle.toplink.exceptions.DescriptorException
Exception Description: The underlying descriptor callback method [legacy45PostBuild], with parameter (DescriptorEvent), triggered an exception.
Internal Exception: java.lang.reflect.InvocationTargetException
Target Invocation Exception: java.lang.NullPointerException
Descriptor: XMLDescriptor(oracle.toplink.workbench.mappingsmodel.project.relational.MWRelationalProject --> [DatabaseTable(BldrProject)])
     at oracle.toplink.exceptions.DescriptorException.targetInvocationWhileEventExecution(DescriptorException.java:1598)
     at oracle.toplink.publicinterface.DescriptorEventManager.executeEvent(DescriptorEventManager.java:177)
     at oracle.toplink.internal.descriptors.ObjectBuilder.buildAttributesIntoObject(ObjectBuilder.java:256)
     at oracle.toplink.internal.descriptors.ObjectBuilder.buildObject(ObjectBuilder.java:504)
     at oracle.toplink.internal.descriptors.ObjectBuilder.buildObject(ObjectBuilder.java:372)
     at oracle.toplink.queryframework.ObjectLevelReadQuery.buildObject(ObjectLevelReadQuery.java:408)
     at oracle.toplink.queryframework.ReadObjectQuery.executeObjectLevelReadQuery(ReadObjectQuery.java:372)
     at oracle.toplink.queryframework.ObjectLevelReadQuery.executeDatabaseQuery(ObjectLevelReadQuery.java:727)
     at oracle.toplink.queryframework.DatabaseQuery.execute(DatabaseQuery.java:559)
     at oracle.toplink.queryframework.ReadObjectQuery.execute(ReadObjectQuery.java:336)
     at oracle.toplink.publicinterface.Session.internalExecuteQuery(Session.java:1977)
     at oracle.toplink.publicinterface.Session.executeQuery(Session.java:973)
     at oracle.toplink.publicinterface.Session.executeQuery(Session.java:930)
     at oracle.toplink.publicinterface.Session.readObject(Session.java:2429)
     at oracle.toplink.workbench.mappingsio.legacy.PersistenceTools45.readMWProjectNamed(PersistenceTools45.java:230)
     at oracle.toplink.workbench.mappingsio.legacy.LegacyIOFacade.read45Project(LegacyIOFacade.java:18)
     at oracle.toplink.workbench.mappingsio.ProjectReader.readPreviousVersion(ProjectReader.java:97)
     at oracle.toplink.workbench.mappingsio.ProjectReader.read(ProjectReader.java:85)
     at oracle.toplink.workbench.mappingsio.ProjectIOManager.read(ProjectIOManager.java:48)
     at oracle.toplink.workbench.mappingsio.ProjectIOManager.read(ProjectIOManager.java:44)
     at oracle.toplink.workbench.mappingsplugin.MWPlugin.open(MWPlugin.java:260)
     ... 5 more
Caused by: java.lang.reflect.InvocationTargetException
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
     at java.lang.reflect.Method.invoke(Method.java:324)
     at oracle.toplink.internal.security.PrivilegedAccessController.invokeMethod(PrivilegedAccessController.java:416)
     at oracle.toplink.publicinterface.DescriptorEventManager.executeEvent(DescriptorEventManager.java:170)
     ... 24 more
Caused by: java.lang.NullPointerException
     at oracle.toplink.workbench.mappingsmodel.desc.relational.MWRelationalPrimaryKeyPolicy.nodeRemoved(MWRelationalPrimaryKeyPolicy.java:185)
     at oracle.toplink.workbench.utility.node.AbstractNodeModel.nodeRemoved(AbstractNodeModel.java:288)
     at oracle.toplink.workbench.utility.node.AbstractNodeModel.nodeRemoved(AbstractNodeModel.java:288)
     at oracle.toplink.workbench.mappingsmodel.desc.MWMappingDescriptor.nodeRemoved(MWMappingDescriptor.java:1174)
     at oracle.toplink.workbench.mappingsmodel.desc.relational.MWTableDescriptor.nodeRemoved(MWTableDescriptor.java:1054)
     at oracle.toplink.workbench.utility.node.AbstractNodeModel.nodeRemoved(AbstractNodeModel.java:288)
     at oracle.toplink.workbench.mappingsmodel.MWModel.removeNodeFromCollection(MWModel.java:152)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.removeAttribute(MWClass.java:960)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.removeAttributes(MWClass.java:969)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.removeAttributes(MWClass.java:964)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.clearAttributes(MWClass.java:974)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.legacyXXReworkCoreType(MWClass.java:3108)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClass.legacy45PostPostProjectBuild(MWClass.java:3084)
     at oracle.toplink.workbench.mappingsmodel.MWModel.legacy45PostPostProjectBuild(MWModel.java:575)
     at oracle.toplink.workbench.mappingsmodel.meta.MWClassRepository.legacy45PostPostProjectBuild(MWClassRepository.java:1271)
     at oracle.toplink.workbench.mappingsmodel.MWModel.legacy45PostPostProjectBuild(MWModel.java:575)
     at oracle.toplink.workbench.mappingsmodel.project.MWProject.legacy45PostBuild(MWProject.java:1233)
     at oracle.toplink.workbench.mappingsmodel.project.relational.MWRelationalProject.legacy45PostBuild(MWRelationalProject.java:651)
     ... 30 more

Similar Messages

  • Toplink workbench exception

    One of our teams is having the following problem:
    when we refresh one class in toplink workbench to add a new field, we can no longer save. we get the following error. What is curious, is that our local classes get listed in the workbench. I'm not sure exactly what this means, and the classes referred to in the stack trace are our local framework classes. Has anyone seen something like this before, or have an idea of what it might mean?. Once again the error below is shown in the workbench not runtime.
    LOCAL EXCEPTION STACK: EXCEPTION [TOPLINK-6004] (TopLink - 4.0 (Build 345)): com.webgain.integrator.exceptions.QueryException EXCEPTION DESCRIPTION: The object [BldrClass[3c8807] (com.cna.exceptions.CfRuntimeException, modifier = public, array=, implements [BldrClass[3aa0bb] (com.cna.exceptions.CiException, modifier = public abstract interface, interface, array=, implements [])], extends RuntimeException)], of class [class com.webgain.workbench.model.meta.BldrClass], with identity hashcode (System.identityHashCode()) [3,966,983], is not from this UnitOfWork object space, but the parent session's. The object was never registered in this UnitOfWork, but read from the parent session and related to an object registered in the UnitOfWork. Ensure that you are correctly registering your objects. If you are still having problems, you can use the UnitOfWork.validateObjectSpace() method to help debug where the error occurred. For more information, see the manual or FAQ. QUERY: WriteObjectQuery(BldrClass[3c8807] (com.cna.exceptions.CfRuntimeException, modifier = public, array=, implements [BldrClass[3aa0bb] (com.cna.exceptions.CiException, modifier = public abstract interface, interface, array=, implements [])], extends RuntimeException))      at com.webgain.integrator.exceptions.QueryException.backupCloneIsOriginalFromParent(QueryException.java:143)      at com.webgain.integrator.publicinterface.UnitOfWork.getBackupClone(UnitOfWork.java:1284)      at com.webgain.integrator.publicinterface.UnitOfWork.getBackupCloneForCommit(UnitOfWork.java:1316)      at com.webgain.integrator.queryframework.ObjectLevelModifyQuery.prepareForExecution(ObjectLevelModifyQuery.java:144)      at com.webgain.integrator.queryframework.WriteObjectQuery.prepareForExecution(WriteObjectQuery.java:102)      at com.webgain.integrator.queryframework.DatabaseQuery.execute(DatabaseQuery.java:473)      at com.webgain.integrator.publicinterface.Session.internalExecuteQuery(Session.java:1869)      at com.webgain.integrator.publicinterface.UnitOfWork.internalExecuteQuery(UnitOfWork.java:1962)      at com.webgain.integrator.publicinterface.Session.executeQuery(Session.java:1034)      at com.webgain.integrator.publicinterface.Session.executeQuery(Session.java:988)

    The easiest workaround to this problem is normally to perform a "save as" of the project, which will normally work.
    TopLink - 4.0 (Build 345) - is a fairly old release, you may wish to contact support to get the latest patch for this release, or to upgrade to a newer version of the product.

  • Bug in TopLink Workbench

    Hi,
    I'm testing TopLink, my 1st step is running Workbench, but after I define the database and save project, the exception exception below always occur, with Workbench
    and I can't do anything,
    Plataform is:
    Linux kernel 2.4.18
    SUN J2SDK 1.4.1_01
    java.lang.NullPointerException
         at oracle.toplink.workbench.persistence.BldrDatabasePlatformPersistenceTools.loadPlatformNamesFromFileNames(Unknown Source)
         at oracle.toplink.workbench.persistence.BldrDatabasePlatformPersistenceTools.initialize(Unknown Source)
         at oracle.toplink.workbench.persistence.BldrDatabasePlatformPersistenceTools.<init>(Unknown Source)
         at oracle.toplink.workbench.persistence.BldrDatabasePlatformPersistenceTools.instance(Unknown Source)
         at oracle.toplink.workbench.model.db.BldrDatabase.getPlatform(Unknown Source)
         at oracle.toplink.workbench.ui.BldrProjectPropertiesSequencingPage.updateSequenceNativeChoice(Unknown Source)
         at oracle.toplink.workbench.ui.BldrProjectPropertiesSequencingPage.populatePage(Unknown Source)
         at oracle.toplink.workbench.ui.BldrProjectPropertiesPanel.populate(Unknown Source)
         at oracle.toplink.workbench.ui.tree.BldrProjectNode.populate(Unknown Source)
         at oracle.toplink.workbench.ui.BldrMainView.maintainPropertiesPanel(Unknown Source)
         at oracle.toplink.workbench.ui.BldrMainView.access$100(Unknown Source)
         at oracle.toplink.workbench.ui.BldrMainView$TreeSelectionHandler.valueChanged(Unknown Source)
         at javax.swing.JTree.fireValueChanged(JTree.java:2406)
         at javax.swing.JTree$TreeSelectionRedirector.valueChanged(JTree.java:2777)
         at javax.swing.tree.DefaultTreeSelectionModel.fireValueChanged(DefaultTreeSelectionModel.java:629)
         at javax.swing.tree.DefaultTreeSelectionModel.notifyPathChange(DefaultTreeSelectionModel.java:1076)
         at javax.swing.tree.DefaultTreeSelectionModel.setSelectionPaths(DefaultTreeSelectionModel.java:287)
         at javax.swing.tree.DefaultTreeSelectionModel.setSelectionPath(DefaultTreeSelectionModel.java:170)
         at javax.swing.JTree.setSelectionPath(JTree.java:1181)
         at javax.swing.plaf.basic.BasicTreeUI.selectPathForEvent(BasicTreeUI.java:2192)
         at javax.swing.plaf.basic.BasicTreeUI$MouseHandler.handleSelection(BasicTreeUI.java:2840)
         at javax.swing.plaf.basic.BasicTreeUI$MouseHandler.mousePressed(BasicTreeUI.java:2801)
         at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:218)
         at java.awt.AWTEventMulticaster.mousePressed(AWTEventMulticaster.java:217)
         at java.awt.Component.processMouseEvent(Component.java:5090)
         at java.awt.Component.processEvent(Component.java:4890)
         at java.awt.Container.processEvent(Container.java:1566)
         at java.awt.Component.dispatchEventImpl(Component.java:3598)
         at java.awt.Container.dispatchEventImpl(Container.java:1623)
         at java.awt.Component.dispatchEvent(Component.java:3439)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3450)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3162)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3095)
         at java.awt.Container.dispatchEventImpl(Container.java:1609)
         at java.awt.Window.dispatchEventImpl(Window.java:1585)
         at java.awt.Component.dispatchEvent(Component.java:3439)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:450)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:197)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:144)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:136)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)

    I found the problem
    The steps to simulate are ,
    1) open a Konsole of KDE.
    2) type sh workbench.sh.
    3) create the project, save and close workbench.
    4) retype sh workbench.sh.
    now all clicks throw the exception,
    then if you don't reopen workbench, all works, or open it in another Konsole.

  • Problem migrating Toplink Workbench project from 9.0.4.5 to 10.1.3.1.0

    Hi all,
    I am having problems migrating my Toplink Workbench project from 9.0.4.5 to 10.1.3.1.0! I used the Toplink Workbench to open and convert the existing project. The conversion succeeded, but when I tried to export the mappings I got this:
    java.lang.NullPointerException
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalPrimaryKeyPolicy.adjustRuntimeDescriptor(MWRelationalPrimaryKeyPolicy.java:174)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalTransactionalPolicy.adjustRuntimeDescriptor(MWRelationalTransactionalPolicy.java:85)
         at oracle.toplink.workbench.mappingsmodel.descriptor.MWDescriptor.buildRuntimeDescriptor(MWDescriptor.java:423)
         at oracle.toplink.workbench.mappingsmodel.descriptor.MWMappingDescriptor.buildRuntimeDescriptor(MWMappingDescriptor.java:860)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalClassDescriptor.buildRuntimeDescriptor(MWRelationalClassDescriptor.java:791)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWTableDescriptor.buildRuntimeDescriptor(MWTableDescriptor.java:955)
         at oracle.toplink.workbench.mappingsmodel.project.MWProject.buildRuntimeProject(MWProject.java:932)
         at oracle.toplink.workbench.mappingsmodel.project.MWProject.exportDeploymentXML(MWProject.java:804)
         at oracle.toplink.workbench.mappingsplugin.ProjectDeploymentXmlGenerationCoordinator.exportProjectDeploymentXml(ProjectDeploymentXmlGenerationCoordinator.java:46)
         at oracle.toplink.workbench.mappingsplugin.ExportDeploymentXmlAction.execute(ExportDeploymentXmlAction.java:27)
         at oracle.toplink.workbench.framework.action.AbstractFrameworkAction.actionPerformed(AbstractFrameworkAction.java:134)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:245)
         at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:231)
         at java.awt.Component.processMouseEvent(Component.java:5100)
         at java.awt.Component.processEvent(Component.java:4897)
         at java.awt.Container.processEvent(Container.java:1569)
         at java.awt.Component.dispatchEventImpl(Component.java:3615)
         at java.awt.Container.dispatchEventImpl(Container.java:1627)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
         at java.awt.Container.dispatchEventImpl(Container.java:1613)
         at java.awt.Window.dispatchEventImpl(Window.java:1606)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:480)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
    Anyone seen this error before? This is very critical for us. Please help. Thanks.
    Regards,
    gkk1969

    I am seeing the same problem when i try to do Export to Java Source
    java.lang.NullPointerException
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalPrimaryKeyPolicy.adjustRuntimeDescriptor(MWRelationalPrimaryKeyPolicy.java:174)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalTransactionalPolicy.adjustRuntimeDescriptor(MWRelationalTransactionalPolicy.java:85)
         at oracle.toplink.workbench.mappingsmodel.descriptor.MWDescriptor.buildRuntimeDescriptor(MWDescriptor.java:423)
         at oracle.toplink.workbench.mappingsmodel.descriptor.MWMappingDescriptor.buildRuntimeDescriptor(MWMappingDescriptor.java:860)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWRelationalClassDescriptor.buildRuntimeDescriptor(MWRelationalClassDescriptor.java:791)
         at oracle.toplink.workbench.mappingsmodel.descriptor.relational.MWTableDescriptor.buildRuntimeDescriptor(MWTableDescriptor.java:955)
         at oracle.toplink.workbench.mappingsmodel.project.MWProject.buildRuntimeProject(MWProject.java:932)
         at oracle.toplink.workbench.mappingsmodel.project.MWProject.exportProjectSource(MWProject.java:824)
         at oracle.toplink.workbench.mappingsplugin.ProjectSourceGenerationCoordinator.exportProjectSource(ProjectSourceGenerationCoordinator.java:68)
         at oracle.toplink.workbench.mappingsplugin.ExportJavaSourceAction.execute(ExportJavaSourceAction.java:31)
         at oracle.toplink.workbench.framework.action.AbstractFrameworkAction.actionPerformed(AbstractFrameworkAction.java:134)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.AbstractButton.doClick(AbstractButton.java:289)
         at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1113)
         at javax.swing.plaf.basic.BasicMenuItemUI$MouseInputHandler.mouseReleased(BasicMenuItemUI.java:943)
         at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:231)
         at java.awt.Component.processMouseEvent(Component.java:5100)
         at java.awt.Component.processEvent(Component.java:4897)
         at java.awt.Container.processEvent(Container.java:1569)
         at java.awt.Component.dispatchEventImpl(Component.java:3615)
         at java.awt.Container.dispatchEventImpl(Container.java:1627)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
         at java.awt.Container.dispatchEventImpl(Container.java:1613)
         at java.awt.Window.dispatchEventImpl(Window.java:1606)
         at java.awt.Component.dispatchEvent(Component.java:3477)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)

  • Help with: oracle.toplink.essentials.exceptions.ValidationException

    hi guys,
    I really need ur help with this.
    I have a remote session bean that retrieves a list of books from the database using entity class and I call the session bean from a web service. The problem is that when i display the books in a jsp directly from the session bean everything works ok but the problem comes when I call the session bean via the web service than it throws this:
    Exception Description: An attempt was made to traverse a relationship using indirection that had a null Session. This often occurs when an entity with an uninstantiated LAZY relationship is serialized and that lazy relationship is traversed after serialization. To avoid this issue, instantiate the LAZY relationship prior to serialization.
    at oracle.toplink.essentials.exceptions.ValidationException.instantiatingValueholderWithNullSession(ValidationException.java:887)
    at oracle.toplink.essentials.internal.indirection.UnitOfWorkValueHolder.instantiate(UnitOfWorkValueHolder.java:233)
    at oracle.toplink.essentials.internal.indirection.DatabaseValueHolder.getValue(DatabaseValueHolder.java:105)
    at oracle.toplink.essentials.indirection.IndirectList.buildDelegate(IndirectList.java:208)
    at oracle.toplink.essentials.indirection.IndirectList.getDelegate(IndirectList.java:330)
    at oracle.toplink.essentials.indirection.IndirectList$1.<init>(IndirectList.java:425)
    at oracle.toplink.essentials.indirection.IndirectList.iterator(IndirectList.java:424)
    at com.sun.xml.bind.v2.runtime.reflect.Lister$CollectionLister.iterator(Lister.java:278)
    at com.sun.xml.bind.v2.runtime.reflect.Lister$CollectionLister.iterator(Lister.java:265)
    at com.sun.xml.bind.v2.runtime.property.ArrayElementProperty.serializeListBody(ArrayElementProperty.java:129)
    at com.sun.xml.bind.v2.runtime.property.ArrayERProperty.serializeBody(ArrayERProperty.java:152)
    at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.serializeBody(ClassBeanInfoImpl.java:322)
    at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsXsiType(XMLSerializer.java:681)
    at com.sun.xml.bind.v2.runtime.property.ArrayElementNodeProperty.serializeItem(ArrayElementNodeProperty.java:65)
    at com.sun.xml.bind.v2.runtime.property.ArrayElementProperty.serializeListBody(ArrayElementProperty.java:168)
    at com.sun.xml.bind.v2.runtime.property.ArrayERProperty.serializeBody(ArrayERProperty.java:152)
    at com.sun.xml.bind.v2.runtime.ClassBeanInfoImpl.serializeBody(ClassBeanInfoImpl.java:322)
    at com.sun.xml.bind.v2.runtime.XMLSerializer.childAsXsiType(XMLSerializer.java:681)
    at com.sun.xml.bind.v2.runtime.MarshallerImpl.write(MarshallerImpl.java:277)
    at com.sun.xml.bind.v2.runtime.BridgeImpl.marshal(BridgeImpl.java:100)
    at com.sun.xml.bind.api.Bridge.marshal(Bridge.java:141)
    at com.sun.xml.ws.message.jaxb.JAXBMessage.writePayloadTo(JAXBMessage.java:315)
    at com.sun.xml.ws.message.AbstractMessageImpl.writeTo(AbstractMessageImpl.java:142)
    at com.sun.xml.ws.encoding.StreamSOAPCodec.encode(StreamSOAPCodec.java:108)
    at com.sun.xml.ws.encoding.SOAPBindingCodec.encode(SOAPBindingCodec.java:258)
    at com.sun.xml.ws.transport.http.HttpAdapter.encodePacket(HttpAdapter.java:320)
    at com.sun.xml.ws.transport.http.HttpAdapter.access$100(HttpAdapter.java:93)
    at com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit.handle(HttpAdapter.java:454)
    at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:244)
    at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)
    at com.sun.enterprise.webservice.JAXWSServlet.doPost(JAXWSServlet.java:176)
    ... 29 more
    This happens when I test the web service using netbeans 6.5.
    here's my code:
    session bean:
    ArrayList bookList = null;
    public ArrayList retrieveBooks()
    try
    List list = em.createNamedQuery("Book.findAll").getResultList();
    bookList = new ArrayList(list);
    catch (Exception e)
    e.getCause();
    return bookList;
    web service:
    @WebMethod(operationName = "retrieveBooks")
    public Book[] retrieveBooks()
    ArrayList list = ejbUB.retrieveBooks();
    int size = list.size();
    Book[] bookList = new Book[size];
    Iterator it = list.iterator();
    int i = 0;
    while (it.hasNext())
    Book book = (Book) it.next();
    bookList[i] = book;
    i++;
    return bookList;
    Please help guys, it's very urgent

    Yes i have a relationship but i didnt want it to be directly. Maybe this is a design problem but in my case I dont expect any criminals to be involved in lawsuit. My tables are like that:
    CREATE TABLE IF NOT EXISTS Criminal(
         criminal_id INTEGER NOT NULL AUTO_INCREMENT,
         gender varchar(1),
         name varchar(25) NOT NULL,
         last_address varchar(100),
         birth_date date,
         hair_color varchar(10),
         eye_color varchar(10),
         weight INTEGER,
         height INTEGER,
         PRIMARY KEY (criminal_id)
    ENGINE=INNODB;
    CREATE TABLE IF NOT EXISTS Lawsuit(
         lawsuit_id INTEGER NOT NULL AUTO_INCREMENT,
         courtName varchar(25),
         PRIMARY KEY (lawsuit_id),
         FOREIGN KEY (courtName) REFERENCES Court_of_Law(courtName) ON DELETE NO ACTION
    ENGINE=INNODB;
    CREATE TABLE IF NOT EXISTS Rstands_trial(
         criminal_id INTEGER,
         lawsuit_id INTEGER,
         PRIMARY KEY (criminal_id, lawsuit_id),
         FOREIGN KEY (criminal_id) REFERENCES Criminal(criminal_id) ON DELETE NO ACTION,
         FOREIGN KEY (lawsuit_id) REFERENCES Lawsuit(lawsuit_id) ON DELETE CASCADE
    ENGINE=INNODB;So I couldnt get it.

  • Using TopLink Workbench in Jdeveloper HELP!!!!!

    HI! I want to know how can I use TopLink Workbench in JDeveloper to configure java classes???
    Please Help!!!
    Best Regards

    JDeveloper has built in TopLink design time - so you don't need the external TopLink Workbench.
    Try following one of the TopLink Tutorials here:
    http://www.oracle.com/technology/obe/obe1013jdev/10131/10131_adftoplink/master-detail-edit_page_adf_toplink.htm
    and
    http://www.oracle.com/technology/obe/ADF_tutorial_1013/10131/index.htm

  • StringIndexOutOfBoundsException in o.toplink.workbench.addin.mapping.spi.db

    Hi All
    I'm using JDeveloper 11g. When I started JDeveloper, the following error appear.
    Unexpected severe error has occurred in JDeveloper
    The program may be unstable, which could result in data loss. Decide how you want to proceed and click OK.
    View errory details.
    +Invoking command: Toggle Comments[ from oracle.ide.ceditor.CodeEditor ]+
    +Performing action Undo Toggle Comments[ from oracle.ide.ceditor.CodeEditor ]+
    +Performing action Close All[ from oracle.ide.ceditor.CodeEditor ]+
    An error was detected while opening a persistence file.
    java.lang.StringIndexOutOfBoundsException: String index out of range: -1
    j.lang.String.substring(String.java:1932)
    j.lang.String.substring(String.java:1905)
    o.toplink.workbench.addin.mappings.spi.db.JDeveloperDBObject.getCatalogName(JDeveloperDBObject.java:41)
    o.toplink.workbench.mappingsmodel.db.MWDatabase.refreshTables(MWDatabase.java:1157)
    o.toplink.workbench.mappingsmodel.db.MWDatabase.refreshRelations(MWDatabase.java:1142)
    o.toplink.workbench.mappingsmodel.db.MWDatabase.refresh(MWDatabase.java:1074)
    o.toplink.workbench.mappingsmodel.sessions.MWSessionsProject.initializeDatabases(MWSessionsProject.java:501)
    o.toplink.workbench.mappingsmodel.sessions.MWSessionsProject.initialize(MWSessionsProject.java:487)
    o.toplink.workbench.mappingsmodel.sessions.MWSessionsProject.<init>(MWSessionsProject.java:153)
    o.toplink.workbench.addin.application.SessionsProjectContext.buildTopLinkSessionsProject(SessionsProjectContext.java:63)
    o.toplink.workbench.addin.application.SessionsProjectContext.initialize(SessionsProjectContext.java:101)
    o.toplink.workbench.addin.application.AbstractTopLinkContext.<init>(AbstractTopLinkContext.java:51)
    o.toplink.workbench.addin.application.SessionsProjectContext.<init>(SessionsProjectContext.java:45)
    o.toplink.workbench.addin.application.ContextManager.openTopLinkSessions(ContextManager.java:1376)
    o.toplink.workbench.addin.application.ContextManager.openTopLinkContexts(ContextManager.java:1325)
    o.toplink.workbench.addin.TopLinkProjectChangeListener$TopLinkContextWorker.run(TopLinkProjectChangeListener.java:370)
    j.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
    j.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    j.util.concurrent.FutureTask.run(FutureTask.java:138)
    j.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
    j.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    j.lang.Thread.run(Thread.java:619)
    Thankyou.
    Thiensu2810

    I am using 10.1.3.0.1 and for me there are still grave issues with interface management in the WB.
    First of all, I get a NullPointerException when clicking the "add" Button on the interface descriptor's implementor list after having refreshed all classes by selecting the project packages and doing "refresh classes" from the context menu. I have to close and restart the WB in order to be able to continue working.
    Then, some attributes which are not common among the implementor classes are detected as common query keys.
    Lastly, if I use variable one-to-one relationships and de-select some class indicator values, the de-selected implementor descriptors are displayed as selected after workbench restart again, showing me errors about missing class indicator values for selected descriptors (Error 0055).

  • Oracle.toplink.essentials.exceptions.ValidationException

    Hi,
    In my EJB 3 application we added a Schema entity to our already existing Student entity.
    I added the followning code in the student entity:
    @OneToOne(cascade = CascadeType.ALL)
    @JoinColumn(
              nullable = true,
              name = "SCHEMA_ID"
    private Schema schema;
    After adding the Schema enity I tried to compile and run the tests. I got the following toplink error message (roughly):
    nternal Exception: Exception [TOPLINK-7250] (Oracle TopLink Essentials - 2.0 (Build b41-beta2 (03/30/2007))): oracle.toplink.essentials.exceptions.ValidationException
    Exception Description: [class se.myapp.subsytem.alpha.Student] uses a non-entity [class se.myapp.subsytem.domain.Schema] as target entity in the relationship attribute [private e.myapp.subsytem.domain.Schema].
    I found out that I had to change the persistence.xml but not why?
    I would be very happy if someone could shed some light in this matter since I have no clue why I must put it in the persistence.xml
    cheers,
    //mike

    You must either annotate every Entity with the @Entity annotation, or map it through the ORM.xml. All Entities must also define an @Id annotation.
    -- James : http://www.eclipselink.org

  • EJB3.0 and toplink workbench

    Hi,
    I have a question to the new TopLink release and EJB 3.0 support.
    Is it possible that TopLink workbench generates EJB 3.0 persistence classes from database with annotations or mappings in the project.xml?
    I don't want to write all the persistence classes with annotations by myself.

    EJB 3.0's Java Persistence API (JPA) is not supported directly from the workbench. You can however take your existing TopLink XML config files (sessions and Map/Project) and use them with JPA (no annotations).
    When working with annotations it becomes more relevant to be doing these operations within an IDE. To this end we have already delivered early support for JPA in JDeveloper. You can generate a persistent entity model from tables with full annotations and then generate a session bean facade exposing the persistence operations as needed.
    For those of you not using JDeveloper we are also leading a project to add this functionality to Eclipse within WTP. For more information on project dali go to www.eclipse.org/dali.
    Doug

  • TopLink workbench won't run (can't find "~1\bin\javaw.exe" error)

    Hello,
    I'm having a tough time getting the TopLink WorkBench to run on Windows XP. I'm trying to run TopLink WorkBench 10g Release 3 (10.1.3.0.0) Build 060118. I've also installed Oracle Application Server 10g Release 3 (10.1.3.0.0) which is working fine (other than the Toplink part). I've managed to get EJB's deployed and access them through RMI and WS.
    When I run "workbench.cmd" I get the error
    Windows cannot find `~1\bin\javaw.exe"
    If I manually remove the setenv.cmd call and cutout all the fixpath bits, Toplink Workbench comes up fine (as far as I can tell), but I cannot connect to my Oracle databases. When I try to connect, I get "The class oracle.jdbc.OracleDriver was not found".
    I've been told this is because my J2EE 1.5 environment is incompatible with standalone Toplink Workbench. Is this true? I have both J2EE 1.5 SDK installed as well as J2EE 1.4 SDK but not amount of rearranging the system CLASSPATH seems to make everything work. (I've restarted Workbench to make sure the new env vars take effect when I change them)
    Is there a step by step document on getting this to work?
    Thanks in advance,
    James Ewell
    Seismic Micro technology
    Houston, TX
    PS - I am running WinXP 64-bit if that matters. The specific java bits are
    W:\>java -version
    java version "1.5.0_05"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
    Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)

    I was referred to this "step by step" link
    http://download-west.oracle.com/docs/cd/B25221_04/web.1013/b13593/mw002.htm#CJADJEEE
    which helps (it walks through the required edits in setenv.cmd). I still have the "can't find ~\bin\javaw.exe" problem though.
    Perhaps this is a JRE 1.5 issue or a WinXP (64-bit) issue.
    James Ewell

  • Primary key issue in toplink workbench

    Hi All,
    I am getting No primary keys specified in (xxx is the table name) table error in workbench.
    I my table,don't have any primary keys,i try to do direct to field mapping for all the fields with the table.
    After mapping,was getting this warning.
    Is there any mandatory thing in toplink workbench that we need to have atleast one primary key defined in a table.
    Please let me know!!!!!!!!!!!!
    Appreciate your hekp............

    Yes, it needs to know how to uniquely identify the row to do deletes and updates, etc. If you have no PK, then actually every field is needed to uniquely identify the row, and therefore just slect every field in the MW as being the PK... Note that the PK specified in the MW doesn't have to actually be the PK on the database, it just has to be unique for when TL does update/delete, etc.
    - Don

  • My Toplink Workbench doesn't start

    Hi,
    I have installed the Toplink Release 10.1.3. Also I have changed the JAVA_HOME classpath and the Driver classpath in the setenv.cmd.
    But when I want to start workbench.cmd, the litte Oracle Window is shown for a few seconds, but the workbench doesn't startup. So nothing happens when I start the workbench - no Exception or so is schown.
    What can I do, please help me.
    Thanks, the german "Hallore"
    P.S. Sorry for my bad English! :-)

    Try the following to see if it could help ......
    1) locate the file "workbench.cmd" in the same folder
    of "setenv.cmd";
    2) modify it as below if applicable
    REM User may increase Java memory setting(s) if
    desired:
    set JVM_ARGS=-Xmx512mI have a similar problem and i did try the suggestion above but to no avail. The surprising thing is it was working okay before
    Thanks

  • TOPLINK-69 exception during commit.

    I am receiving the following exception during commit, idcprice.tenor happens to
    be an aggregate object defined in extending class, this does not always happen,
    can provide more info.
    This is extremely urgent!!! thanks
    Exception:
    2008-04-03 17:05:05,390 ERROR http-0.0.0.0-8080-3 [[email protected]] FXTRADER_WORKFLOWHEL
    PER_FACADE :: acceptRFPQuote() : Exception thrown Database exception: Exception [TOPLINK-69] (Oracle
    TopLink - 10g Release 3 (10.1.3.3.0) (Build 070620)): oracle.toplink.exceptions.DescriptorException
    Exception Description: A NullPointerException was thrown while extracting a value from the instance
    variable [tenor] in the object [null].
    Internal Exception: java.lang.NullPointerException
    Mapping: oracle.toplink.mappings.DirectToFieldMapping[tenor-->IdcPrice.tenor]
    Descriptor: Descriptor(com.integral.finance.trade.Tenor --> [DatabaseTable(IdcPrice)]).

    The bug is that you're getting an NPE instead of a validation exception. When the bug is fixed you'll still get an exception--just one that communicates the problem in your code better.
    It boils down to the fact that you can't share a single aggregate instance between two "owners". This has nothing to do with the aggregate being defined in the base class. The owner and aggregate form a composite--they have the same life cycle. For example if you delete the owner you delete the aggregate. I think you have a situation in which the same instance of an aggregate is being assigned to two owner objects and you're getting this exception.
    In other words somewhere in your code you're either doing something like:
    MyAggregate ag = new MyAggregate();
    object1.setAggregate(ag);
    object2.setAggregate(ag);or
    object1.setAggregate(object2.getAggregate());You need to clone an aggregate if you want to duplicate it's value and assign it to a second owner. Something like:
    MyAggregate ag = new MyAggregate();
    object1.setAggregate(ag);
    object2.setAggregate(ag.clone());or
    object1.setAggregate(object2.getAggregate().clone());--Shaun                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Toplink Workbench Query

    Hi,
    Currently I am using TopLink Mapping Workbench (Release 2 - 9.0.3). I added one field to one of the tables in the database and added a mapping (direct to field) to the bean using the workbench. It also modified the ejb-jar.xml file to add that field as follows:
    <cmp-field>
    <field-name>AId</field-name>
    </cmp-field>
    BUT it also updated security-identity tag under for one of the message driven bean under </enterprise-beans>
    FROM
    <security-identity>
    <run-as>
    <role-name>BBBB</role-name>
    </run-as>
    </security-identity>
    TO
    <relationship-role-source>
    <run-as>
    <role-name>BBBB</role-name>
    </run-as>
    </relationship-role-source>
    I'll be glad if anyone can tell me why it is doing so?
    The bean for which I am adding the field is different than the bean for which the workbench is modifying the security identity.

    I'll be honest, this makes absolutely no sense. The MW doesn't even touch the message driven beans. Is it possible that the ejb-jar.xml originally had the "new" content, the ejb-jar.xml was updated underneath the MW to have the "old" content, and then when the MW wrote out the ejb-jar.xml, it reverted to the "new" content? The MW does preserve the content of the document, but only if kept up to date with the ejb-jar.xml document as changes are made to it.

  • Oracle TopLink Workbench - database connection

    Hello all
    I'm new at Toplink... I installed toplink 11.1.1.3.0
    I'm trying to connect to a oracle database 10g, but I always get a message saying
    "The class oracle.jdbc.driver.OracleDriver was not found.
    Please ensure that the JDBC driver is on the System Classpath"
    I have a system variable called JAVA_HOME, which makes part of the CLASSPATH variable also.
    I read that I need to change the setenv.cmd file, but don't know for sure which changes to make?...
    Thanks for any help

    Hello,
    Looks like you are using the mapping workbench, which needs to have the driver jar file added to its classpath in order to use it to access your database. The documentation at
    http://download.oracle.com/docs/cd/E14571_01/web.1111/b32441/mw.htm#insertedID2
    describes setting the DRIVER_CLASSPATH and other variables needed to get the workbench running.
    Best Regards,
    Chris

Maybe you are looking for