[ https://issues.apache.org/jira/browse/SLING-922?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12705544#action_12705544 ]
Bertrand Delacretaz commented on SLING-922: ------------------------------------------- > ...(3) The helper bundles are only provided as binaries.,,,I would probably > be more comfortable with the > source in SVN and creating the binaries during the test run (using the bnd > tool and ant script > for example). .. FWIW, I'm doing something like this in the installClonedBundle() method of the JcrinstallTestBase class [1]. The BundleCloner class uses bnd to create several copies of test bundles with different symbolic names. See also SLING-946, for some reason the bnd call currently fails on our Hudson build server. [1] http://svn.eu.apache.org/repos/asf/incubator/sling/trunk/contrib/launchpad/testing/src/test/java/org/apache/sling/launchpad/webapp/integrationtest/jcrinstall/JcrinstallTestBase.java > Load modules on startup from an external directory > -------------------------------------------------- > > Key: SLING-922 > URL: https://issues.apache.org/jira/browse/SLING-922 > Project: Sling > Issue Type: New Feature > Components: Launchpad, Launchpad Launcher > Reporter: Aaron Zeckoski > Assignee: Felix Meschberger > Attachments: binary-test-resources.zip, SLING-922.patch, > SLING922_fmeschbe.patch > > Original Estimate: 72h > Remaining Estimate: 72h > > Need a way to install and start bundles automatically from an external > directory (sling home) on startup. The ideas below are from the list. > ---------- > > I would like to be able to setup sling to start with a bunch of > > installed bundles when it first is started. It seems like there are a > > couple way to do this that I have found but neither is ideal: > > 1) Rebuild sling from source with the extra bundles in the launcher > > pom (this seems to create a bunch of resources/# folders with bundles > > in them) > > 2) Configure all bundles in the sling.properties file (this requires > > the bundles to be in an accessible obr) > > http://incubator.apache.org/sling/site/provisioning-and-startup.html > > > > I would like to ideally do something in between like so: > > Get a binary copy of the sling jar > > Create a folder with sub-folders like /1 /10 /15 > > Put my bundles in the various subfolders > > Configure sling.properties to point to the folder > > Start sling and have all bundles in the sub-folders installed and started > - Aaron Zeckoski > =============== > Currently, as you say in (1), the BootstrapInstaller of the Sling > launchpad looks into its own resources enclosed in the JAR or WAR file > for bundles to install on startup. > How about extending this mechanism like this: > - Copy all bundles from enclosed resources to > ${sling.home}/startup. This gives something like > ${sling.home}/startup/0, /1, /10, /15, ... > Existing files are only replaced if the files > enclosed in the Sling launchpad jar/war file are > newer. > - Scan ${sling.home}/startup for bundles to install > in the same way as today the enclosed resources > are scanned directly. > So you could place your bundles in that structure and get them installed > at the requested start level (0 being "default bundle start level"). > A nice side effect of this is, that you can quickly see, which bundles > have been installed at all. > - Felix > ================= > I like this, and agree that this should replace the current mechanism. > How about adding a sling.properties option to completely ignore the > bundles that come from the Sling jar/war file? Might make it easier to > have precise control on what's installed. > -Bertrand > ================= > Maybe worth it to make this optional or controllable via a property in the > sling properties. > - Aaron Zeckoski -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.