You are right! And thanks for reviewing my commits :)

Indeed, buildFaultHandler is still creating the wrong type of IdentityDefiner. I thought that all dependencies on the various IdentityDefiner implementations were removed from OpenEJB thanks to the introduction of IdentityDefinerBuilder; obviously, two references have been forgotten :(

About createCMPFieldAccessors, the relatedEntity.getPrimaryKeyFields().size() test must also be replaced by an isCompoundPK test. However, it seems that we should add a special processing to handle a CMP field mapped to a FK column referencing the (single) PK column associated to a compound PK having a single field.

Thanks,
Gianny

Manu George wrote:

Hi Gianny,
                Was just seeing the fix you made. 1 question on that.
In CMPContainerBuilder there are 2 methods

private FaultHandler buildFaultHandler(SQLQueryBuilder queryBuilder, EJB definingEJB, CMRField field, int slot, boolean prefetch) throws QueryException
and
private LinkedHashMap createCMPFieldAccessors(SQLQueryBuilder queryBuilder, LinkedHashMap cmrFieldAccessor)

I feel that in both of these methods instead of comparing based on relatedEntity.getPrimaryKeyFields().size() we need to change to ejb.isCompoundPK(). Am I right?

Thanks
Manu




Reply via email to