This is a sample project to showcase the use of DDRs in Sling. It requires a Sling 12 instance to be installed on.
These are the components of the Sample:
After the DDR Sample is installed the DDR Manager will discover that /conf/ddr-sample/settings/dynamic is a DDR source (by its primary type) and then read out the DDR target path. Then it will register that folder as DDR Source / Target pair with the DDR Provider. Whenever now a user requests a resource from that folder the DDR Provider will look it up and if:
After the installation open Sling in a browser and then go to composum browser. Here go to /apps/ddr-dynamic and you will find two child nodes button1 and text1. These resources are fully dynamic mean that they would go away if the DDR core is disabled. Try this by going to the System Console Bundles and stop the org.apache.sling.ddr.core bundle. Refreshing the /apps/ddr-dynamic folder in composum will not display any child resources. Restart the bundle now again and make sure the child resources are there again. Now we want to see these components but open the content on /ddr-sample/button.html. This will show Hello Button or Hello Text.
Andreas Schaefer: 3/27/2021