unknown
1970-01-01 00:00:00 UTC
Cheers,
Leander
Leander
I have had similar issues and solutions to the CMR problem generated by the VO's, but I still rather make that small change than throw-out the VO code in Middlegen - it IS a huge timesaver and a core part of the at least the projects I work on. I understand a lot of the devs are working/waiting/working on Middlegen3 based on the new framework(s), and not a lot of time has gone into the VO code since its original release, but I still appreciate what is there and just needs to be cleaned up a bit.
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
middlegen-user mailing list
https://lists.sourceforge.net/lists/listinfo/middlegen-user
-----Original Message-----
Sent: Tuesday, August 17, 2004 3:26 AM
Subject: Re: [Middlegen-user] CMR/CMP Problem
Hi Leslie,
had the same problem under JBOss. Basically the problem is in
the setVO
methods of the CMP classes generated by XDoclet where the CMR
fields of
the entity are modified which is not allowed when you are creating an
entity. You can always use the light value objects and set any FKs in
there to create an entity (works under JBoss).
I guess the ejbCreate(VO) methods should be removed from the
Middlegen
template all together since they'll never work as far as I can tell.
Leander
-------------------------------------------------------Sent: Tuesday, August 17, 2004 3:26 AM
Subject: Re: [Middlegen-user] CMR/CMP Problem
Hi Leslie,
had the same problem under JBOss. Basically the problem is in
the setVO
methods of the CMP classes generated by XDoclet where the CMR
fields of
the entity are modified which is not allowed when you are creating an
entity. You can always use the light value objects and set any FKs in
there to create an entity (works under JBoss).
I guess the ejbCreate(VO) methods should be removed from the
Middlegen
template all together since they'll never work as far as I can tell.
Leander
Hi,
I'm getting a CMR/CMP problem when I try to call create
with a VO instance.I'm getting a CMR/CMP problem when I try to call create
In the Middlegen generated ejbCreate method (which takes a
VO as a param)the generated code is calling a setter on a CMP field that
holds the FK.Inother words, instead of setting the relationship in the
ejbPostCreate via aLocal to the other bean, it's trying to set the (integer)
FK directly withsomething like setFoo(vo.getFoo()). This causes Weblogic
to complain atruntime.
If I set FKCMP="false" then I get compilation errors - the
same copy from VOIf I set FKCMP="false" then I get compilation errors - the
create code is generated and setters are being called but
of course, thesetter itself isnt generated.
If I comment out the setters everything works just fine.
So I guess this is a bug in Middlegen - it shouldn't be
generating VO fieldsIf I comment out the setters everything works just fine.
So I guess this is a bug in Middlegen - it shouldn't be
for CMR fields maybe?
Bye
Les
Bye
Les
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
middlegen-user mailing list
https://lists.sourceforge.net/lists/listinfo/middlegen-user