Home » Modeling » EMF "Technology" (Ecore Tools, EMFatic, etc) » [Eclipse Client Platform] EReference of Type "EObject" throws null pointer exception
[Eclipse Client Platform] EReference of Type "EObject" throws null pointer exception [message #1129630] |
Tue, 08 October 2013 20:58 |
Steffen Lehnert Messages: 22 Registered: October 2013 |
Junior Member |
|
|
Hi,
I have a bunch of custom meta-models which all work fine with EMFStore 1.0.1, except for one EClass.
Once I create an instance of this class via the "New Model Element" feature of the EMF client, several null-pointer exceptions are thrown and the client is not able to open the editor for the model element.
This class and its meta-model consist of no custom code. Everything was generated with EMF Ecore.
After a bit of debugging, I've noticed that this class is the only one that contains EReferences of the type "EObject".
If I delete those references from the class or change their type to anything other than "EObject" the problem is gone.
So it seems to me that there is a problem with EReferences of the type EObject.
However, the same meta-model and all of its classes were working fine with EMFStore/ECP 0.9.3, though.
I'm using the following software configuration:
Eclipse Platform 4.3
Eclipse SDK 4.3
Eclipse RCP 4.3
EMFStore 1.0.1
EMF Client Platform 1.0.2
EMF Client Platform EMFStore Integration 1.0.2
ECP SDK Feature 1.0.2
I'm attaching the output of the console that was thrown after creating an instance of this EClass as it might be of use.
Now my question would be whether this is a new "bug" of EMFStore 1.0.1 as it was working fine with 0.9.3, or whether I forget to change something after upgrading from 0.9.3 to 1.0.1?
Any help ore ideas would be appreciated!
Regards,
Steffen
[Updated on: Thu, 05 December 2013 12:45] Report message to a moderator
|
|
|
Re: [EMFStore] EReference of Type "EObject" throws null pointer exception in EMFS [message #1131119 is a reply to message #1129630] |
Thu, 10 October 2013 07:57 |
Maximilian Koegel Messages: 253 Registered: July 2009 |
Senior Member |
|
|
Hi Steffen,
thank you for your post!
This seems to be a bug in the EMF Client Platform UI. But since I am
also responsible for ECP, I will look into it today and get back to you.
Cheers,
Maximilian
Am 08.10.2013 22:58, schrieb Steffen Lehnert:
> Hi,
>
> I have a bunch of custom meta-models which all work fine with EMFStore 1.0.1, except for one EClass.
> Once I create an instance of this class via the "New Model Element" feature of the EMF client, several null-pointer exceptions are thrown and the client is not able to open the editor for the model element.
>
> This class and its meta-model consist of no custom code. Everything was generated with EMF Ecore.
> After a bit of debugging, I've noticed that this class is the only one that contains EReferences of the type "EObject".
> If I delete those references from the class or change their type to anything other than "EObject" the problem is gone.
>
> So it seems to me that there is a problem with EReferences of the type EObject.
> However, the same meta-model and all of its classes were working fine with EMFStore/ECP 0.9.3, though.
>
> I'm using the following software configuration:
> Eclipse Platform 4.3
> Eclipse SDK 4.3
> Eclipse RCP 4.3
> EMFStore 1.0.1
> EMF Client Platform 1.0.2
> EMF Client Platform EMFStore Integration 1.0.2
> ECP SDK Feature 1.0.2
>
> I'm attaching the output of the console that was thrown after creating an instance of this EClass as it might be of use.
>
> Now my question would be whether this is a new "bug" of EMFStore 1.0.1 as it was working fine with 0.9.3, or whether I forget to change something after upgrading from 0.9.3 to 1.0.1?
> Any help ore ideas would be appreciated!
>
> Regards,
> Steffen
>
--
Maximilian Kögel
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
|
Re: [EMFStore] EReference of Type "EObject" throws null pointer exception in EMFS [message #1131257 is a reply to message #1131119] |
Thu, 10 October 2013 10:59 |
Maximilian Koegel Messages: 253 Registered: July 2009 |
Senior Member |
|
|
Hi Steffen,
we can reproduce the problem and have opened a bug:
https://bugs.eclipse.org/bugs/show_bug.cgi?id=419116
The problem is caused by the LabelProvider for EObjects (EMF Core) which
returns a URI instead of a URL, which we did not handle so far. We have
prepared a fix and will deliver it as part of a hotfix release (1.0.3)
in the upcoming days.
Cheers,
Maximilian
Am 10.10.2013 09:57, schrieb Maximilian Koegel:
> Hi Steffen,
>
> thank you for your post!
> This seems to be a bug in the EMF Client Platform UI. But since I am
> also responsible for ECP, I will look into it today and get back to you.
>
> Cheers,
> Maximilian
>
> Am 08.10.2013 22:58, schrieb Steffen Lehnert:
>> Hi,
>>
>> I have a bunch of custom meta-models which all work fine with EMFStore 1.0.1, except for one EClass.
>> Once I create an instance of this class via the "New Model Element" feature of the EMF client, several null-pointer exceptions are thrown and the client is not able to open the editor for the model element.
>>
>> This class and its meta-model consist of no custom code. Everything was generated with EMF Ecore.
>> After a bit of debugging, I've noticed that this class is the only one that contains EReferences of the type "EObject".
>> If I delete those references from the class or change their type to anything other than "EObject" the problem is gone.
>>
>> So it seems to me that there is a problem with EReferences of the type EObject.
>> However, the same meta-model and all of its classes were working fine with EMFStore/ECP 0.9.3, though.
>>
>> I'm using the following software configuration:
>> Eclipse Platform 4.3
>> Eclipse SDK 4.3
>> Eclipse RCP 4.3
>> EMFStore 1.0.1
>> EMF Client Platform 1.0.2
>> EMF Client Platform EMFStore Integration 1.0.2
>> ECP SDK Feature 1.0.2
>>
>> I'm attaching the output of the console that was thrown after creating an instance of this EClass as it might be of use.
>>
>> Now my question would be whether this is a new "bug" of EMFStore 1.0.1 as it was working fine with 0.9.3, or whether I forget to change something after upgrading from 0.9.3 to 1.0.1?
>> Any help ore ideas would be appreciated!
>>
>> Regards,
>> Steffen
>>
>
>
--
Maximilian Kögel
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
| | | | |
Re: [EMFStore] EReference of Type "EObject" throws null pointer exception [message #1219720 is a reply to message #1219693] |
Thu, 05 December 2013 14:55 |
Eugen Neufeld Messages: 63 Registered: March 2012 |
Member |
|
|
Hi Steffen,
I checked our source code, and the fix is still there.
Could you please paste the stacktrace from ECP 1.1.1 you get?
Thank you,
Eugen
Am 05.12.2013 13:43, schrieb Steffen Lehnert:
> Hey Guys,
>
> I hate to bother you with this issues again, but it seems as if you've
> reintroduced the problem while upgrading from ECP 1.0.3. to ECP 1.1.1.
>
> I've tested this with two new Eclipse Kepler installations, one running
> ECP 1.0.3, the other running ECP 1.1.1.
> The 1.1.1. version doesn't work with models that contain EReferences
> towards EObjects. It's throwing the same exceptions as the version prior
> to 1.0.3, so the old problem seems to be back...
>
> Cheers,
> Steffen
>
--
Eugen Neufeld
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
| |
Re: [EMFStore] EReference of Type "EObject" throws null pointer e [message #1219848 is a reply to message #1219762] |
Fri, 06 December 2013 09:21 |
Eugen Neufeld Messages: 63 Registered: March 2012 |
Member |
|
|
Hi Steffen,
thank you for the Stacktrace.
In 1.1 we introduced a so called ViewModel
(http://eclipsesource.com/blogs/tutorials/emf-client-platform-how-to-customize-the-editor-layout/).
As far as I can see in the Stacktrace, you are missing some plugins in
your launch configuration.
Please check that you have added org.eclipse.emf.ecp.ui.view and
org.eclipse.emf.ecp.ui.view.swt to your launch configuration.
If you have customized the view model and are using concepts defined in
other plugins like group then also add the corresponding ui and ui.swt
plugins, too , e.g. org.eclipse.emf.ecp.view.group.model ->
org.eclipse.emf.ecp.view.group.ui, org.eclipse.emf.ecp.view.group.ui.swt
Cheers,
Eugen
Am 05.12.2013 18:04, schrieb Steffen Lehnert:
> Hi Eugen,
>
> you're post made me wonder whether I've done something stupid so I've run the whole test again and obtained the same results.
> I'm attaching the stacktrace to my post.
>
> Steffen
>
> Eugen Neufeld wrote on Thu, 05 December 2013 09:55
>> Hi Steffen,
>> I checked our source code, and the fix is still there.
>> Could you please paste the stacktrace from ECP 1.1.1 you get?
>>
>> Thank you,
>> Eugen
>
>
--
Eugen Neufeld
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
|
Re: [EMFStore] EReference of Type "EObject" throws null pointer e [message #1219933 is a reply to message #1219848] |
Fri, 06 December 2013 21:28 |
Steffen Lehnert Messages: 22 Registered: October 2013 |
Junior Member |
|
|
Hi Eugen,
thanks for the message. Those two plug-ins were already activated, however some other ECP plug-ins were missing.
After reading your post I simply activated all ECP and EMFStore plug-ins and the problem was solved.
Thanks again!
I just wonder why the "Add required plug-ins" didn't add them to the launch configuration in the first place.
Cheers,
Steffen
Eugen Neufeld wrote on Fri, 06 December 2013 04:21Hi Steffen,
thank you for the Stacktrace.
In 1.1 we introduced a so called ViewModel
(http://eclipsesource.com/blogs/tutorials/emf-client-platform-how-to-customize-the-editor-layout/).
As far as I can see in the Stacktrace, you are missing some plugins in
your launch configuration.
Please check that you have added org.eclipse.emf.ecp.ui.view and
org.eclipse.emf.ecp.ui.view.swt to your launch configuration.
If you have customized the view model and are using concepts defined in
other plugins like group then also add the corresponding ui and ui.swt
plugins, too , e.g. org.eclipse.emf.ecp.view.group.model ->
org.eclipse.emf.ecp.view.group.ui, org.eclipse.emf.ecp.view.group.ui.swt
Cheers,
Eugen
Am 05.12.2013 18:04, schrieb Steffen Lehnert:
> Hi Eugen,
>
> you're post made me wonder whether I've done something stupid so I've run the whole test again and obtained the same results.
> I'm attaching the stacktrace to my post.
>
> Steffen
>
> Eugen Neufeld wrote on Thu, 05 December 2013 09:55
>> Hi Steffen,
>> I checked our source code, and the fix is still there.
>> Could you please paste the stacktrace from ECP 1.1.1 you get?
>>
>> Thank you,
>> Eugen
>
>
--
Eugen Neufeld
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
|
Re: [EMFStore] EReference of Type "EObject" throws null po [message #1220022 is a reply to message #1219933] |
Mon, 09 December 2013 08:43 |
Eugen Neufeld Messages: 63 Registered: March 2012 |
Member |
|
|
Hi Steffen,
I'm glad that it now works for you.
The "Add required plug-ins" doesn't work because the missing plugins
aren't referenced as dependencies from the other plugins. As you can
imagine the view model renderer have dependencies to the corresponding
model plugins but not vice-versa.
Cheers,
Eugen
Am 06.12.2013 22:28, schrieb Steffen Lehnert:
> Hi Eugen,
>
> thanks for the message. Those two plug-ins were already activated,
> however some other ECP plug-ins were missing.
> After reading your post I simply activated all ECP and EMFStore plug-ins
> and the problem was solved.
> Thanks again!
>
> I just wonder why the "Add required plug-ins" didn't add them to the
> launch configuration in the first place.
>
> Cheers,
> Steffen
>
> Eugen Neufeld wrote on Fri, 06 December 2013 04:21
>> Hi Steffen,
>> thank you for the Stacktrace.
>>
>> In 1.1 we introduced a so called ViewModel
>> (http://eclipsesource.com/blogs/tutorials/emf-client-platform-how-to-customize-the-editor-layout/).
>>
>>
>> As far as I can see in the Stacktrace, you are missing some plugins in
>> your launch configuration.
>> Please check that you have added org.eclipse.emf.ecp.ui.view and
>> org.eclipse.emf.ecp.ui.view.swt to your launch configuration.
>>
>> If you have customized the view model and are using concepts defined
>> in other plugins like group then also add the corresponding ui and
>> ui.swt plugins, too , e.g. org.eclipse.emf.ecp.view.group.model ->
>> org.eclipse.emf.ecp.view.group.ui, org.eclipse.emf.ecp.view.group.ui.swt
>>
>>
>> Cheers,
>> Eugen
>>
>> Am 05.12.2013 18:04, schrieb Steffen Lehnert:
>> > Hi Eugen,
>> >
>> > you're post made me wonder whether I've done something stupid so
>> I've run the whole test again and obtained the same results.
>> > I'm attaching the stacktrace to my post.
>> >
>> > Steffen
>> >
>> > Eugen Neufeld wrote on Thu, 05 December 2013 09:55
>> >> Hi Steffen,
>> >> I checked our source code, and the fix is still there.
>> >> Could you please paste the stacktrace from ECP 1.1.1 you get?
>> >>
>> >> Thank you,
>> >> Eugen
>> >
>> >
>>
>>
>> --
>> Eugen Neufeld
>>
>> Get Professional Eclipse Support: http://eclipsesource.com/munich
>
>
--
Eugen Neufeld
Get Professional Eclipse Support: http://eclipsesource.com/munich
|
|
|
Goto Forum:
Current Time: Thu Sep 26 00:57:37 GMT 2024
Powered by FUDForum. Page generated in 0.04607 seconds
|