Re: failure to commit part of the changes

From: Bryan Lewis (jbryanlewi..mail.com)
Date: Mon Nov 02 2009 - 17:52:10 EST

  • Next message: Tobias Schoessler: "ConcurrentModificationExceptio on commit"

    Resending my last post. The list rejected it as spam, probably because I
    sent two posts in the same minute.

    Now that I've had a day to cogitate on it and to re-read CAY-1008, the issue
    > I addressed in my "model validation" code wasn't the important one. Having
    > redundant DbRelationships isn't risky; it's ony a cleanliness issue. Having
    > multiple ObjRelationships sharing the same DbRelationship is the case in the
    > Jira. I wrote a little more code today in EntityResolver to check for that:
    >
    > private void validateObjLayer()
    > {
    > for (DataMap map : getDataMaps()) {
    > for (ObjEntity entity : map.getObjEntities()) {
    > ArrayList dbpaths = new ArrayList<String>();
    > for (ObjRelationship rel : entity.getRelationships()) {
    > String dbpath = rel.getDbRelationshipPath();
    > if (dbpaths.contains(dbpath)) {
    > // Redundant ObjRelationships can lead to
    > misbehavior; see CAY-1008.
    > logger.warn("!! Found redundant ObjRelationship "
    > + entity.getName() + "."
    > + rel.getName()
    > + " sharing DbRel " + dbpath);
    > }
    > dbpaths.add(dbpath);
    > }
    > }
    > }
    > }
    >
    > So you might see in the log at start-up:
    >
    > !! Found redundant ObjRelationship Company.industry2 sharing DbRel
    > industry
    >
    >
    >



    This archive was generated by hypermail 2.0.0 : Mon Nov 02 2009 - 17:52:46 EST