failed to load entity

Post any questions regarding Installing or Upgrading Ebase, including problems starting up the Ebase Xi Server or Designer

Moderators: Jon, Steve, Ian, Dave

Segi
Ebase User
Posts: 649
Joined: Mon Dec 09, 2013 6:37 pm

failed to load entity

#1

Postby Segi » Wed May 04, 2016 5:36 pm

I am suddenly running into an issue where I cannot load one of my main (and most important) forms in Ebase 5.0.1. This was working fine up until today. When I try to open it I get the error "Failed to load entity - C:\ebaseXI5\Workspace\Parts\Forms\Parts.eb."

The log file error.log in UFSClient\logs contains a generic NULLPointerException error. The full error message is

Code: Select all

java.lang.NullPointerException
	at com.ebasetech.ufs.designer.client.workspace.DesignerWorkspace.getProjectObjectLoader(DesignerWorkspace.java:368)
	at com.ebasetech.ufs.kernel.EntityLoader.getProjectObjectLoader(EntityLoader.java:234)
	at com.ebasetech.ufs.designer.client.ComponentHelper.getComponentContextEntityObject(ComponentHelper.java:1417)
	at com.ebasetech.ufs.kernel.StandaloneUFSComponent.loadTexts(StandaloneUFSComponent.java:2324)
	at com.ebasetech.ufs.runtime.LinkedTextsAccessor.initText(LinkedTextsAccessor.java:69)
	at com.ebasetech.ufs.runtime.LinkedTextsAccessor.initializeLinkedTexts(LinkedTextsAccessor.java:58)
	at com.ebasetech.ufs.runtime.LinkedTextsAccessor.<init>&#40;LinkedTextsAccessor.java&#58;40&#41;
	at com.ebasetech.ufs.runtime.RuntimeTexts.initializePhase1&#40;RuntimeTexts.java&#58;81&#41;
	at com.ebasetech.ufs.runtime.RuntimeHeadless.initialiseRuntimes&#40;RuntimeHeadless.java&#58;812&#41;
	at com.ebasetech.ufs.runtime.RuntimeForm.initialiseRuntimes&#40;RuntimeForm.java&#58;138&#41;
	at com.ebasetech.ufs.runtime.RuntimeHeadless.initialise&#40;RuntimeHeadless.java&#58;786&#41;
	at com.ebasetech.ufs.runtime.AbstractRuntimeLoader.loadRuntimeHeadless&#40;AbstractRuntimeLoader.java&#58;151&#41;
	at com.ebasetech.ufs.runtime.AbstractRuntimeLoader.initialiseRuntime&#40;AbstractRuntimeLoader.java&#58;80&#41;
	at com.ebasetech.ufs.runtime.AbstractRuntimeLoader.makeRuntimeHeadless&#40;AbstractRuntimeLoader.java&#58;70&#41;
	at com.ebasetech.ufs.runtime.SimpleRuntimeLoader.getRuntime&#40;SimpleRuntimeLoader.java&#58;60&#41;
	at com.ebasetech.ufs.runtime.FormEngine.getRuntimeHeadless&#40;FormEngine.java&#58;433&#41;
	at com.ebasetech.ufs.runtime.FormEngine.getRuntimeHeadless&#40;FormEngine.java&#58;428&#41;
	at com.ebasetech.ufs.runtime.FormEngine.getRuntimeHeadless&#40;FormEngine.java&#58;415&#41;
	at com.ebasetech.ufs.runtime.HeadlessUserState.hookupRuntime&#40;HeadlessUserState.java&#58;497&#41;
	at com.ebasetech.ufs.runtime.FormEngineSession.setCurrentUserState&#40;FormEngineSession.java&#58;114&#41;
	at com.ebasetech.ufs.runtime.FormEngineSession.changeCurrentUserState&#40;FormEngineSession.java&#58;102&#41;
	at com.ebasetech.ufs.runtime.UserState.setInFormSession&#40;UserState.java&#58;184&#41;
	at com.ebasetech.ufs.runtime.UserState.setUserForm&#40;UserState.java&#58;144&#41;
	at com.ebasetech.ufs.runtime.UserState.setUserForm&#40;UserState.java&#58;118&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.PageDesignComponentEditor.makeUserState&#40;PageDesignComponentEditor.java&#58;111&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.ComponentEditor.initialise&#40;ComponentEditor.java&#58;61&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.PageDesignComponentEditor.initialise&#40;PageDesignComponentEditor.java&#58;72&#41;
	at com.ebasetech.common.gui.dockingFramework.AbstractEditor.init&#40;AbstractEditor.java&#58;50&#41;
	at com.ebasetech.common.gui.dockingFramework.AbstractEditor.<init>&#40;AbstractEditor.java&#58;38&#41;
	at com.ebasetech.common.gui.dockingFramework.AbstractComponentEditor.<init>&#40;AbstractComponentEditor.java&#58;34&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.ComponentEditor.<init>&#40;ComponentEditor.java&#58;51&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.PageDesignComponentEditor.<init>&#40;PageDesignComponentEditor.java&#58;64&#41;
	at com.ebasetech.ufs.designer.client.componentDesign.FormEditor.<init>&#40;FormEditor.java&#58;52&#41;
	at com.ebasetech.ufs.designer.client.FormFunctionFrame.makeContentPanel&#40;FormFunctionFrame.java&#58;85&#41;
	at com.ebasetech.ufs.designer.client.FieldsOnlyFunctionFrame.setupPanelDisplay&#40;FieldsOnlyFunctionFrame.java&#58;37&#41;
	at com.ebasetech.ufs.designer.client.FieldsOnlyFunctionFrame.initWithObject&#40;FieldsOnlyFunctionFrame.java&#58;30&#41;
	at com.ebasetech.ufs.designer.client.FormFunctionFrame.initWithObject&#40;FormFunctionFrame.java&#58;48&#41;
	at com.ebasetech.ufs.designer.client.designerPlugins.FormPlugin.createFunctionFrame&#40;FormPlugin.java&#58;82&#41;
	at com.ebasetech.ufs.designer.client.designerPlugins.AbstractPlugin.displayFrame&#40;AbstractPlugin.java&#58;150&#41;
	at com.ebasetech.ufs.designer.client.designerPlugins.RepositoryPlugin.displayFrame&#40;RepositoryPlugin.java&#58;74&#41;
	at com.ebasetech.ufs.designer.client.DesignerFunctionFrameKey.displayFrame&#40;DesignerFunctionFrameKey.java&#58;124&#41;
	at com.ebasetech.ufs.designer.client.entities.actions.OpenFrameAction.actionPerformed&#40;OpenFrameAction.java&#58;75&#41;
	at com.ebasetech.ufs.designer.client.entities.designerTree.DesignerJTree.showFrameForNode&#40;DesignerJTree.java&#58;656&#41;
	at com.ebasetech.ufs.designer.client.entities.designerTree.DesignerJTree.mousePress&#40;DesignerJTree.java&#58;145&#41;
	at com.ebasetech.ufs.designer.client.entities.designerTree.DesignerJTree.access$000&#40;DesignerJTree.java&#58;51&#41;
	at com.ebasetech.ufs.designer.client.entities.designerTree.DesignerJTree$1.mousePressed&#40;DesignerJTree.java&#58;66&#41;
	at java.awt.AWTEventMulticaster.mousePressed&#40;AWTEventMulticaster.java&#58;280&#41;
	at java.awt.AWTEventMulticaster.mousePressed&#40;AWTEventMulticaster.java&#58;279&#41;
	at java.awt.AWTEventMulticaster.mousePressed&#40;AWTEventMulticaster.java&#58;279&#41;
	at java.awt.Component.processMouseEvent&#40;Component.java&#58;6522&#41;
	at javax.swing.JComponent.processMouseEvent&#40;JComponent.java&#58;3324&#41;
	at java.awt.Component.processEvent&#40;Component.java&#58;6290&#41;
	at java.awt.Container.processEvent&#40;Container.java&#58;2234&#41;
	at java.awt.Component.dispatchEventImpl&#40;Component.java&#58;4881&#41;
	at java.awt.Container.dispatchEventImpl&#40;Container.java&#58;2292&#41;
	at java.awt.Component.dispatchEvent&#40;Component.java&#58;4703&#41;
	at java.awt.LightweightDispatcher.retargetMouseEvent&#40;Container.java&#58;4898&#41;
	at java.awt.LightweightDispatcher.processMouseEvent&#40;Container.java&#58;4530&#41;
	at java.awt.LightweightDispatcher.dispatchEvent&#40;Container.java&#58;4462&#41;
	at java.awt.Container.dispatchEventImpl&#40;Container.java&#58;2278&#41;
	at java.awt.Window.dispatchEventImpl&#40;Window.java&#58;2750&#41;
	at java.awt.Component.dispatchEvent&#40;Component.java&#58;4703&#41;
	at java.awt.EventQueue.dispatchEventImpl&#40;EventQueue.java&#58;758&#41;
	at java.awt.EventQueue.access$500&#40;EventQueue.java&#58;97&#41;
	at java.awt.EventQueue$3.run&#40;EventQueue.java&#58;709&#41;
	at java.awt.EventQueue$3.run&#40;EventQueue.java&#58;703&#41;
	at java.security.AccessController.doPrivileged&#40;Native Method&#41;
	at java.security.ProtectionDomain$1.doIntersectionPrivilege&#40;ProtectionDomain.java&#58;75&#41;
	at java.security.ProtectionDomain$1.doIntersectionPrivilege&#40;ProtectionDomain.java&#58;86&#41;
	at java.awt.EventQueue$4.run&#40;EventQueue.java&#58;731&#41;
	at java.awt.EventQueue$4.run&#40;EventQueue.java&#58;729&#41;
	at java.security.AccessController.doPrivileged&#40;Native Method&#41;
	at java.security.ProtectionDomain$1.doIntersectionPrivilege&#40;ProtectionDomain.java&#58;75&#41;
	at java.awt.EventQueue.dispatchEvent&#40;EventQueue.java&#58;728&#41;
	at com.ebasetech.ufs.designer.client.ExceptionReporter$1.dispatchEvent&#40;ExceptionReporter.java&#58;81&#41;
	at java.awt.EventDispatchThread.pumpOneEventForFilters&#40;EventDispatchThread.java&#58;201&#41;
	at java.awt.EventDispatchThread.pumpEventsForFilter&#40;EventDispatchThread.java&#58;116&#41;
	at java.awt.EventDispatchThread.pumpEventsForHierarchy&#40;EventDispatchThread.java&#58;105&#41;
	at java.awt.EventDispatchThread.pumpEvents&#40;EventDispatchThread.java&#58;101&#41;
	at java.awt.EventDispatchThread.pumpEvents&#40;EventDispatchThread.java&#58;93&#41;
	at java.awt.EventDispatchThread.run&#40;EventDispatchThread.java&#58;82&#41;

0 x

Jon
Moderator
Moderator
Posts: 1342
Joined: Wed Sep 12, 2007 12:49 pm

#2

Postby Jon » Thu May 05, 2016 8:14 am

I think this is caused by a missing dependent project. Check the list of dependent projects for the project containing the form. I suspect this problem is fixed in the latest V5.1 release.
0 x

Segi
Ebase User
Posts: 649
Joined: Mon Dec 09, 2013 6:37 pm

#3

Postby Segi » Thu May 05, 2016 3:44 pm

I have fixed the problem by re-importing a backup of this form.

I did in fact find that some forms in various projects referenced a Messages resource that no longer exists but I have been able to open those forms without any problem to remove the reference to this non-existing message but this particular form gave me an error in designer. Also, this error only appear right after I upgraded to 5.1.1.

Can someone please explain how to decipher an error message such as this to determine what the actual source of the problem is ?

I see these types of messages come up in the server log from time to time. It spits out a great deal of output and in cases like this where there isn't a script or resource being referenced, java.lang.NullPointerException doesn't give me much to go off of to locate the problem.

If I knew how to interpret errors like this, it would go a long way towards helping me locate issues.
0 x

Jon
Moderator
Moderator
Posts: 1342
Joined: Wed Sep 12, 2007 12:49 pm

#4

Postby Jon » Fri May 06, 2016 8:23 am

There isn't a simple guide to reading one of these stacktraces, but to us at Ebase they tell a story. But even without knowing the internals of how Ebase works, you can frequently guess what might be wrong just by looking at the class names and method names. So for your stacktrace, it has failed in:
method getProjectObjectLoader of DesignerWorkspace
so it's a reasonable assumption that it's trying to load a project.
A few lines lower you see:
method loadTexts in class StandaloneUFSComponent
This is loading the text entities configured in form properties and for all inserted components.

In most cases a NullPointerException is a bug - these are usually caused by something that is missing e.g. some sort of relationship. In your case the Texts entity (same as Messages) is part of a component and the project name for the component is included in the entity but it's missing. You can't see that in the designer, but you will see it in the XML - in your case in the components folder within the form.

I've raised a bug for this - the system should show you an error message saying what is wrong, it shouldn't just crash with a NullPointerException.
0 x


Who is online

Users browsing this forum: No registered users and 7 guests