Skip to content

InheritanceValueMap.getInherited(propPath, fallback) doesn't throw javax.jcr.ItemNotFoundException #10

@ItGumby

Description

@ItGumby

The jackalope implementation is throwing exceptions instead of returning the fallback value.

com.twcable.jackalope.impl.sling.SlingRepositoryException: javax.jcr.ItemNotFoundException
    at com.twcable.jackalope.impl.sling.ItemResourceImpl.getParent(ItemResourceImpl.java:78)
    at org.apache.sling.api.resource.ResourceUtil.getParent(ResourceUtil.java:215)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:124)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:152)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:152)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:152)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:152)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getParentPageValue(HierarchyNodeInheritanceValueMap.java:152)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getInherited(HierarchyNodeInheritanceValueMap.java:92)
    at com.day.cq.commons.inherit.HierarchyNodeInheritanceValueMap.getInherited(HierarchyNodeInheritanceValueMap.java:108)
    at com.twc.webcms.clusync.models.RelationshipItem.<init>(RelationshipItem.groovy:41)
    at com.twc.webcms.clusync.impl.RelationshipServiceImpl.getPageRelationships_closure5(RelationshipServiceImpl.groovy:219)
    at groovy.lang.Closure.call(Closure.java:423)
    at groovy.lang.Closure.call(Closure.java:439)
    at com.twc.webcms.clusync.impl.RelationshipServiceImpl.getPageRelationships(RelationshipServiceImpl.groovy:217)
    at com.twc.webcms.clusync.impl.RelationshipServiceImplSpec.should extract RelationshipItems from the relationship page(RelationshipServiceImplSpec.groovy:291)
Caused by: javax.jcr.ItemNotFoundException
    at com.twcable.jackalope.impl.jcr.ItemImpl.getParent(ItemImpl.java:93)
    at com.twcable.jackalope.impl.sling.ItemResourceImpl.getParent(ItemResourceImpl.java:75)
    ... 15 more

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions