Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Sirius » getting resource malformed URL exception while loading the model(getting resource malformed URL exception while loading the model)
getting resource malformed URL exception while loading the model [message #1801541] Tue, 22 January 2019 06:55 Go to next message
Sharmila D is currently offline Sharmila DFriend
Messages: 81
Registered: June 2018
Member
Hii

I have created an project with artop as model in backend.Iam not using editor plugin.Iam using my own editor.
Iam adding the resources to my Semantic model as like this



EcorePlatformUtil.saveNewModelResource(editingDomain, arxmlfile.getFullPath(), initialModelProperties.getMetaModelDescriptor().getDefaultContentTypeId(), global_rootObject,
false, new NullProgressMonitor());

If add the resource like this then in editor it is writing like the way I want.
eerything works fine upto now. Now I map reference of an element to other element if I close the eclipse and open Iam getting resource malformed exception:unknown protocal error.

please find the below stack trace.

!ENTRY org.eclipse.core.jobs 4 2 2019-01-22 12:25:06.605
!MESSAGE An internal error occurred during: "Loading models".
!STACK 0
java.lang.RuntimeException: The modeling project "fr" is invalid: Problem during loading models: unknown protocol: ar
at org.eclipse.sirius.ui.tools.internal.views.common.modelingproject.OpenRepresentationsFileJob.runInWorkspace(OpenRepresentationsFileJob.java:135)
at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:39)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$1DiagnosticWrappedException: java.net.MalformedURLException: unknown protocol: ar
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.handleDemandLoadException(ResourceSetImpl.java:319)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:278)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$ResourceLocator.demandLoadHelper(ResourceSetImpl.java:804)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl$MappedResourceLocator.getResource(ResourceSetImpl.java:1204)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:352)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getEObject(ResourceSetImpl.java:220)
at org.eclipse.sphinx.emf.ecore.proxymanagement.ProxyResolutionBehavior.eResolveProxyInResourceSet(ProxyResolutionBehavior.java:63)
at org.eclipse.sphinx.emf.ecore.proxymanagement.ProxyResolutionBehavior.eResolveProxy(ProxyResolutionBehavior.java:47)
at org.eclipse.sphinx.emf.ecore.ExtendedMinimalEObjectImpl.eResolveProxy(ExtendedMinimalEObjectImpl.java:28)
at autosar40.swcomponent.composition.impl.SwComponentPrototypeImpl.getType(SwComponentPrototypeImpl.java:211)
at autosar40.swcomponent.composition.impl.SwComponentPrototypeImpl.eGet(SwComponentPrototypeImpl.java:347)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:1011)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:1003)
at org.eclipse.emf.ecore.impl.BasicEObjectImpl.eGet(BasicEObjectImpl.java:998)
at org.eclipse.sirius.ecore.extender.tool.internal.ReferencesResolver.resolveCrossReferences(ReferencesResolver.java:100)
at org.eclipse.sirius.ecore.extender.tool.internal.ReferencesResolver.doResolveAll(ReferencesResolver.java:93)
at org.eclipse.sirius.ecore.extender.tool.internal.ReferencesResolver.resolve(ReferencesResolver.java:74)
at org.eclipse.sirius.ecore.extender.tool.api.ModelUtils.resolveAll(ModelUtils.java:452)
at org.eclipse.sirius.business.internal.session.danalysis.SessionResourcesTracker.forceLoadingOfEveryLinkedResource(SessionResourcesTracker.java:170)
at org.eclipse.sirius.business.internal.session.danalysis.SessionResourcesTracker.initialize(SessionResourcesTracker.java:94)
at org.eclipse.sirius.business.internal.session.danalysis.DAnalysisSessionImpl.open(DAnalysisSessionImpl.java:1175)
at org.eclipse.sirius.business.internal.session.SessionManagerImpl.openSession(SessionManagerImpl.java:386)
at org.eclipse.sirius.ui.tools.internal.views.common.modelingproject.OpenRepresentationsFileJob.performOpenSession(OpenRepresentationsFileJob.java:156)
at org.eclipse.sirius.ui.tools.internal.views.common.modelingproject.OpenRepresentationsFileJob.runInWorkspace(OpenRepresentationsFileJob.java:125)
... 2 more
Caused by: java.net.MalformedURLException: unknown protocol: ar
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at org.eclipse.emf.ecore.resource.impl.URIHandlerImpl.createInputStream(URIHandlerImpl.java:199)
at org.eclipse.emf.ecore.resource.impl.ExtensibleURIConverterImpl.createInputStream(ExtensibleURIConverterImpl.java:360)
at org.eclipse.emf.ecore.resource.impl.ResourceImpl.load(ResourceImpl.java:1269)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoad(ResourceSetImpl.java:259)
at org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandLoadHelper(ResourceSetImpl.java:274)
... 24 more

Please help me what Iam doing wrong
Re: getting resource malformed URL exception while loading the model [message #1801680 is a reply to message #1801541] Thu, 24 January 2019 16:37 Go to previous message
Julien Dupont is currently offline Julien DupontFriend
Messages: 172
Registered: July 2009
Senior Member
Hello Sharmila,

As explain the stack trace you have a problem in the URL built. More exactly there is a "fr" element in the URL of your semantic model and this element seems not to be defined in the metamodel.

Regards,
Previous Topic:[ANN] Sirius 5.1.4
Next Topic:multiple diagram elements for the same domain class
Goto Forum:
  


Current Time: Wed Apr 24 23:11:41 GMT 2024

Powered by FUDForum. Page generated in 0.02851 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top