Hi,
Defining a Primary Key class was a part of
EJB 1.1 specs. As the ejb-jar.xml file had a tag prim-key-class and the bean developer had to code the name of the Primary Key class here.
<prim-key-class>ejb.cmpejb.AccountPK</prim-key-class>
whereas in EJB 2.0 and 2.1, the same can be replaced with
<prim-key-class>java.lang.String</prim-key-class>
The primary key could be a sequence generator or any other modes of creating one and the same gets reflected as a automatic-key-generation tag
<automatic-key-generation>
<generator-type>ORACLE</generator-type>
<generator-name>oracle_sequence</generator-name>
<key-cache-size>10</key-cache-size>
</automatic-key-generation>
Seetesh