EJB 2.0 is almost done and finished. The best is to check it out from CVS (instructions on the developers website). Your testing and documenting is appreciated, it should be fairly stable already, the developers have been banging on it for quite a while.
You can also try MVCSoft's stuff it is pretty advanced
It says in the J2EE 1.3 tutorial:
... for other beans, the key's value is arbitrary--provided that it's unique. With container-managed persistence, these key values can be generated automatically by the EJB container. To take advantage of this feature, an entity bean must meet these requirements:
* In the deployment descriptor, the primary key class is defined as a java.lang.Object. The primary key field is not specified.
* In the home interface, the argument of the findByPrimaryKey method must be a java.lang.Object.
* In the entity bean class, the return type of the ejbCreate method must be a java.lang.Object.
In these entity beans, the primary key values are in an internal field that only the EJB container can access. You cannot associate the primary key with a persistent field or any other instance variable. However, you can fetch the bean's primary key by invoking the getPrimaryKey method, and you can locate the bean by invoking its findByPrimaryKey method.
This didn't seem to work in JBoss3. Did I do something wrong, or is it NYI?
NYI but Dain says soon.
Thanks. BTW, since you are looking for user testing, here is another one...
When trying a CMR accessor from a client, I get the following:
java.lang.reflect.UndeclaredThrowableException: java.io.NotSerializableException: org.jboss.ejb.plugins.cmp.jdbc.bridge.RelationSet
at org.jboss.invocation.jrmp.server.JRMPInvoker_Stub.invoke(Unknown Source)
at $Proxy5.getEvents(Unknown Source)
Surely this doesn't mean CMR fields can only be accessed through the local interface! Another NYI, or am I losing it?
While I am here, thanks and congratulations to all of the developers of JBoss. An excellent tool, no doubt dragging up the level of J2EE expertise throughout the Java community.
From section 10.3.2 of the spec:
"Container-managed relationships can exist only among entity beans within the same local relationship
scope, as defined by the relationships element in the deployment descriptor. Container-managed
relationships are defined in terms of the local interfaces of the related beans."
I wrote two entity beans and a client. one entity bean has a cmr field (one to many)
public abstract Collection getDestinationIPs();
that points to the other one with only two fields fk and ip
... and now i try to call the localbean1.getCollection() method to obtain the all the ips from bean2..... and i am using local interfaces between the beans ... but i have the same output here
08:43:40,836 ERROR [JRMPInvoker] operation failed
at java.lang.reflect.Method.invoke(Native Method)
at java.security.AccessController.doPrivileged(Native Method)
where is the prob???
Thanks for the quote from the spec, but does that mean that CMR fields can only be accessed from within the same JAR as the CMP EJBs? In other words, by other EJBs in the JAR?
It seems pretty silly if you have to package all the beans into the same JAR, and worse still if you cannot access CMR fields from clients (such as Web Server located JavaBeans) without an intervening Session Bean.
BTW, I see you are located in Sydney. I am from the US but flying tonight to Melbourne to work there for six months.