Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » [CDO] Meta-reference dynamic objects(Problem with using CDO in a specific meta-context)
[CDO] Meta-reference dynamic objects [message #1842651] Sat, 26 June 2021 20:50 Go to next message
Rauno Ots is currently offline Rauno OtsFriend
Messages: 2
Registered: June 2021
Junior Member
Hi,
thanks for everyone working on CDO.

I have a problem when trying to save a dynamic object of an Eclass stored in the repository that references another model resource from the same repository.

I'm afraid I'm not doing something correct with URI mappings. unfortunately I don't have much experience with EMF URI mappings, but I can reproduce the issue with current CDO tests: I've added a testMetaProxyDynamic() test case in the MetaTest.java (see attachment)

Any help greatly appreciated.

There are various errors I get with different combinations of tries, the current one is:

*******************************************************
MetaTest.testMetaProxyDynamic [MEM-branching, JVM, Native]
*******************************************************
[ERROR] Unresolvable proxy: http://www.eclipse.org/emf/CDO/tests/dynamic-model1/L5
java.lang.IllegalStateException: Unresolvable proxy: http://www.eclipse.org/emf/CDO/tests/dynamic-model1/L5
	at org.eclipse.emf.cdo.common.model.EMFUtil.safeResolve(EMFUtil.java:721)
	at org.eclipse.emf.cdo.common.model.EMFUtil.safeResolveAll(EMFUtil.java:751)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicatingRead(CommitTransactionIndication.java:189)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicating(CommitTransactionIndication.java:102)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CDOServerIndicationWithMonitoring.indicating(CDOServerIndicationWithMonitoring.java:118)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.indicating(IndicationWithMonitoring.java:87)
	at org.eclipse.net4j.signal.IndicationWithResponse.doExtendedInput(IndicationWithResponse.java:100)
	at org.eclipse.net4j.signal.Signal.doInput(Signal.java:391)
	at org.eclipse.net4j.signal.IndicationWithResponse.execute(IndicationWithResponse.java:73)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.execute(IndicationWithMonitoring.java:66)
	at org.eclipse.net4j.signal.Signal.runSync(Signal.java:297)
	at org.eclipse.net4j.signal.Signal.run(Signal.java:169)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)


org.eclipse.emf.cdo.util.CommitException: org.eclipse.net4j.signal.RemoteException: java.lang.IllegalStateException: Unresolvable proxy: http://www.eclipse.org/emf/CDO/tests/dynamic-model1/L5
	at org.eclipse.emf.internal.cdo.transaction.CDOTransactionImpl.commitSynced(CDOTransactionImpl.java:1730)
	at org.eclipse.emf.internal.cdo.transaction.CDOTransactionImpl.commit(CDOTransactionImpl.java:1625)
	at org.eclipse.emf.internal.cdo.transaction.CDOTransactionImpl.commit(CDOTransactionImpl.java:1591)
	at org.eclipse.emf.cdo.tests.MetaTest.testMetaProxyDynamic(MetaTest.java:106)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
	at junit.framework.TestCase.runTest(TestCase.java:177)
	at org.eclipse.net4j.util.tests.AbstractOMTest.access$1(AbstractOMTest.java:1)
	at org.eclipse.net4j.util.tests.AbstractOMTest$3.execute(AbstractOMTest.java:312)
	at org.eclipse.net4j.internal.util.test.TestExecuter.execute(TestExecuter.java:40)
	at org.eclipse.net4j.util.tests.AbstractOMTest.runBare(AbstractOMTest.java:298)
	at org.eclipse.emf.cdo.tests.config.impl.ConfigTest.runBare(ConfigTest.java:647)
	at junit.framework.TestResult$1.protect(TestResult.java:122)
	at junit.framework.TestResult.runProtected(TestResult.java:142)
	at junit.framework.TestResult.run(TestResult.java:125)
	at junit.framework.TestCase.run(TestCase.java:130)
	at org.eclipse.net4j.util.tests.AbstractOMTest.run(AbstractOMTest.java:372)
	at junit.framework.TestSuite.runTest(TestSuite.java:241)
	at junit.framework.TestSuite.run(TestSuite.java:236)
	at org.junit.internal.runners.JUnit38ClassRunner.run(JUnit38ClassRunner.java:90)
	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:89)
	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:40)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:541)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:768)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:464)
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:210)
Caused by: org.eclipse.net4j.signal.RemoteException: java.lang.IllegalStateException: Unresolvable proxy: http://www.eclipse.org/emf/CDO/tests/dynamic-model1/L5
	at org.eclipse.net4j.signal.RequestWithConfirmation.getRemoteException(RequestWithConfirmation.java:142)
	at org.eclipse.net4j.signal.RequestWithConfirmation.setRemoteException(RequestWithConfirmation.java:131)
	at org.eclipse.net4j.signal.SignalProtocol.handleRemoteException(SignalProtocol.java:562)
	at org.eclipse.net4j.signal.RemoteExceptionIndication.indicating(RemoteExceptionIndication.java:62)
	at org.eclipse.net4j.signal.Indication.doExtendedInput(Indication.java:57)
	at org.eclipse.net4j.signal.Signal.doInput(Signal.java:391)
	at org.eclipse.net4j.signal.Indication.execute(Indication.java:51)
	at org.eclipse.net4j.signal.Signal.runSync(Signal.java:297)
	at org.eclipse.net4j.signal.Signal.run(Signal.java:169)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)
Caused by: java.lang.IllegalStateException: Unresolvable proxy: http://www.eclipse.org/emf/CDO/tests/dynamic-model1/L5
	at org.eclipse.emf.cdo.common.model.EMFUtil.safeResolve(EMFUtil.java:721)
	at org.eclipse.emf.cdo.common.model.EMFUtil.safeResolveAll(EMFUtil.java:751)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicatingRead(CommitTransactionIndication.java:189)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicating(CommitTransactionIndication.java:102)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CDOServerIndicationWithMonitoring.indicating(CDOServerIndicationWithMonitoring.java:118)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.indicating(IndicationWithMonitoring.java:87)
	at org.eclipse.net4j.signal.IndicationWithResponse.doExtendedInput(IndicationWithResponse.java:100)
	at org.eclipse.net4j.signal.Signal.doInput(Signal.java:391)
	at org.eclipse.net4j.signal.IndicationWithResponse.execute(IndicationWithResponse.java:73)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.execute(IndicationWithMonitoring.java:66)
	... 5 more
Re: [CDO] Meta-reference dynamic objects [message #1842758 is a reply to message #1842651] Wed, 30 June 2021 15:39 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6587
Registered: July 2009
Senior Member
Why are you storing the meta models in the instance area (i.e. in CDOResources)? I'm not really sure what's going on in your test case, but I'm going to attach a corrected version of it.

Re: [CDO] Meta-reference dynamic objects [message #1842768 is a reply to message #1842758] Wed, 30 June 2021 19:48 Go to previous message
Rauno Ots is currently offline Rauno OtsFriend
Messages: 2
Registered: June 2021
Junior Member
Hmm... thanks for taking the time to look at my attempt. But that was actually the goal - to have a meta-model and the model both dynamic in the repository (i.e. potentially modifiable by the end-user).

Is it not meant to be possible to use meta-model as model resources with CDO? I was able to create a proof-of-concept for creating an EClass and a dynamic object of that type in the same repository - so up to some level it can work. The problem above seems to occur if there are several levels of dependencies between packages(resources).

Is the scenario above really not supported? If so, I guess the "workaround" would be to just store snapshots of the meta-model resources as binary resources and download them locally to the client side before modelling the instance data.
I'd be happy to hear your perspective and suggestions.
Previous Topic:[CDO] Client startup causes server to load/revision every object
Next Topic:eclipse modeling 4.20 - validation error org.eclipse.net4j.http.server
Goto Forum:
  


Current Time: Tue Sep 21 12:27:57 GMT 2021

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

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

Back to the top