You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Felix Meschberger (JIRA)" <ji...@apache.org> on 2012/06/26 10:27:44 UTC

[jira] [Created] (SLING-2521) Allow disabling sling:alias support per configuration

Felix Meschberger created SLING-2521:
----------------------------------------

             Summary: Allow disabling sling:alias support per configuration
                 Key: SLING-2521
                 URL: https://issues.apache.org/jira/browse/SLING-2521
             Project: Sling
          Issue Type: New Feature
          Components: JCR
    Affects Versions: JCR Resource 2.1.0
            Reporter: Felix Meschberger


The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.

It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson resolved SLING-2521.
-----------------------------------

    Resolution: Fixed

Marking this one as resolved.
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>            Assignee: Justin Edelson
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Comment Edited] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13442694#comment-13442694 ] 

Justin Edelson edited comment on SLING-2521 at 8/28/12 7:31 AM:
----------------------------------------------------------------

Perf test results:
# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                        31      33      40      50      81
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                       230     242     254     275     472
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.1.0                       459     459     536     804     804

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                        41      43      52      77     132
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                       278     279     294     440     459
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0                       523     523     554    1127    1127

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      53
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      15
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      77
                
      was (Author: justinedelson):
    Perf test results:
<pre>
# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                        31      33      40      50      81
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                       230     242     254     275     472
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.1.0                       459     459     536     804     804

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                        41      43      52      77     132
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                       278     279     294     440     459
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0                       523     523     554    1127    1127

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      53
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      15
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      77
</pre>
                  
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13401250#comment-13401250 ] 

Felix Meschberger commented on SLING-2521:
------------------------------------------

> About a) see [0] 

Excellent. Thanks.
                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13443740#comment-13443740 ] 

Justin Edelson commented on SLING-2521:
---------------------------------------

duplicate case is handled with a warning
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>            Assignee: Justin Edelson
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Antonio Sanso (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13423855#comment-13423855 ] 

Antonio Sanso commented on SLING-2521:
--------------------------------------

Hi Carsten,

the test is an updated (due SLING-2255 et al ) version of [1].
So it basically tests node having 1000 children and resource not found.


[1] https://issues.apache.org/jira/secure/attachment/12520445/ResolveWithManyAliasTest.java
                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson updated SLING-2521:
----------------------------------

    Fix Version/s: Resource Resolver 1.0.0
    
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13423852#comment-13423852 ] 

Carsten Ziegeler commented on SLING-2521:
-----------------------------------------

Thanks Antonio, can you please explain how your test actually looks like/what it does? (how many aliases are created, which requests are executed etc.) Obviously we should 

                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (SLING-2521) Allow disabling sling:alias support per configuration

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

Antonio Sanso updated SLING-2521:
---------------------------------

    Attachment: disabling-alias-performance.png

I re-run the test as in [0] but with the latest code (namely with SLING-2255 et al). 
It doesn't show any performance gain for this particular matter compared to [0] 

# ResolveWithManyAliasTest               min     10%     50%     90%     max
jcr.resource-2.0.11                       58      62     124     283     877
with-alias-disabled    					   0       0       0       0      16

(see also attache graph).

Now, while the disabling might no be the right/final solution this tests shows that there is room for optimization (at least)
                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Antonio Sanso (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13414888#comment-13414888 ] 

Antonio Sanso commented on SLING-2521:
--------------------------------------

I can run a new test with SLING-2255 in place and latest code (included jackrabbit).
Obviously the win win would be to improve the alias resolving mechanism per se.
                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13443739#comment-13443739 ] 

Justin Edelson commented on SLING-2521:
---------------------------------------

committed this in r1378421 through r1378425. I meant to collapse these into a single revision, but I fat fingered the command.
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>            Assignee: Justin Edelson
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Antonio Sanso (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13401242#comment-13401242 ] 

Antonio Sanso commented on SLING-2521:
--------------------------------------

+1.

About a) see  [0]

[0] https://issues.apache.org/jira/browse/SLING-2311?focusedCommentId=13241320&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13241320
                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13442694#comment-13442694 ] 

Justin Edelson commented on SLING-2521:
---------------------------------------

Perf test results:

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                        31      33      40      50      81
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                       230     242     254     275     472
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.1.0                       459     459     536     804     804

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                        41      43      52      77     132
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                       278     279     294     440     459
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0                       523     523     554    1127    1127

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      53
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      15
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      77
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Comment Edited] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13442694#comment-13442694 ] 

Justin Edelson edited comment on SLING-2521 at 8/28/12 7:31 AM:
----------------------------------------------------------------

Perf test results:
<pre>
# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                        31      33      40      50      81
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                       230     242     254     275     472
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.1.0                       459     459     536     804     804

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                        41      43      52      77     132
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                       278     279     294     440     459
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0                       523     523     554    1127    1127

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      53
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      15
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      77
</pre>
                
      was (Author: justinedelson):
    Perf test results:

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                        31      33      40      50      81
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.1.0                       230     242     254     275     472
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.1.0                       459     459     536     804     804

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                        41      43      52      77     132
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0                       278     279     294     440     459
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0                       523     523     554    1127    1127

# ResolveWith1000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      53
# ResolveWith5000AliasTest               min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      15
# ResolveWith10000AliasTest              min     10%     50%     90%     max
jcr.resource-2.2.0 (patched)               0       0       0       0      77
                  
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Comment Edited] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13423852#comment-13423852 ] 

Carsten Ziegeler edited comment on SLING-2521 at 7/27/12 2:10 PM:
------------------------------------------------------------------

Thanks Antonio, can you please explain how your test actually looks like/what it does? (how many aliases are created, which requests are executed etc.)

                
      was (Author: cziegeler):
    Thanks Antonio, can you please explain how your test actually looks like/what it does? (how many aliases are created, which requests are executed etc.) Obviously we should 

                  
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Allow disabling sling:alias support per configuration

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13414876#comment-13414876 ] 

Carsten Ziegeler commented on SLING-2521:
-----------------------------------------

With SLING-2255 the performance win is less than outlined in [0], still disabling seems to improve the performance under heavy load.
However, I really would like to have new numbers based on latest code (and jackrabbit version)

I'm not in favour of a general switch, while this is the easiest to implement it is the most dangerous for users and as soon as you have a single alias, the whole improvement is pointless.

                
> Allow disabling sling:alias support per configuration
> -----------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13442656#comment-13442656 ] 

Justin Edelson commented on SLING-2521:
---------------------------------------

At least that's my understanding. I'm open to being told I am wrong :)
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson updated SLING-2521:
----------------------------------

    Attachment: SLING-2521.patch

This looks to be reasonably simple to fix - we just have to treat aliases like vanity paths, e.g. something where we store a cache of the values rather iterating through the node structure.

Proposed patch attached.

This is not 100% backwards compatible as the former behavior supported having multiple nodes with the same alias in the same path, e.g.

/content/foo
                  bar - sling:alias = test
                  baz - sling:alias = test

The resolved path for /content/foo/test would depend upon the node order of bar and baz. With this patch, the behavior would be non-deterministic (unless respectDocumentOrder was enabled in Jackrabbit).
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Assigned] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson reassigned SLING-2521:
-------------------------------------

    Assignee: Justin Edelson
    
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>            Assignee: Justin Edelson
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson updated SLING-2521:
----------------------------------

    Summary: Improve performance of sling:alias lookups and/or provide the ability to disable this feature  (was: Allow disabling sling:alias support per configuration)
    
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

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

Justin Edelson updated SLING-2521:
----------------------------------

    Attachment: SLING-2521-u1.patch

forgot about the case where sling:alias is set on the jcr:content child node. fixed the patch.
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Carsten Ziegeler (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13443006#comment-13443006 ] 

Carsten Ziegeler commented on SLING-2521:
-----------------------------------------

Wow, looks pretty good to me, I think we can live with the backwards compatibility problem. Can we issue a warning in the log in such cases?
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Justin Edelson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13442652#comment-13442652 ] 

Justin Edelson commented on SLING-2521:
---------------------------------------

Updated summary. The issue is not that this feature isn't desirable, but that the performance cost of it is too great.
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>         Attachments: disabling-alias-performance.png
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (SLING-2521) Improve performance of sling:alias lookups and/or provide the ability to disable this feature

Posted by "Felix Meschberger (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/SLING-2521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13443775#comment-13443775 ] 

Felix Meschberger commented on SLING-2521:
------------------------------------------

Thanks Justin for tackling. I am impressed.
                
> Improve performance of sling:alias lookups and/or provide the ability to disable this feature
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-2521
>                 URL: https://issues.apache.org/jira/browse/SLING-2521
>             Project: Sling
>          Issue Type: New Feature
>          Components: JCR
>    Affects Versions: JCR Resource 2.1.0
>            Reporter: Felix Meschberger
>            Assignee: Justin Edelson
>             Fix For: Resource Resolver 1.0.0
>
>         Attachments: disabling-alias-performance.png, SLING-2521.patch, SLING-2521-u1.patch
>
>
> The the JCR based ResourceResolver.resolve method currently support sling:alias properties on nodes to allow for resolution of translated URLs. This is potentially a very expensive operation particularly in the case of non existing resource.
> It should be analyzed whether (a) disabling sling:alias support has a measurable benefit on resource resolution (particularly when not finding a resource) and (b) whether it would be easy and simple to disable such support per configuration.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira