Bogus FaultFailureExceptions
----------------------------

         Key: CAY-724
         URL: http://issues.apache.org/cayenne/browse/CAY-724
     Project: Cayenne
        Type: Bug

  Components: Cayenne Core Library  
    Versions: 3.0    
    Reporter: Andrus Adamchik
 Assigned to: Andrus Adamchik 
     Fix For: 3.0


Noticed FaultFailureExceptions happening randomly on resolving HOLLOW objects 
that are where initially instantiated via reading regular to-one relationships. 
Objects themselves have valid matching DB rows, still FaultFailureException is 
thrown. Further debugging showed that those objects had invalid partial 
snapshots in the DataRowStore that only contained PK and no other data, hence 
the object came out of the query intended to resolve it as HOLLOW. 

Now I am trying to determine how partial snapshots even get into the shared 
cache. This code from DataDomainQueryAction (line 212) looks suspicious ("else 
if" clause returns partial snapshot):


            if (targetRow != null) {
                resultRow = targetRow;
            }
            // if no inheritance involved, we can return a valid partial row 
made from
            // the target Id alone...
            else if (domain.getEntityResolver().lookupInheritanceTree(
                    (ObjEntity) relationship.getTargetEntity()) == null) {

                resultRow = new DataRow(targetId.getIdSnapshot());
            }
            else {
                // can't guess the right target...
                return !DONE;
            }

If this happens to be the case, it affects releases 1.2 - 3.0

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/cayenne/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira

Reply via email to