Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » CDO adding object from sub-model
CDO adding object from sub-model [message #422959] Fri, 19 September 2008 16:09 Go to next message
Paul Richardson is currently offline Paul RichardsonFriend
Messages: 33
Registered: July 2009
Member
Hi,

I have my main tool model which includes such things as folders and
elements. Upon connecting to a CDO server I can add certain elements to
the project as long as they are part of the tool model.

However, additional elements come from a second reference model which
extends the tool model. Thus, for example,

RefModelElement1 extends ProjectElement

where RefModelElement1 is in the reference model and ProjectElement is
in the tool model.

So when I add an instance of RefModelElement1 to the project and commit
it, I get a null pointer exception.

I thought it may be to do with having the transaction open before
registering RefModelElement1's package but that seems to make little
difference. I register RefModelElement1's package using:

cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());

and that does place all the packages into the CDOSession package manager.

The consequence of the NPE is that the server returns an exception
suggesting the object is unresolvable. This exception is below the NPE.

Any ideas please.

Regards

PGR


NPE on the client
class java.lang.NullPointerException
Message:null

org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)

Error on the server
[ERROR] ClassRef unresolveable:
CDOClassRef(http://www.example.co.uk/technology/all, 8)

java.lang.IllegalStateException: ClassRef unresolveable:
CDOClassRef(http://www.example.co.uk/technology/all, 8)

at
org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)

at
org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
Re: CDO adding object from sub-model [message #422961 is a reply to message #422959] Fri, 19 September 2008 16:16 Go to previous messageGo to next message
Simon Mc Duff is currently offline Simon Mc DuffFriend
Messages: 596
Registered: July 2009
Senior Member
Which version of CDO are you using ?

A problem was found in analyzeNewPackages:

246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower than before
https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465

But we change it as well.. so maybe we introduce a problem.

Simon

"phantomjinx" <p.g.richardson@phantomjinx.co.uk> a
Re: CDO adding object from sub-model [message #423032 is a reply to message #422961] Sun, 21 September 2008 13:08 Go to previous messageGo to next message
Paul Richardson is currently offline Paul RichardsonFriend
Messages: 33
Registered: July 2009
Member
Simon,

version 2.0.0 stable build: 200809110653

The date of the stable build seems to be during that bug being fixed so
dont think the patch got applied. What do you think? Should I checkout
HEAD and give that a try?

Regards

PGR

Simon McDuff wrote:
> Which version of CDO are you using ?
>
> A problem was found in analyzeNewPackages:
>
> 246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower than before
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465
>
> But we change it as well.. so maybe we introduce a problem.
>
> Simon
>
> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le message de
> news: gb0isc$93f$1@build.eclipse.org...
>> Hi,
>>
>> I have my main tool model which includes such things as folders and
>> elements. Upon connecting to a CDO server I can add certain elements to
>> the project as long as they are part of the tool model.
>>
>> However, additional elements come from a second reference model which
>> extends the tool model. Thus, for example,
>>
>> RefModelElement1 extends ProjectElement
>>
>> where RefModelElement1 is in the reference model and ProjectElement is in
>> the tool model.
>>
>> So when I add an instance of RefModelElement1 to the project and commit
>> it, I get a null pointer exception.
>>
>> I thought it may be to do with having the transaction open before
>> registering RefModelElement1's package but that seems to make little
>> difference. I register RefModelElement1's package using:
>>
>> cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());
>>
>> and that does place all the packages into the CDOSession package manager.
>>
>> The consequence of the NPE is that the server returns an exception
>> suggesting the object is unresolvable. This exception is below the NPE.
>>
>> Any ideas please.
>>
>> Regards
>>
>> PGR
>>
>>
>> NPE on the client
>> class java.lang.NullPointerException
>> Message:null
>>
>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
>> org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
>> org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
>> org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
>> org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
>> org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
>> org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
>> org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
>> org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
>> org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
>> isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)
>>
>> Error on the server
>> [ERROR] ClassRef unresolveable:
>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>> java.lang.IllegalStateException: ClassRef unresolveable:
>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>> at
>> org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)
>> at
>> org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
>
>
Re: CDO adding object from sub-model [message #423033 is a reply to message #423032] Sun, 21 September 2008 13:16 Go to previous messageGo to next message
Simon Mc Duff is currently offline Simon Mc DuffFriend
Messages: 596
Registered: July 2009
Senior Member
It is worth it using HEAD.
If it is too complicated, I think we will soon publish an integration build.

Let us know what you decide! (Wait for the integration or take HEAD)


Simon


"phantomjinx" <p.g.richardson@phantomjinx.co.uk> a
Re: CDO adding object from sub-model [message #423037 is a reply to message #423033] Sun, 21 September 2008 20:31 Go to previous messageGo to next message
Paul Richardson is currently offline Paul RichardsonFriend
Messages: 33
Registered: July 2009
Member
Looking into getting HEAD. Got as far as checking out the projects and
building them.

Do you happen to have a build script handy that I could build the 10 or
so jars (on bulk) at all? I would write my own but it occurs that this
problem must already have been solved.

Regards

PGR

Simon McDuff wrote:
> It is worth it using HEAD.
> If it is too complicated, I think we will soon publish an integration build.
>
> Let us know what you decide! (Wait for the integration or take HEAD)
>
>
> Simon
>
>
> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le message de
> news: 48D64742.5020703@phantomjinx.co.uk...
>> Simon,
>>
>> version 2.0.0 stable build: 200809110653
>>
>> The date of the stable build seems to be during that bug being fixed so
>> dont think the patch got applied. What do you think? Should I checkout
>> HEAD and give that a try?
>>
>> Regards
>>
>> PGR
>>
>> Simon McDuff wrote:
>>> Which version of CDO are you using ?
>>>
>>> A problem was found in analyzeNewPackages:
>>>
>>> 246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower than before
>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465
>>>
>>> But we change it as well.. so maybe we introduce a problem.
>>>
>>> Simon
>>>
>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le message
>>> de news: gb0isc$93f$1@build.eclipse.org...
>>>> Hi,
>>>>
>>>> I have my main tool model which includes such things as folders and
>>>> elements. Upon connecting to a CDO server I can add certain elements to
>>>> the project as long as they are part of the tool model.
>>>>
>>>> However, additional elements come from a second reference model which
>>>> extends the tool model. Thus, for example,
>>>>
>>>> RefModelElement1 extends ProjectElement
>>>>
>>>> where RefModelElement1 is in the reference model and ProjectElement is
>>>> in the tool model.
>>>>
>>>> So when I add an instance of RefModelElement1 to the project and commit
>>>> it, I get a null pointer exception.
>>>>
>>>> I thought it may be to do with having the transaction open before
>>>> registering RefModelElement1's package but that seems to make little
>>>> difference. I register RefModelElement1's package using:
>>>>
>>>> cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());
>>>>
>>>> and that does place all the packages into the CDOSession package
>>>> manager.
>>>>
>>>> The consequence of the NPE is that the server returns an exception
>>>> suggesting the object is unresolvable. This exception is below the NPE.
>>>>
>>>> Any ideas please.
>>>>
>>>> Regards
>>>>
>>>> PGR
>>>>
>>>>
>>>> NPE on the client
>>>> class java.lang.NullPointerException
>>>> Message:null
>>>>
>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
>>>> org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
>>>> org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
>>>> org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
>>>> org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
>>>> org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
>>>> org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
>>>> org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
>>>> org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
>>>> org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
>>>> isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)
>>>>
>>>> Error on the server
>>>> [ERROR] ClassRef unresolveable:
>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>> java.lang.IllegalStateException: ClassRef unresolveable:
>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>> at
>>>> org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)
>>>> at
>>>> org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
>
Re: CDO adding object from sub-model [message #423040 is a reply to message #423037] Mon, 22 September 2008 01:51 Go to previous messageGo to next message
Simon Mc Duff is currently offline Simon Mc DuffFriend
Messages: 596
Registered: July 2009
Senior Member
Unfortunately, I'm not aware of a script.

In the future, we will try to have an integration build available every
weeks. (after the EMF build).

Simon


"phantomjinx" <p.g.richardson@phantomjinx.co.uk> a
Re: CDO adding object from sub-model [message #423048 is a reply to message #423040] Mon, 22 September 2008 10:14 Go to previous messageGo to next message
Paul Richardson is currently offline Paul RichardsonFriend
Messages: 33
Registered: July 2009
Member
This is a multi-part message in MIME format.
--------------050705010008070000070101
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit

Simon,

Oh well, here is one I rustled up this morning. Not very elegant but
does the job and matches the contents of the released jars in the latest
stable build.

Regards

PGR

Simon McDuff wrote:
> Unfortunately, I'm not aware of a script.
>
> In the future, we will try to have an integration build available every
> weeks. (after the EMF build).
>
> Simon
>
>
> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a
Re: CDO adding object from sub-model [message #423051 is a reply to message #423048] Mon, 22 September 2008 10:37 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
Hi Roger,

Can you explain why you are not just using the downloaded plugins? Or,
if these are too old, just use "Export | PDE | Deployable plugins and
fragments"? While your script *may* currently work I'm worried about the
maintainability. We already put a huge effort into our unattended build
and I'd probably not be very happy to maintain an additional build ;-)

Cheers
/Eike


phantomjinx schrieb:
> Simon,
>
> Oh well, here is one I rustled up this morning. Not very elegant but
> does the job and matches the contents of the released jars in the
> latest stable build.
>
> Regards
>
> PGR
>
> Simon McDuff wrote:
>> Unfortunately, I'm not aware of a script.
>>
>> In the future, we will try to have an integration build available
>> every weeks. (after the EMF build).
>>
>> Simon
>>
>>
>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>> message de news: 48D6AF2B.1070902@phantomjinx.co.uk...
>>> Looking into getting HEAD. Got as far as checking out the projects
>>> and building them.
>>>
>>> Do you happen to have a build script handy that I could build the 10
>>> or so jars (on bulk) at all? I would write my own but it occurs that
>>> this problem must already have been solved.
>>>
>>> Regards
>>>
>>> PGR
>>>
>>> Simon McDuff wrote:
>>>> It is worth it using HEAD.
>>>> If it is too complicated, I think we will soon publish an
>>>> integration build.
>>>>
>>>> Let us know what you decide! (Wait for the integration or take HEAD)
>>>>
>>>>
>>>> Simon
>>>>
>>>>
>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>> message de news: 48D64742.5020703@phantomjinx.co.uk...
>>>>> Simon,
>>>>>
>>>>> version 2.0.0 stable build: 200809110653
>>>>>
>>>>> The date of the stable build seems to be during that bug being
>>>>> fixed so dont think the patch got applied. What do you think?
>>>>> Should I checkout HEAD and give that a try?
>>>>>
>>>>> Regards
>>>>>
>>>>> PGR
>>>>>
>>>>> Simon McDuff wrote:
>>>>>> Which version of CDO are you using ?
>>>>>>
>>>>>> A problem was found in analyzeNewPackages:
>>>>>>
>>>>>> 246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower
>>>>>> than before
>>>>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465
>>>>>>
>>>>>> But we change it as well.. so maybe we introduce a problem.
>>>>>>
>>>>>> Simon
>>>>>>
>>>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>>>> message de news: gb0isc$93f$1@build.eclipse.org...
>>>>>>> Hi,
>>>>>>>
>>>>>>> I have my main tool model which includes such things as folders
>>>>>>> and elements. Upon connecting to a CDO server I can add certain
>>>>>>> elements to the project as long as they are part of the tool model.
>>>>>>>
>>>>>>> However, additional elements come from a second reference model
>>>>>>> which extends the tool model. Thus, for example,
>>>>>>>
>>>>>>> RefModelElement1 extends ProjectElement
>>>>>>>
>>>>>>> where RefModelElement1 is in the reference model and
>>>>>>> ProjectElement is in the tool model.
>>>>>>>
>>>>>>> So when I add an instance of RefModelElement1 to the project and
>>>>>>> commit it, I get a null pointer exception.
>>>>>>>
>>>>>>> I thought it may be to do with having the transaction open
>>>>>>> before registering RefModelElement1's package but that seems to
>>>>>>> make little difference. I register RefModelElement1's package
>>>>>>> using:
>>>>>>>
>>>>>>> cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());
>>>>>>>
>>>>>>>
>>>>>>> and that does place all the packages into the CDOSession package
>>>>>>> manager.
>>>>>>>
>>>>>>> The consequence of the NPE is that the server returns an
>>>>>>> exception suggesting the object is unresolvable. This exception
>>>>>>> is below the NPE.
>>>>>>>
>>>>>>> Any ideas please.
>>>>>>>
>>>>>>> Regards
>>>>>>>
>>>>>>> PGR
>>>>>>>
>>>>>>>
>>>>>>> NPE on the client
>>>>>>> class java.lang.NullPointerException
>>>>>>> Message:null
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
>>>>>>>
>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
>>>>>>>
>>>>>>> org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
>>>>>>> org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
>>>>>>>
>>>>>>> org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
>>>>>>>
>>>>>>> org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
>>>>>>>
>>>>>>> org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
>>>>>>>
>>>>>>> isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)
>>>>>>>
>>>>>>>
>>>>>>> Error on the server
>>>>>>> [ERROR] ClassRef unresolveable:
>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>> java.lang.IllegalStateException: ClassRef unresolveable:
>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>> at
>>>>>>> org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)
>>>>>>>
>>>>>>> at
>>>>>>> org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
>>>>>>>
>>
>>
>


Re: CDO adding object from sub-model [message #423057 is a reply to message #423051] Mon, 22 September 2008 11:37 Go to previous messageGo to next message
Paul Richardson is currently offline Paul RichardsonFriend
Messages: 33
Registered: July 2009
Member
Eike,

Its Paul (a.k.a. PGR) not Roger but assume your reply is meant for me ;)

Absolutely no reason at all for not using "Export | PDE | Deployable
plugins and fragments" other than I didnt know it was there. Not yet up
to speed with eclipse plugin development as my main platform is Netbeans.

Not to mention my version of the ant script does a little more in that
it places the jars in the correct locations for the Netbeans
environment. So feel free to ignore my build script.

I was finding the downloaded stable build plugins were throwing an
exception henee Simon suggested I try HEAD. Currently, the latter seems
to be doing the job and now I have determined how trace works, things
seems to be progressing a little better than over the weekend.

Regards

PGR

Eike Stepper wrote:
> Hi Roger,
>
> Can you explain why you are not just using the downloaded plugins? Or,
> if these are too old, just use "Export | PDE | Deployable plugins and
> fragments"? While your script *may* currently work I'm worried about the
> maintainability. We already put a huge effort into our unattended build
> and I'd probably not be very happy to maintain an additional build ;-)
>
> Cheers
> /Eike
>
>
> phantomjinx schrieb:
>> Simon,
>>
>> Oh well, here is one I rustled up this morning. Not very elegant but
>> does the job and matches the contents of the released jars in the
>> latest stable build.
>>
>> Regards
>>
>> PGR
>>
>> Simon McDuff wrote:
>>> Unfortunately, I'm not aware of a script.
>>>
>>> In the future, we will try to have an integration build available
>>> every weeks. (after the EMF build).
>>>
>>> Simon
>>>
>>>
>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>> message de news: 48D6AF2B.1070902@phantomjinx.co.uk...
>>>> Looking into getting HEAD. Got as far as checking out the projects
>>>> and building them.
>>>>
>>>> Do you happen to have a build script handy that I could build the 10
>>>> or so jars (on bulk) at all? I would write my own but it occurs that
>>>> this problem must already have been solved.
>>>>
>>>> Regards
>>>>
>>>> PGR
>>>>
>>>> Simon McDuff wrote:
>>>>> It is worth it using HEAD.
>>>>> If it is too complicated, I think we will soon publish an
>>>>> integration build.
>>>>>
>>>>> Let us know what you decide! (Wait for the integration or take HEAD)
>>>>>
>>>>>
>>>>> Simon
>>>>>
>>>>>
>>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>>> message de news: 48D64742.5020703@phantomjinx.co.uk...
>>>>>> Simon,
>>>>>>
>>>>>> version 2.0.0 stable build: 200809110653
>>>>>>
>>>>>> The date of the stable build seems to be during that bug being
>>>>>> fixed so dont think the patch got applied. What do you think?
>>>>>> Should I checkout HEAD and give that a try?
>>>>>>
>>>>>> Regards
>>>>>>
>>>>>> PGR
>>>>>>
>>>>>> Simon McDuff wrote:
>>>>>>> Which version of CDO are you using ?
>>>>>>>
>>>>>>> A problem was found in analyzeNewPackages:
>>>>>>>
>>>>>>> 246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower
>>>>>>> than before
>>>>>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465
>>>>>>>
>>>>>>> But we change it as well.. so maybe we introduce a problem.
>>>>>>>
>>>>>>> Simon
>>>>>>>
>>>>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>>>>> message de news: gb0isc$93f$1@build.eclipse.org...
>>>>>>>> Hi,
>>>>>>>>
>>>>>>>> I have my main tool model which includes such things as folders
>>>>>>>> and elements. Upon connecting to a CDO server I can add certain
>>>>>>>> elements to the project as long as they are part of the tool model.
>>>>>>>>
>>>>>>>> However, additional elements come from a second reference model
>>>>>>>> which extends the tool model. Thus, for example,
>>>>>>>>
>>>>>>>> RefModelElement1 extends ProjectElement
>>>>>>>>
>>>>>>>> where RefModelElement1 is in the reference model and
>>>>>>>> ProjectElement is in the tool model.
>>>>>>>>
>>>>>>>> So when I add an instance of RefModelElement1 to the project and
>>>>>>>> commit it, I get a null pointer exception.
>>>>>>>>
>>>>>>>> I thought it may be to do with having the transaction open
>>>>>>>> before registering RefModelElement1's package but that seems to
>>>>>>>> make little difference. I register RefModelElement1's package
>>>>>>>> using:
>>>>>>>>
>>>>>>>> cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());
>>>>>>>>
>>>>>>>>
>>>>>>>> and that does place all the packages into the CDOSession package
>>>>>>>> manager.
>>>>>>>>
>>>>>>>> The consequence of the NPE is that the server returns an
>>>>>>>> exception suggesting the object is unresolvable. This exception
>>>>>>>> is below the NPE.
>>>>>>>>
>>>>>>>> Any ideas please.
>>>>>>>>
>>>>>>>> Regards
>>>>>>>>
>>>>>>>> PGR
>>>>>>>>
>>>>>>>>
>>>>>>>> NPE on the client
>>>>>>>> class java.lang.NullPointerException
>>>>>>>> Message:null
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
>>>>>>>>
>>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
>>>>>>>>
>>>>>>>> org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
>>>>>>>> org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
>>>>>>>>
>>>>>>>> org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
>>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
>>>>>>>>
>>>>>>>> org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
>>>>>>>>
>>>>>>>> org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
>>>>>>>>
>>>>>>>> isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)
>>>>>>>>
>>>>>>>>
>>>>>>>> Error on the server
>>>>>>>> [ERROR] ClassRef unresolveable:
>>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>>> java.lang.IllegalStateException: ClassRef unresolveable:
>>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>>> at
>>>>>>>> org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)
>>>>>>>>
>>>>>>>> at
>>>>>>>> org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
>>>>>>>>
>>>
>>>
>>
Re: CDO adding object from sub-model [message #423066 is a reply to message #423057] Mon, 22 September 2008 15:02 Go to previous messageGo to next message
Eike Stepper is currently offline Eike StepperFriend
Messages: 6682
Registered: July 2009
Senior Member
phantomjinx schrieb:
> Eike,
>
> Its Paul (a.k.a. PGR) not Roger but assume your reply is meant for me ;)
Apologies!!! Consider that I have hard times with all these acronyms
(like PGR, CDO, ...) ;-)

>
> Absolutely no reason at all for not using "Export | PDE | Deployable
> plugins and fragments" other than I didnt know it was there. Not yet
> up to speed with eclipse plugin development as my main platform is
> Netbeans.
>
> Not to mention my version of the ant script does a little more in that
> it places the jars in the correct locations for the Netbeans
> environment. So feel free to ignore my build script.
>
> I was finding the downloaded stable build plugins were throwing an
> exception henee Simon suggested I try HEAD. Currently, the latter
> seems to be doing the job and now I have determined how trace works,
> things seems to be progressing a little better than over the weekend.
Nice to hear that you can start with great motivation into the new week!

Cheers
/Eike

>
> Regards
>
> PGR
>
> Eike Stepper wrote:
>> Hi Roger,
>>
>> Can you explain why you are not just using the downloaded plugins?
>> Or, if these are too old, just use "Export | PDE | Deployable plugins
>> and fragments"? While your script *may* currently work I'm worried
>> about the maintainability. We already put a huge effort into our
>> unattended build and I'd probably not be very happy to maintain an
>> additional build ;-)
>>
>> Cheers
>> /Eike
>>
>>
>> phantomjinx schrieb:
>>> Simon,
>>>
>>> Oh well, here is one I rustled up this morning. Not very elegant but
>>> does the job and matches the contents of the released jars in the
>>> latest stable build.
>>>
>>> Regards
>>>
>>> PGR
>>>
>>> Simon McDuff wrote:
>>>> Unfortunately, I'm not aware of a script.
>>>>
>>>> In the future, we will try to have an integration build available
>>>> every weeks. (after the EMF build).
>>>>
>>>> Simon
>>>>
>>>>
>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>> message de news: 48D6AF2B.1070902@phantomjinx.co.uk...
>>>>> Looking into getting HEAD. Got as far as checking out the projects
>>>>> and building them.
>>>>>
>>>>> Do you happen to have a build script handy that I could build the
>>>>> 10 or so jars (on bulk) at all? I would write my own but it occurs
>>>>> that this problem must already have been solved.
>>>>>
>>>>> Regards
>>>>>
>>>>> PGR
>>>>>
>>>>> Simon McDuff wrote:
>>>>>> It is worth it using HEAD.
>>>>>> If it is too complicated, I think we will soon publish an
>>>>>> integration build.
>>>>>>
>>>>>> Let us know what you decide! (Wait for the integration or take HEAD)
>>>>>>
>>>>>>
>>>>>> Simon
>>>>>>
>>>>>>
>>>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans le
>>>>>> message de news: 48D64742.5020703@phantomjinx.co.uk...
>>>>>>> Simon,
>>>>>>>
>>>>>>> version 2.0.0 stable build: 200809110653
>>>>>>>
>>>>>>> The date of the stable build seems to be during that bug being
>>>>>>> fixed so dont think the patch got applied. What do you think?
>>>>>>> Should I checkout HEAD and give that a try?
>>>>>>>
>>>>>>> Regards
>>>>>>>
>>>>>>> PGR
>>>>>>>
>>>>>>> Simon McDuff wrote:
>>>>>>>> Which version of CDO are you using ?
>>>>>>>>
>>>>>>>> A problem was found in analyzeNewPackages:
>>>>>>>>
>>>>>>>> 246465: [PERF] CDOTransactionImpl.AnalyzeNewPackage is slower
>>>>>>>> than before
>>>>>>>> https://bugs.eclipse.org/bugs/show_bug.cgi?id=246465
>>>>>>>>
>>>>>>>> But we change it as well.. so maybe we introduce a problem.
>>>>>>>>
>>>>>>>> Simon
>>>>>>>>
>>>>>>>> "phantomjinx" <p.g.richardson@phantomjinx.co.uk> a écrit dans
>>>>>>>> le message de news: gb0isc$93f$1@build.eclipse.org...
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> I have my main tool model which includes such things as
>>>>>>>>> folders and elements. Upon connecting to a CDO server I can
>>>>>>>>> add certain elements to the project as long as they are part
>>>>>>>>> of the tool model.
>>>>>>>>>
>>>>>>>>> However, additional elements come from a second reference
>>>>>>>>> model which extends the tool model. Thus, for example,
>>>>>>>>>
>>>>>>>>> RefModelElement1 extends ProjectElement
>>>>>>>>>
>>>>>>>>> where RefModelElement1 is in the reference model and
>>>>>>>>> ProjectElement is in the tool model.
>>>>>>>>>
>>>>>>>>> So when I add an instance of RefModelElement1 to the project
>>>>>>>>> and commit it, I get a null pointer exception.
>>>>>>>>>
>>>>>>>>> I thought it may be to do with having the transaction open
>>>>>>>>> before registering RefModelElement1's package but that seems
>>>>>>>>> to make little difference. I register RefModelElement1's
>>>>>>>>> package using:
>>>>>>>>>
>>>>>>>>> cdoSession.getPackageRegistry().putEPackage(RefModelElement1 Instance.eClass().getEPackage());
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> and that does place all the packages into the CDOSession
>>>>>>>>> package manager.
>>>>>>>>>
>>>>>>>>> The consequence of the NPE is that the server returns an
>>>>>>>>> exception suggesting the object is unresolvable. This
>>>>>>>>> exception is below the NPE.
>>>>>>>>>
>>>>>>>>> Any ideas please.
>>>>>>>>>
>>>>>>>>> Regards
>>>>>>>>>
>>>>>>>>> PGR
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> NPE on the client
>>>>>>>>> class java.lang.NullPointerException
>>>>>>>>> Message:null
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirmingNewPackage(CommitTransactionRequest.java:195)
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:94)
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CommitTransactionReque st.confirming(CommitTransactionRequest.java:1)
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.protocol.CDOClientRequest.confi rming(CDOClientRequest.java:102)
>>>>>>>>>
>>>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.execute(Req uestWithConfirmation.java:69)
>>>>>>>>>
>>>>>>>>> org.eclipse.net4j.signal.Signal.runSync(Signal.java:186)
>>>>>>>>> org.eclipse.net4j.signal.SignalProtocol.startSignal(SignalPr otocol.java:300)
>>>>>>>>>
>>>>>>>>> org.eclipse.net4j.signal.SignalActor.send(SignalActor.java:5 0)
>>>>>>>>> org.eclipse.net4j.signal.RequestWithConfirmation.send(Reques tWithConfirmation.java:56)
>>>>>>>>>
>>>>>>>>> org.eclipse.net4j.signal.failover.NOOPFailOverStrategy.send( NOOPFailOverStrategy.java:27)
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.CDOSingleTransactionStrategy.co mmit(CDOSingleTransactionStrategy.java:58)
>>>>>>>>>
>>>>>>>>> org.eclipse.emf.internal.cdo.CDOTransactionImpl.commit(CDOTr ansactionImpl.java:285)
>>>>>>>>>
>>>>>>>>> isse.project.impl.RepositoryConnectionImpl.commit(Repository ConnectionImpl.java:318)
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Error on the server
>>>>>>>>> [ERROR] ClassRef unresolveable:
>>>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>>>> java.lang.IllegalStateException: ClassRef unresolveable:
>>>>>>>>> CDOClassRef(http://www.example.co.uk/technology/all, 8)
>>>>>>>>> at
>>>>>>>>> org.eclipse.emf.cdo.internal.common.CDODataInputImpl.readCDO ClassRefAndResolve(CDODataInputImpl.java:216)
>>>>>>>>>
>>>>>>>>> at
>>>>>>>>> org.eclipse.emf.cdo.internal.common.revision.CDORevisionImpl . <init>(CDORevisionImpl.java:109)
>>>>>>>>>
>>>>
>>>>
>>>


Re: CDO adding object from sub-model [message #427344 is a reply to message #423057] Fri, 13 February 2009 01:19 Go to previous message
Sam is currently offline SamFriend
Messages: 12
Registered: July 2009
Junior Member
I have the exact same null pointer exception thrown, when using the CDO
Session editors for creating resources and cross model entities, on
Version: 3.4.1, Build id: M20080911-1700. In my case:

model 1 has entity A
model 2 has entity B
A is ESuper type of B

Creating B and committing transaction throws exception. I tried creating A
and B within the same resource, and then committing transaction ... with
no result.

Has this issue been addressed in the release I use, or later builds?

Any help is appreciated. Thanks.

Sam.
Previous Topic:[CDO] Explicit Locking feature.
Next Topic:Copying GMF diagram and model
Goto Forum:
  


Current Time: Fri Apr 26 22:47:40 GMT 2024

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

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

Back to the top