-
1. Re: CMR bug or misuse?
rfrey May 10, 2002 11:51 AM (in response to rfrey)A bit more floundering on my part indicates that CMR fields are *never* persisted with my configuration (Jboss3.0RC2, Mysql) if the CMR reference is obtained from within the bean itself. Going back to Michael's example, the test method
public abstract void setParent(CMRbugLocal cmrbug);
works like a champ, but when I overload the method:
public void setParent(String parentID) {
try {
  Context c = getInitialContext();
  CMRbugLocalHome clh = c.lookup("java:comp/env/ejb/CMRbugLocalHome");
  CMRbugLocal cl = clh.findByPrimaryKey(parentID);
  setParent(cl);
}
catch(Exception ignored){}
}
the CMR field is set for the scope of the setParent(String) method (i.e., I can call getParent and get expected values on the CMRbugLocal returned), but the field is not persisted in the database.
This seems somewhat crippling to me, as it precludes use of value objects for remote EJBs that have CMR references.
My hope is I'm overlooking something obvious!
Rod. -
2. Re: CMR bug or misuse?
scornflake Jul 31, 2002 12:57 PM (in response to rfrey)I have observed that exact behavior with the current 3.0.0 (to Oracle9i) release as well. Did you manage to find any solution to this?
Regards,
Neil Clayton -
3. Re: CMR bug or misuse?
dsundstrom Jul 31, 2002 8:15 PM (in response to rfrey)This is a bug in 3.0 that has been fixed, but I think the fix is not in 3.0.1rc1. I think you have to get 3.0 from cvs. There should be a 3.0.1 release soon (they are just waiting on some of my fixes).