| Summary: | NPE when unloading resources of models which use MinimalEObjectImpl and ExtendedResourceAdapter | ||
|---|---|---|---|
| Product: | [Automotive] Sphinx | Reporter: | Stephan Eberle <stephaneberle9> |
| Component: | Core | Assignee: | Project Inbox <sphinx-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | ||
| Version: | 0.7.0 | ||
| Target Milestone: | 0.7.0 | ||
| Hardware: | All | ||
| OS: | All | ||
| Whiteboard: | |||
Fixed by excluding MinimalEObject#eFlags and #eStorage fields from reflective nullification. This makes sure that "cleared" MinimalEObjects can still be converted to proxies and identified as such. Mass-closing Resolved tickets |
java.lang.NullPointerException at org.eclipse.emf.ecore.impl.MinimalEObjectImpl.addField(MinimalEObjectImpl.java:412) at org.eclipse.emf.ecore.impl.MinimalEObjectImpl.setField(MinimalEObjectImpl.java:344) at org.eclipse.emf.ecore.impl.MinimalEObjectImpl.eSetProxyURI(MinimalEObjectImpl.java:642) at org.eclipse.sphinx.emf.resource.ExtendedResourceAdapter.unloaded(ExtendedResourceAdapter.java:123) at org.eclipse.sphinx.examples.hummingbird20.util.Hummingbird20ResourceImpl.unloaded(Hummingbird20ResourceImpl.java:72) at org.eclipse.emf.ecore.resource.impl.ResourceImpl.doUnload(ResourceImpl.java:1624) at org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl.doUnload(XMLResourceImpl.java:506) at org.eclipse.emf.ecore.resource.impl.ResourceImpl.unload(ResourceImpl.java:1639) at org.eclipse.sphinx.emf.util.EcoreResourceUtil.unloadResource(EcoreResourceUtil.java:913) at org.eclipse.sphinx.emf.util.EcorePlatformUtil$27.run(EcorePlatformUtil.java:1973) at org.eclipse.emf.transaction.impl.TransactionalEditingDomainImpl.runExclusive(TransactionalEditingDomainImpl.java:328) at org.eclipse.sphinx.emf.util.EcorePlatformUtil.unloadResources(EcorePlatformUtil.java:1965) at org.eclipse.sphinx.emf.workspace.loading.ModelLoadManager.runUnloadModelResources(ModelLoadManager.java:1023) at org.eclipse.sphinx.emf.workspace.loading.ModelLoadManager.access$4(ModelLoadManager.java:1013) at org.eclipse.sphinx.emf.workspace.loading.ModelLoadManager$5.run(ModelLoadManager.java:990) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) The cause is in org.eclipse.sphinx.emf.resource.ExtendedResourceAdapter#unloaded(EObject), line 114, where the fields are cleared by reflection.