[
https://issues.apache.org/jira/browse/SLING-1473?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Carsten Ziegeler resolved SLING-1473.
-------------------------------------
Resolution: Fixed
Added a lazy resource implementation in revision 931058
> Resolve script resource lazy
> ----------------------------
>
> Key: SLING-1473
> URL: https://issues.apache.org/jira/browse/SLING-1473
> Project: Sling
> Issue Type: Improvement
> Components: Scripting
> Affects Versions: Scripting Core 2.0.10
> Reporter: Carsten Ziegeler
> Assignee: Carsten Ziegeler
> Fix For: Scripting Core 2.0.12
>
>
> The script implementations use the SlingScript.getScriptResource().getPath()
> as a unique key for the script. The script resource is resolved in the
> current user context. This results in unnecessary resolutions during script
> executions just to get the path of the script - especially with a jcr backed
> resource this is quiet expensive.
> Therefore we should rather use a lazy resource implementation which directly
> responds to getResourcePath() for getScriptResource(). Only if other methods
> of the Resource interface are used, the resource should be resolved.
> First test showed a hugh performance increase of a lot of scripts are used to
> render a single request.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.