You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Julian Reschke (JIRA)" <ji...@apache.org> on 2006/11/27 15:56:21 UTC

[jira] Created: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
-----------------------------------------------------------------------

                 Key: JCR-647
                 URL: http://issues.apache.org/jira/browse/JCR-647
             Project: Jackrabbit
          Issue Type: Bug
          Components: SPI
            Reporter: Julian Reschke
            Priority: Minor
         Attachments: JCR-647.diff.txt

JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.


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

        

[jira] Commented: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "Julian Reschke (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/JCR-647?page=comments#action_12454293 ] 
            
Julian Reschke commented on JCR-647:
------------------------------------

Good point.

One of my test cases looks at all registered node types, and then checks canRemoveItem() (and friends), As a matter of fact, more of these tests are failing under JCR2SPI, but I thought I start with the first and simple example for which I actually have a fix.

With respect to Jackrabbit core: maybe this isn't covered by any test case?



> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: http://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

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

        

[jira] Commented: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "angela (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/JCR-647?page=comments#action_12454017 ] 
            
angela commented on JCR-647:
----------------------------

the patch looks good to me.

however: the code originates from jackrabbit.core.nodetype.EffectiveNodeType.java and probably
stefan knows more details about the reasons for not respecting unnamed definitions in the mentioned check
method.

if  it the SPI code gets modified, i would suggest to also apply the same change to the mentioned
class in jackrabbit.core.

regards
angela

> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: http://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

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

        

[jira] Closed: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "Julian Reschke (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-647?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Julian Reschke closed JCR-647.
------------------------------

    Resolution: Won't Fix

canRemoveItem with residual properties is not meaningful; make sure JCR 2.0 says that the method should return true.


> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: https://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "Julian Reschke (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/JCR-647?page=comments#action_12454968 ] 
            
Julian Reschke commented on JCR-647:
------------------------------------

For the record:

- I agree with Angela's analysis, and

- I was wrong when I thought I say other related problems when the other checker methods; all of these were caused by my SPI implementation.


> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: http://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

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

        

[jira] Commented: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "angela (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/JCR-647?page=comments#action_12454370 ] 
            
angela commented on JCR-647:
----------------------------

i had a closer look at the reference implementation (core) and found, that  child item definitions combining residual and mandatory are not only ignored with the mentioned NodeType.canRemoveItem method but also during consistency checks upon Item.save().

regarding the patch:
if multiple residual definitions exist, canRemoveItem may still (having the patch applied) return a wrong result, since from the itemName we cannot determine, which definition belongs to the item of the given name... i'd say, this is a problem of the specification.

=> i added new issues to JSR283 asking for clarification.



> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: http://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

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

        

[jira] Updated: (JCR-647) NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)

Posted by "Julian Reschke (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/JCR-647?page=all ]

Julian Reschke updated JCR-647:
-------------------------------

    Attachment: JCR-647.diff.txt

Proposed patch.


> NodeType.canRemoveItem does not consider residual definitions (JCR2SPI)
> -----------------------------------------------------------------------
>
>                 Key: JCR-647
>                 URL: http://issues.apache.org/jira/browse/JCR-647
>             Project: Jackrabbit
>          Issue Type: Bug
>          Components: SPI
>            Reporter: Julian Reschke
>            Priority: Minor
>         Attachments: JCR-647.diff.txt
>
>
> JCR2SPI's NodeType.canRemoveItem() doesn't seem to work with residual definitions. This seems to be caused by EffectiveNodeTyoeImpl.checkRemoveItemConstraints not checking the unnamed definitions.

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