Apache Sling Scripting Reloaded
Following David's model, in Apache Sling, everything is a Resource. While this mechanism is very powerful in general, it does have its disadvantages when it comes to script deployment.
Firstly, scripts can be overlaid freely through the search path override or through the special sling:resourceSuperType property, complicating a developer's understanding of the script resolution mechanism.
Secondly, subsequent script deployments have the potential of completely changing the script resolution for a certain resource, by introducing backwards incompatible changes that can break script inheritance.
Lastly, scripts can be accessed by platform users with read permissions for the search paths, although scripts should have a developer-only audience.
In this talk, we will present a revised approach to scripting that preserves the current ease of deployment and content to script mapping. We will also introduce a prototype that implements script resolution based on OSGi requirements and capabilities, as well as the concept of versioned scripts with explicitly declared dependencies, finally bridging the gap between bundles and scripts.