Re: Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Andrus Adamchik
Ok, that much Cayenne does already, so I was surprised to hear that it didn't work for you. If you still think Cayenne doesn't handle it right, please provide the details and we'll look into it. Andrus On Dec 11, 2007, at 11:59 PM, Daniel Abrams wrote: My biggest concern was tripping the

Re: Faulting nested relationships

2007-12-11 Thread Kevin Menard
I have done precisely what you were saying and realize that the relationship is read-only. I just thought it would reflect the latest state of the graph. Moreover, I'd have thought RefreshQuery would have done the trick. I'm beginning to think this may be a caching problem in the ROP client. I'l

Re: Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Daniel Abrams
My biggest concern was tripping the to-many fault, so if it avoids doing that, great. I guess avoiding tripping the to-one fault is nice, but not as serious a problem. When I referred to being "clever" I didn't actually mean avoid tripping the fault, I meant that if the fault was tripped intentio

Re: Faulting nested relationships

2007-12-11 Thread Michael Gentry
My mistake -- I thought you had hand-written a cover method in your getShipments() method. Is the following what might be causing your problem? "Most of flattened relationships are treated as read-only by Cayenne. Only one (the most commonly used) type is read/write. It is many-to-many (n:m) flat

Re: Faulting nested relationships

2007-12-11 Thread Kevin Menard
It's a mapped relationship. Target: Shipment Collection Type: java.util.List Mapping to DbRelationships: orderedItems [orders -> order_entries] shipmentEntries [order_entries -> shipment_entries] shipment [shipment_entries -> shipments] Thanks, Kevin On 12/11/07 3:42 PM, "Michael Gentry" <[EM

Re: Faulting nested relationships

2007-12-11 Thread Michael Gentry
What does your Order#getShipments() look like? Thanks, /dev/mrg On Dec 11, 2007 3:37 PM, Kevin Menard <[EMAIL PROTECTED]> wrote: > Hi, > > I have a nested relationship that I can't seem to update. I have something > like the following: > > Order ---* OrderEntry ---* ShipmentEntry ---* Shipment

Faulting nested relationships

2007-12-11 Thread Kevin Menard
Hi, I have a nested relationship that I can't seem to update. I have something like the following: Order ---* OrderEntry ---* ShipmentEntry ---* Shipment I added a nested relationship on Order to Shipment so I wouldn't have to manually traverse all of that. If I create a new Shipment and assoc

Re: Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Andrus Adamchik
Yep, that's the manual API for people who really know what their are doing with their object graph :-) Andrus On Dec 11, 2007, at 10:24 PM, Peter Karich wrote: Hi Daniel, it seems to me that CayenneDataObject.addToManyTarget(String targetName, DataObject obj, boolean reverse); and Cay

Re: Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Andrus Adamchik
We are doing the "extra clever" thing for to-many, avoiding tripping the list on add. We don't for to-one. Is that the case you are talking about? (Address ->> State is a bit confusing... wouldn't a State have many Addresses? It appears to be the other way around in your example) Anyways, I

Re: Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Peter Karich
Hi Daniel, it seems to me that CayenneDataObject.addToManyTarget(String targetName, DataObject obj, boolean reverse); and CayenneDataObject.setToOneTarget(String targetName, DataObject obj, boolean reverse); could do the job for you. Am I right? Peter.

Suggestion: Don't Fault Relationship On Add

2007-12-11 Thread Daniel Abrams
Hello, I'm new to Cayenne but have a strong background with EOF. I downloaded Cayenne, and found one behavior that I dislike in EOF is actually somewhat worse (by default) with Cayenne, so I would like to propose a change to the default behavior. Imagine a regular one to many relationship Addres

Re: jpa provider

2007-12-11 Thread Andrus Adamchik
I will. Thanks! Andrus On Dec 11, 2007, at 7:48 PM, Gilberto C Andrade wrote: Would you mind check my project?(attach) Gilberto

Re: jpa provider

2007-12-11 Thread Gilberto C Andrade
Would you mind check my project?(attach) Gilberto core.tar.gz Description: GNU Zip compressed data

Re: jpa provider

2007-12-11 Thread Andrus Adamchik
oh and also pom.xml and PessoaServiceTest... Thanks Andrus On Dec 11, 2007, at 7:13 PM, Andrus Adamchik wrote: On Dec 11, 2007, at 7:07 PM, Gilberto C Andrade wrote: Other thing, I've setup toplink and openjpa, the test works! Out of ideas... Would it be possible to open a bug report in Ji

Re: jpa provider

2007-12-11 Thread Andrus Adamchik
On Dec 11, 2007, at 7:07 PM, Gilberto C Andrade wrote: Other thing, I've setup toplink and openjpa, the test works! Out of ideas... Would it be possible to open a bug report in Jira attaching an entity class in question (and any other JPA artifacts you might have - persistence.xml, orm.x

Re: jpa provider

2007-12-11 Thread Gilberto C Andrade
Andrus Adamchik wrote: > Are you seeing this line in the logs prior to the unit tests? > > *** CayenneAgent starting... > Yes! Here: > [EMAIL PROTECTED]:~/dev/netbeans-config/workspace/gfi/core> mvn test -Pcayenne > [INFO] Scanning for projects... > [INFO] > ---

Re: jpa provider

2007-12-11 Thread Andrus Adamchik
Are you seeing this line in the logs prior to the unit tests? *** CayenneAgent starting... This should indicate that the agent is started. If not, check that both "forkMode" and "argLine" match what I posted, of course with $ {version} replaced with the actual Cayenne version. Andrus On

Re: Additional class dependency of a CayenneDataObject class at runtime

2007-12-11 Thread james yong
Hi Andrus, Thanks. I am not using JPA. Following your reply, i am able to narrow down to the root of the problem which is not cayenne. Regards, James -- View this message in context: http://www.nabble.com/Additional-class-dependency-of-a-CayenneDataObject-class-at-runtime-tp14256613p14275760.h