Discussion:
[Middlegen-user] Why was get/setData() removed? and Relation Fields
Joao Miguel Garcia
2002-06-20 11:55:10 UTC
Permalink
Guys,

1.

In the CVS update below, Aslak Hellesoy removed from the EJB template the getData/setData functionality. Why was this needed? This breaks existing code based on Data Object implementations, and I still cannot see a clear reason for its removal. Was it replaced by an alternative functionality? Was it a simple code drop? If so, how do you suggest an alternative solution?

http://sourceforge.net/mailarchive/message.php?msg_id=1696383

2.

Moreover, in the same update, the CMR relationship fields are set using setID() operations in the ejbCreate methods. I believe that the correct implementation would be setting the Relationship directly IN THE POSTCREATE method, i.e. setCity (City c), instead of setting the ID's. With the current implementation, Weblogic seriously complains with spec violation errors.

Thanks in advance

Hugo José Pinto
***@hugopinto.com
a***@netcom.no
2002-06-20 12:52:08 UTC
Permalink
----- Original Message -----
From: "Joao Miguel Garcia" <***@oni.pt>
Date: Thursday, June 20, 2002 3:45 pm
Subject: [Middlegen-user] Why was get/setData() removed? and Relation
Fields
Post by Joao Miguel Garcia
Guys,
1.
In the CVS update below, Aslak Hellesoy removed from the EJB
template the getData/setData functionality. Why was this needed?
This breaks existing code based on Data Object implementations,
and I still cannot see a clear reason for its removal. Was it
replaced by an alternative functionality? Was it a simple code
drop? If so, how do you suggest an alternative solution?
http://sourceforge.net/mailarchive/message.php?msg_id=1696383
I was trying to avoid using data objects, since they don't support
relations. It's an attempt to encourage the use of the local interfaces
directly instead. I can put them back in if you want to, but I'll
probably put in a switch on the Ant level, allowing to turn them
completely off.

To be honest, it's unclear to me why anyone would use data/value
objects when dealing with local beans. Maybe you can explain that to
me. Since you're on WLS, I assume you're not using legacy remote entity
beans.

Sorry if this caused trouble for you.
Post by Joao Miguel Garcia
2.
Moreover, in the same update, the CMR relationship fields are set
using setID() operations in the ejbCreate methods. I believe that
the correct implementation would be setting the Relationship
directly IN THE POSTCREATE method, i.e. setCity (City c), instead
of setting the ID's. With the current implementation, Weblogic
seriously complains with spec violation errors.
I am testing on WLS 6.1sp2, and it has never choked on this. Aren't you
able to deploy the beans created from the airline sample?

Anyway, if this is the way it should be, I'll move the PK setters to
postCreate()
Post by Joao Miguel Garcia
Thanks in advance
Hugo Jos� Pinto
Aslak Hellesøy
2002-06-20 16:11:05 UTC
Permalink
1) I threw dataobjects back in. See samples/build.xml and cmp20 ant.html
docs
2) That's also done now. It's good to have spec fanatics watching me ;-)

Aslak
-----Original Message-----
From: middlegen-user-***@lists.sourceforge.net
[mailto:middlegen-user-***@lists.sourceforge.net]On Behalf Of Joao Miguel
Garcia
Sent: 20. juni 2002 15:45
To: middlegen-***@lists.sourceforge.net
Subject: [Middlegen-user] Why was get/setData() removed? and Relation
Fields


Guys,



1.



In the CVS update below, Aslak Hellesoy removed from the EJB template the
getData/setData functionality. Why was this needed? This breaks existing
code based on Data Object implementations, and I still cannot see a clear
reason for its removal. Was it replaced by an alternative functionality? Was
it a simple code drop? If so, how do you suggest an alternative solution?



http://sourceforge.net/mailarchive/message.php?msg_id=1696383



2.



Moreover, in the same update, the CMR relationship fields are set using
setID() operations in the ejbCreate methods. I believe that the correct
implementation would be setting the Relationship directly IN THE POSTCREATE
method, i.e. setCity (City c), instead of setting the ID’s. With the current
implementation, Weblogic seriously complains with spec violation errors.



Thanks in advance



Hugo José Pinto

***@hugopinto.com

Loading...