Return-Path: Delivered-To: apmail-incubator-sling-commits-archive@locus.apache.org Received: (qmail 72205 invoked from network); 13 Jan 2009 12:07:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 13 Jan 2009 12:07:21 -0000 Received: (qmail 89224 invoked by uid 500); 13 Jan 2009 12:07:21 -0000 Delivered-To: apmail-incubator-sling-commits-archive@incubator.apache.org Received: (qmail 89188 invoked by uid 500); 13 Jan 2009 12:07:20 -0000 Mailing-List: contact sling-commits-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: sling-dev@incubator.apache.org Delivered-To: mailing list sling-commits@incubator.apache.org Received: (qmail 89179 invoked by uid 99); 13 Jan 2009 12:07:20 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Jan 2009 04:07:20 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Jan 2009 12:07:11 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id B72A3238895D; Tue, 13 Jan 2009 04:06:50 -0800 (PST) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r734113 [1/6] - in /incubator/sling/whiteboard/fmeschbe/launchpad: ./ app/ app/src/ app/src/main/ app/src/main/assembly/ app/src/main/dist/ app/src/main/dist/bin/ app/src/main/dist/dos/ app/src/main/dist/unix/ app/src/main/java/ app/src/mai... Date: Tue, 13 Jan 2009 12:06:20 -0000 To: sling-commits@incubator.apache.org From: fmeschbe@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20090113120650.B72A3238895D@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: fmeschbe Date: Tue Jan 13 04:04:51 2009 New Revision: 734113 URL: http://svn.apache.org/viewvc?rev=734113&view=rev Log: Prototype for restartable Sling Added: incubator/sling/whiteboard/fmeschbe/launchpad/ incubator/sling/whiteboard/fmeschbe/launchpad/app/ (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/app/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.ico (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.jpg (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.png (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/apache/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/apache/sling/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/apache/sling/launchpad/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/apache/sling/launchpad/app/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/java/org/apache/sling/launchpad/app/Main.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/resources/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/resources/META-INF/ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/resources/META-INF/DISCLAIMER incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/resources/META-INF/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/resources/META-INF/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/base/ (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/base/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/base/README.txt (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/pom.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/BootstrapInstaller.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/ClassLoaderResourceProvider.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/ContextConnection.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/ContextProtocolHandler.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/DeploymentPackageInstaller.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/ResourceProvider.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/Sling.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launcher/app/SlingFelix.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/main/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/main/SlingMain.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/shared/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/shared/Launcher.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/shared/Loader.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/shared/Notifiable.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/webapp/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/webapp/SlingBridge.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/java/org/apache/sling/launchpad/base/webapp/SlingServlet.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/META-INF/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/META-INF/DISCLAIMER incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/META-INF/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/META-INF/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/WEB-INF/ incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/WEB-INF/jcr-client.properties (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/jre-1.5.properties (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/jre-1.6.properties (with props) incubator/sling/whiteboard/fmeschbe/launchpad/base/src/main/resources/sling.properties (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/ (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/webapp/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/webapp/README.txt (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/pom.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/assembly/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/assembly/bin.xml (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/apache/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/apache/sling/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/apache/sling/launchpad/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/apache/sling/launchpad/webapp/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/java/org/apache/sling/launchpad/webapp/SlingServlet.java (with props) incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/WEB-INF/ incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/WEB-INF/DISCLAIMER incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/WEB-INF/LICENSE incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/WEB-INF/NOTICE incubator/sling/whiteboard/fmeschbe/launchpad/webapp/src/main/webapp/WEB-INF/web.xml (with props) Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/ ------------------------------------------------------------------------------ --- svn:ignore (added) +++ svn:ignore Tue Jan 13 04:04:51 2009 @@ -0,0 +1,5 @@ +.project +.classpath +.settings +target +sling Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/LICENSE URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/LICENSE?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/LICENSE (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/LICENSE Tue Jan 13 04:04:51 2009 @@ -0,0 +1,202 @@ + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/NOTICE URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/NOTICE?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/NOTICE (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/NOTICE Tue Jan 13 04:04:51 2009 @@ -0,0 +1,8 @@ +Apache Sling Launchpad App +Copyright 2008-2009 The Apache Software Foundation + +Apache Sling is based on source code originally developed +by Day Software (http://www.day.com/). + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt Tue Jan 13 04:04:51 2009 @@ -0,0 +1,57 @@ +Apache Sling Launchpad App + +Standalone Launchpad Java Application. Everything needed to run +the Launchpad is included in a single JAR file. + +Disclaimer +========== +Apache Sling is an effort undergoing incubation at The Apache Software Foundation (ASF), +sponsored by the Apache Jackrabbit PMC. Incubation is required of all newly accepted +projects until a further review indicates that the infrastructure, communications, +and decision making process have stabilized in a manner consistent with other +successful ASF projects. While incubation status is not necessarily a reflection of +the completeness or stability of the code, it does indicate that the project has yet +to be fully endorsed by the ASF. + +Getting Started +=============== + +This component uses a Maven 2 (http://maven.apache.org/) build +environment. It requires a Java 5 JDK (or higher) and Maven (http://maven.apache.org/) +2.0.7 or later. We recommend to use the latest Maven version. + +If you have Maven 2 installed, you can compile and +package the jar using the following command: + + mvn package + +See the Maven 2 documentation for other build features. + +The latest source code for this component is available in the +Subversion (http://subversion.tigris.org/) source repository of +the Apache Software Foundation. If you have Subversion installed, +you can checkout the latest source using the following command: + + svn checkout http://svn.apache.org/repos/asf/incubator/sling/trunk/launchpad/app + +See the Subversion documentation for other source control features. + + +How to run the Sling launcher/app module +---------------------------------------- + +1) Build Sling using + + mvn clean install + +in the top-level directory of the Sling source code. + +2) Come back to this directory and build using + + mvn -P full clean install + +3) Start the generated jar with + + java -jar target/org.apache.sling.launcher.app-2.0.0-incubator-SNAPSHOT-full.jar + +Use the correct version number instead of 2.0.0-incubator-SNAPSHOT, if needed. \ No newline at end of file Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/README.txt ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml Tue Jan 13 04:04:51 2009 @@ -0,0 +1,66 @@ + + + assembly + + zip + tar.gz + tar.bz2 + + true + sling-${version} + + + + src/main/dist/unix + / + unix + 0744 + + serverctl + + + + src/main/dist/bin + / + + + target + bin + + *.jar + + + + + + src/main/dist/unix/serverctl + / + unix + 0744 + true + + + src/main/dist/dos/server.bat + / + dos + true + + + Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/assembly.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml Tue Jan 13 04:04:51 2009 @@ -0,0 +1,621 @@ + + + + + 4.0.0 + + org.apache.sling + sling + 5-incubator-SNAPSHOT + ../../parent/pom.xml + + + org.apache.sling.launchpad.app + jar + 5-incubator-SNAPSHOT + + Sling - Launchpad Application + + Standalone Launchpad Java Application. Everything needed to run + the Launchpad is included in a single JAR file. + + + + + scm:svn:http://svn.apache.org/repos/asf/incubator/sling/trunk/launchpad/app + + + scm:svn:https://svn.apache.org/repos/asf/incubator/sling/trunk/launchpad/app + + + http://svn.apache.org/viewvc/incubator/sling/trunk/launchpad/app + + + + + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.0 + + + inline-launchpad-base + + unpack-dependencies + + + + org.apache.sling.launchpad.base + + true + + ${project.build.outputDirectory} + + + + + + + org.apache.maven.plugins + maven-jar-plugin + + + + + org.apache.sling.launchpad.app.Main + + + true + + + + + + + maven-assembly-plugin + + + + src/main/assembly/bin.xml + + + + + + + + + + org.apache.maven.plugins + maven-javadoc-plugin + + + + org.apache.sling + + + + + + + + + org.apache.sling + org.apache.sling.launchpad.base + 2.0.3-incubator-SNAPSHOT + shared + provided + + + + + org.apache.sling + org.apache.sling.commons.log + 2.0.3-incubator-SNAPSHOT + provided + + + + + org.ops4j.pax.web + pax-web-service + 0.2.3 + provided + + + org.apache.felix + org.apache.felix.webconsole + 1.2.3-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.commons.json + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.felix + org.apache.felix.bundlerepository + 1.2.1 + provided + + + org.apache.sling + org.apache.sling.extensions.threaddump + 0.1.0-incubator-SNAPSHOT + provided + + + + + org.apache.felix + org.apache.felix.eventadmin + 1.0.0 + provided + + + org.apache.felix + org.apache.felix.scr + 1.0.6 + provided + + + org.apache.felix + org.apache.felix.configadmin + 1.0.4 + provided + + + org.apache.felix + org.apache.felix.metatype + 1.0.2 + provided + + + + + org.apache.sling + org.apache.sling.jcr.api + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.jcr.base + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.jackrabbit + jackrabbit-api + 1.5.0 + provided + + + org.apache.sling + org.apache.sling.jcr.jackrabbit.server + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.jackrabbit + jackrabbit-jcr-commons + 1.5.0 + provided + + + org.apache.sling + org.apache.sling.jcr.webdav + 2.0.3-incubator-SNAPSHOT + provided + + + + commons-io + commons-io + 1.4 + provided + + + commons-collections + commons-collections + 3.2.1 + provided + + + org.apache.sling + org.apache.sling.commons.osgi + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.commons.mime + 2.0.3-incubator-SNAPSHOT + provided + + + + + org.apache.sling + org.apache.sling.api + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.engine + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.httpauth + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.adapter + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.servlets.resolver + 2.0.5-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.servlets.get + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.servlets.post + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.samples.path-based.rtp + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.jcr.contentloader + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.jcr.resource + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.jcr.ocm + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.jcr.classloader + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.bundleresource.impl + 2.0.3-incubator-SNAPSHOT + provided + + + + + org.apache.sling + org.apache.sling.launchpad.content + 2.0.2-incubator + provided + + + + + org.apache.sling + org.apache.sling.scripting.api + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.scripting.core + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.scripting.javascript + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.scripting.jsp + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.scripting.jsp.taglib + 2.0.3-incubator-SNAPSHOT + provided + + + org.apache.sling + org.apache.sling.extensions.apt.servlet + 2.0.2-incubator + provided + + + org.apache.sling + org.apache.sling.extensions.apt.parser + 2.0.2-incubator + provided + + + + + + withBundles + + false + + + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.0 + + + + + copy-level-1-bundles + + copy-dependencies + + + + org.apache.sling.commons.log + + true + + ${project.build.outputDirectory}/resources/1 + + + + + + + copy-level-5-bundles + + copy-dependencies + + + + pax-web-service,org.apache.felix.webconsole,org.apache.felix.bundlerepository,org.apache.sling.extensions.threaddump + + true + + ${project.build.outputDirectory}/resources/5 + + + + + + + copy-level-10-bundles + + copy-dependencies + + + + org.apache.felix.eventadmin,org.apache.felix.scr,org.apache.felix.configadmin,org.apache.felix.metatype + + true + + ${project.build.outputDirectory}/resources/10 + + + + + + + copy-level-15-bundles + + copy-dependencies + + + + org.apache.sling.jcr.api,org.apache.sling.jcr.base,jackrabbit-api,org.apache.sling.jcr.jackrabbit.server,jackrabbit-jcr-commons,commons-io,commons-collections,org.apache.sling.commons.osgi,org.apache.sling.commons.mime,org.apache.sling.jcr.webdav + + + true + + ${project.build.outputDirectory}/resources/15 + + + + + + + copy-remaining-bundles + + copy-dependencies + + + + org.apache.sling.api,org.apache.sling.engine,org.apache.sling.httpauth,org.apache.sling.adapter,org.apache.sling.servlets.resolver,org.apache.sling.servlets.get,org.apache.sling.servlets.post,org.apache.sling.samples.path-based.rtp,org.apache.sling.commons.json,org.apache.sling.jcr.contentloader,org.apache.sling.jcr.resource,org.apache.sling.jcr.ocm,org.apache.sling.jcr.classloader,org.apache.sling.bundleresource.impl,org.apache.sling.launchpad.content,org.apache.sling.scripting.api,org.apache.sling.scripting.core,org.apache.sling.scripting.javascript,org.apache.sling.scripting.jsp,org.apache.sling.scripting.jsp.taglib,org.apache.sling.extensions.apt.servlet,org.apache.sling.extensions.apt.parser + + true + + ${project.build.outputDirectory}/resources/0 + + + + + + + + + + + + withBase + + false + + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.0 + + + copy-launcher-jar + + copy + + + + + org.apache.sling + org.apache.sling.launchpad.base + 2.0.3-incubator-SNAPSHOT + + + true + + ${project.build.outputDirectory}/resources + + + + + + + + + + + dist + + + + maven-assembly-plugin + 2.2-beta-1 + + + assemble-distribution + + + + assembly.xml + + + + false + + + package + + attached + + + + + + + + + withShell + + + + org.apache.maven.plugins + maven-dependency-plugin + 2.0 + + + copy-shell-bundles + + copy + + + + + org.apache.felix + org.apache.felix.shell + 1.0.2 + + + org.apache.felix + org.apache.felix.shell.remote + 1.0.2 + + + true + + ${project.build.outputDirectory}/resources/1 + + + + + + + + + + + + + OPS4J + OPS4J Repository + http://repository.ops4j.org/maven2 + + true + + + false + + + + + Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/pom.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml Tue Jan 13 04:04:51 2009 @@ -0,0 +1,50 @@ + + + + bin + + tar.gz + zip + + + + + README* + + + + src/main/resources/META-INF + + + LICENSE* + NOTICE* + DISCLAIMER + + + + target + + + *.jar + *.war + + + + \ No newline at end of file Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/assembly/bin.xml ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.ico URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.ico?rev=734113&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.ico ------------------------------------------------------------------------------ svn:mime-type = image/x-icon Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.jpg URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.jpg?rev=734113&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.jpg ------------------------------------------------------------------------------ svn:mime-type = image/jpeg Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.png URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.png?rev=734113&view=auto ============================================================================== Binary file - no diff available. Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/bin/sling.png ------------------------------------------------------------------------------ svn:mime-type = image/png Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat Tue Jan 13 04:04:51 2009 @@ -0,0 +1,196 @@ +:: +:: Licensed to the Apache Software Foundation (ASF) under one +:: or more contributor license agreements. See the NOTICE file +:: distributed with this work for additional information +:: regarding copyright ownership. The ASF licenses this file +:: to you under the Apache License, Version 2.0 (the +:: "License"); you may not use this file except in compliance +:: with the License. You may obtain a copy of the License at +:: +:: http://www.apache.org/licenses/LICENSE-2.0 +:: +:: Unless required by applicable law or agreed to in writing, +:: software distributed under the License is distributed on an +:: "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +:: KIND, either express or implied. See the License for the +:: specific language governing permissions and limitations +:: under the License. + +@echo off +setlocal + +::----------------------------------------------------------------------------- +:: HTTP Service Arguments +::----------------------------------------------------------------------------- + +::* Default Port +:: + set SLING_PORT=8080 + +::* Default Bind Address +:: + set SLING_ADDR=0.0.0.0 + +::----------------------------------------------------------------------------- +:: General JVM Arguments +::----------------------------------------------------------------------------- + +::* Uncomment one of the JVM_TYPE if you wish a different than '-hotspot' +:: +:: set JVM_TYPE=-classic +:: set JVM_TYPE=-server + +::* Memory settings +:: + set JVM_MINHEAP=-Xms64m + set JVM_MAXHEAP=-Xmx256m + +::* Uncomment, or redefine one of the follwoing JAVA_HOME if you wish a +:: different than your default one +:: +:: set JAVA_HOME=c:\java\jdk1.4.2_08 + +::* 'Exectuable' +:: + set JVM_START=-jar bin/${project.build.finalName}.jar + +::* Additional JVM Options +:: +:: set JVM_OPTS=-Djava.security.auth.login.config=etc/jaas.config + +::* Debug Port (only if started with -debug socket) +:: + set JVM_DEBUG_PORT=30303 + +::* Default Debug Options +:: + set JVM_DEBUG_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE + + +::----------------------------------------------------------------------------- +:: should not change below here +::----------------------------------------------------------------------------- + +:: change drive and directory +%~d0 +cd %~p0 + +:: set window title +set PROGRAM_TITLE=Apache Sling + +:: parse arguments +:while1 + if "%1"=="-debug" ( + set JVM_DEBUG=%JVM_DEBUG_OPTS% + set JVM_DEBUG_TRANSPORT=dt_socket + set JVM_DEBUG_SUSPENDED=n + set JVM_DEBUG_ADR=%JVM_DEBUG_PORT% + goto next1 + ) + + if "%1"=="-suspended" ( + set JVM_DEBUG_SUSPENDED=y + goto next1 + ) + + if "%1"=="-quiet" ( + set NO_INFOMSG=y + goto next1 + ) + + if "%1"=="-jconsole" ( + set JVM_JCONSOLE=-Dcom.sun.management.jmxremote + set NO_INFOMSG=y + goto next1 + ) + + if "%1"=="-level" ( + set SLING_LEVEL=%2 + shift /1 + goto next1 + ) + + if "%1"=="-help" ( + goto usage + ) + + if "%1" NEQ "" ( + echo invalid argument %1 + goto usage + ) + +:next1 + shift /1 + if "%1" NEQ "" goto while1 + + +:: assemble jvm options +set JVM_ADDOPTS=%JVM_OPTS% +set JVM_OPTS=%JVM_MINHEAP% %JVM_MAXHEAP% +if defined JVM_JCONSOLE set JVM_OPTS=%JVM_JCONSOLE% %JVM_OPTS% +if defined JVM_TYPE set JVM_OPTS=%JVM_TYPE% %JVM_OPTS% +if defined JVM_ADDOPTS set JVM_OPTS=%JVM_OPTS% %JVM_ADDOPTS% + +:: check for JVM +set JAVA="%JAVA_HOME%\bin\java.exe" +if not exist %JAVA% ( + echo No JVM found at %JAVA% + goto exit +) + +:: check for debug +if defined JVM_DEBUG ( + set JVM_OPTS=%JVM_OPTS% %JVM_DEBUG% -Xrunjdwp:transport=%JVM_DEBUG_TRANSPORT%,server=y,suspend=%JVM_DEBUG_SUSPENDED%,address=%JVM_DEBUG_ADR% +) + +:: assemble program arguments +if defined SLING_PORT set SLING_ARGS=%SLING_ARGS% -p %SLING_PORT% +if defined SLING_ADDR set SLING_ARGS=%SLING_ARGS% -a %SLING_ADDR% +if defined SLING_LEVEL set SLING_ARGS=%SLING_ARGS% -l %SLING_LEVEL% + +:: ensure logging to stdout +set SLING_ARGS=%SLING_ARGS% -f - + +:: print info message +if defined NO_INFOMSG goto startcq + +echo ------------------------------------------------------------------------------- +echo Starting %PROGRAM_TITLE% +echo ------------------------------------------------------------------------------- +call %JAVA% %JVM_TYPE% -version +echo ------------------------------------------------------------------------------- +if "%JVM_DEBUG_TRANSPORT%"=="dt_socket" ( + echo debugging: Socket (%JVM_DEBUG_PORT%^) + if "%JVM_DEBUG_SUSPENDED%"=="y" echo starting jvm suspended^! + echo ------------------------------------------------------------------------------- +) +echo %JAVA% %JAVA_VM_TYPE% %JVM_OPTS% %JVM_START% %SLING_ARGS% +echo ------------------------------------------------------------------------------- + + +:startcq + +title %PROGRAM_TITLE% +%JAVA% %JAVA_VM_TYPE% %JVM_OPTS% %JVM_START% %SLING_ARGS% +goto exit + + +::----------------------------------------------------------------------------- +:usage + +echo %PROGRAM_TITLE% +echo usage: %0 [options] +echo. +echo where options include: +echo -debug enable debug +echo -suspended start suspended (only if debug) +echo -quiet don't show info message +echo -jconsole start with -Dcom.sun.management.jmxremote +echo -level [ level ] set initial log level (DEBUG, INFO, ...) +echo -help this usage +echo. +echo for additional tuning, edit the first section of the %0 file + +::----------------------------------------------------------------------------- +:exit +endlocal Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/dos/server.bat ------------------------------------------------------------------------------ svn:eol-style = native Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl Tue Jan 13 04:04:51 2009 @@ -0,0 +1,574 @@ +#!/bin/sh +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# + +# define a special java home +#JAVA_HOME=/opt/java/jdk1.6.0 + +# enable this as default command if no command argument is given +#SLING_COMMAND=start + +# define the port sling listens to. +#SLING_PORT=8080 + +# define the interface sling binds to. +#SLING_INTERFACE=0.0.0.0 + +# enable if jvm-debugging should be enabled +#SLING_JVM_DEBUG=socket + +# set the max amount of java heap space +#SLING_JVM_HEAP_MAX=512 + +# add additional options to the jvm +#SLING_JVM_OPTS=-enableassertions + +# enable starting the engine in foreground +#SLING_FOREGROUND=y + +#--------------------------------------------------------------------- +# Don't edit below here +#--------------------------------------------------------------------- + +#--------------------------------------------------------------------- +# functions +#--------------------------------------------------------------------- + +# print the usage info +usage() { +cat <<-@@ +$SLING_TITLE Control, version 2.0.0 ($SLING_SVN_ID) + usage: `basename $0` [options] {start|stop|restart|status} + +Engine Options: + --context the sling context directory, defaults to `dirname $0` + --port, -p the default port to listen to + --loglevel, -l the initial loglevel. + --logdir the log directory for startup.log. defaults to `dirname $0`/logs + --log the startup log file. defaults to `dirname $0`/logs/startup.log + --interface, -a the interfact to bind to (use 0.0.0.0 for any). + +Java Options: + --javahome the java home directory. overrides JAVA_HOME env var. + --heap-min the minimum heap in megabytes. defaults to 128 + --heap-max the maximum heap in megabytes. defaults to 256 + --debug, -d [socket|shmem] + starts jvm in debug mode. default 'socket' + --debug-suspended [socket|shmem] + starts jvm in suspended debug mode. default 'socket' + --debug-port port for debug address. default "30303" + --profile [yjp] start jvm with YourKit Java Profiler + --javaopts additional java options + --jaas use jaas.config. default is disabled + --jaas-config config for jaas. default is etc/jaas.config + --verbose-gc turn on vebose gc + +Other options + --fg, -D starts Sling in foreground + --bg starts Sling in background. this is the default. + --verbose, -v be more verbose + --dry prepare but do not start + --help, -h show this help + --max-files sets the ulimit for max open files before executing the jvm. + default is 1024 +@@ +} + +# init the defaults +initDefaults() { + BASEDIR=`fullpath -d $0` + SLING_TITLE="Sling" + export SLING_TITLE + SLING_SVN_ID='$Rev: 25335 $' + export SLING_SVN_ID + SLING_CONTEXT="${SLING_CONTEXT:-$BASEDIR}" + export SLING_CONTEXT + export SLING_PORT + export SLING_LOGLEVEL + SLING_LOGDIR="${SLING_LOGDIR:-"$BASEDIR/logs"}" + export SLING_LOGDIR + SLING_LOG="${SLING_LOG:-"$SLING_LOGDIR/startup.log"}" + export SLING_LOG + SLING_INTERFACE="${SLING_INTERFACE:-$SLING_ADDRESS}" + export SLING_INTERFACE + SLING_JVM_HEAP_MIN="${SLING_HEAP_MIN:-"128"}" + export SLING_JVM_HEAP_MIN + SLING_JVM_HEAP_MAX="${SLING_HEAP_MAX:-"256"}" + export SLING_JVM_HEAP_MAX + export SLING_JVM_JAAS + SLING_JVM_JAAS_CONFIG=etc/jaas.config + export SLING_JVM_JAAS_CONFIG + export SLING_JVM_OPTS + export SLING_JVM_VERBOSE_GC + export SLING_JVM_DEBUG + SLING_JVM_DEBUG_PORT=30303 + export SLING_JVM_DEBUG_PORT + SLING_JVM_DEBUG_SUSPENDED=n + export SLING_JVM_DEBUG_SUSPENDED + export SLING_JVM_PROFILE + export SLING_FOREGROUND + export SLING_DRY + SLING_COMMAND=${SLING_COMMAND} + export SLING_COMMAND + export SLING_VERBOSE + SLING_MAX_OPEN_FILES="${SLING_MAX_OPEN_FILES:-"1024"}" + export SLING_MAX_OPEN_FILES +} + +# echo to stderr and to the log file +_log() { + _level=$1; shift + if [ "$use_stderr" = "YES" ] ; then + echo "`date '+%d.%m.%Y %H:%M:%S'` *$_level* $*" >&2 + fi + if [ -w "$SLING_LOG" ]; then + echo "`date '+%d.%m.%Y %H:%M:%S'` *$_level* $*" >> "$SLING_LOG" + fi +} + +# log an error message +err() { + _log "ERROR" $* +} + +# log an warning message +warn() { + _log "WARN " $* +} + +# log an info message +info() { + _log "INFO " $* +} + +# print all relevant variables +dump() { + set | grep SLING +} + +# calculate the fullpath +fullpath() { + OPWD="$PWD" + if [ "$1" = "-d" ]; then + cd `dirname $2` + echo `pwd -L` + else + cd `dirname $1` + echo `pwd -L`/`basename $1` + fi + cd $OPWD +} + +# check if verbose level +verbose() { + test -n "$SLING_VERBOSE" +} + +# print the java version of the $SLING_JVM vm +javaVersion() { + jvm_version=`$SLING_JVM -version 2>&1 | grep "java version"` + case "$jvm_version" in + "java version \"1.2"*) echo 1.2;; + "java version \"1.3"*) echo 1.3;; + "java version \"1.4"*) echo 1.4;; + "java version \"1.5"*) echo 1.5;; + "java version \"1.6"*) echo 1.6;; + *) echo ;; + esac +} + +# print the debug info +printDebug() { + if [ "$SLING_JVM_DEBUG" = "socket" ]; then + info "attaching debugger on port ${SLING_JVM_DEBUG_PORT}" + if [ "${SLING_JVM_DEBUG_SUSPENDED}" = y ]; then + info "jvm is suspended! attach debugger to continue." + fi + fi + if [ "$SLING_JVM_DEBUG" = "shmem" ]; then + info "attaching debugger using shared memory" + if [ "${SLING_JVM_DEBUG_SUSPENDED}" = y ]; then + info "jvm is suspended! attach debugger to continue." + fi + fi +} + +#--------------------------------------------------------------------- +# main program begins here +#--------------------------------------------------------------------- + +# parse the arguments +initDefaults +while [ -n "$1" ]; do + case "$1" in + '--context') + SLING_CONTEXT=$2 + shift;; + '--port' | '-p') + SLING_PORT=$2 + shift;; + '--loglevel' | '-l') + SLING_LOGLEVEL=$2 + shift;; + '--logdir') + SLING_LOGDIR=$2 + shift;; + '--log') + SLING_LOG=$2 + shift;; + '--interface' | '-a') + SLING_INTERFACE=$2 + shift;; + '--javahome') + JAVA_HOME=$2 + shift;; + '--javaopts') + SLING_JVM_OPTS=$2 + shift;; + '--heap-min') + SLING_JVM_HEAP_MIN=$2 + shift;; + '--heap-max') + SLING_JVM_HEAP_MAX=$2 + shift;; + '--debug' | '-d' | '--debug-suspended') + SLING_JVM_DEBUG=socket + if [ "$1" == "--debug-suspended" ]; then + SLING_JVM_DEBUG_SUSPENDED=y + fi + if [ "$2" == "socket" -o "$2" == "shmem" ]; then + SLING_JVM_DEBUG=$2 + shift + fi;; + '--profile') + SLING_JVM_PROFILE=yjp + if [ "$2" = "yjp" ]; then + SLING_JVM_PROFILE=$2 + shift + fi;; + '--debug-port') + SLING_JVM_DEBUG_PORT=$2 + shift;; + '--debug-suspended') + SLING_JVM_DEBUG_SUSPENDED=y + ;; + '--jaas') + SLING_JVM_JAAS=y + ;; + '--jaas-config') + SLING_JVM_JAAS_CONFIG=$2 + shift;; + '--verbose-gc') + SLING_JVM_VERBOSE_GC=y + ;; + '--fg' | '-D') + SLING_FOREGROUND=y + ;; + '--bg') + SLING_FOREGROUND=n + ;; + '--verbose' | '-v') + SLING_VERBOSE=y + ;; + '--max-files') + SLING_MAX_OPEN_FILES=$2 + shift;; + '--dry') + SLING_DRY=y + ;; + '--help' | '-h') + usage + exit ;; + 'status'|'start'|'psmon'|'terminator'|'bgstart'|'stop'|'restart') + SLING_COMMAND=$1 + ;; + *) + echo "Invalid option: $1" + usage + exit;; + esac + shift +done + +#-------------------------------------------------------------------------------- +if [ ! -d "$SLING_CONTEXT" ] ; then + mkdir -p "$SLING_CONTEXT" +fi +if [ ! -f "$SLING_CONTEXT/bin/${project.build.finalName}.jar" ] ; then + echo "Bad SLING_CONTEXT: $SLING_CONTEXT (bin/${project.build.finalName}.jar not found)" >&2 + exit 4 +fi +cd "$SLING_CONTEXT" + +case "$SLING_COMMAND" in + 'start') # test to be sure we can run, then bg + # the startup + use_stderr="YES" + + + if [ ! -d "$SLING_LOGDIR" ] ; then + mkdir -p "$SLING_LOGDIR" 2>/dev/null || \ + ( echo "mkdir failed for $SLING_LOGDIR" >&2 ; exit 2 ) + fi + for file in "$SLING_LOG" "$SLING_LOGDIR/sling.pid" "$SLING_LOGDIR/monitor.pid" ; do + if [ ! -w "$file" ] ; then + touch "$file" 2>/dev/null || \ + ( "Couldn't create file $file" >&2 ; exit 2 ) + fi + done + + if [ -n "$JAVA_HOME" -a -x "$JAVA_HOME/bin/java" ] ; then + SLING_JVM=$JAVA_HOME/bin/java + else + JAVA_HOME= + SLING_JVM="`which java 2>/dev/null`" + if [ -z "$SLING_JVM" ] ; then + for pfix in "/usr/local" "/opt" "/usr" ; do + for jvers in "java" "j2sdk" "j2sdk1.4" "java1.4" \ + "j2sdk1.3.1" "java1.3.1" "j2sdk1.3" "java1.3" ; do + if [ -x "$pfix/$jvers/bin/java" ] ; then + SLING_JVM="$pfix/$jvers/bin/java" + break 2 + fi + done + done + if [ -z "$SLING_JVM" ] ; then + err "Unable to locate java, please make sure java is installed and JAVA_HOME set" + exit 3 + fi + fi + fi + + # check if already running + SLING_PID=`cat "$SLING_LOGDIR/sling.pid" 2> /dev/null` + if [ -n "$SLING_PID" ]; then + if ps -p $SLING_PID > /dev/null; then + err "process $SLING_PID already running. please stop and try again." + exit 4 + else + warn "pid file $SLING_LOGDIR/sling.pid present, but process not running. "\ + "maybe unclean shutdown ?" + rm -f "$SLING_LOGDIR/sling.pid" + SLING_PID= + fi + fi + + # assemble the startup param + SLING_JAVA_VERSION=`javaVersion` + if [ -n "$SLING_JVM_JAAS" ]; then + jvmOpts="$jvmOpts -Djava.security.auth.login.config=$SLING_JVM_JAAS_CONFIG" + fi + if [ -n "$SLING_JVM_VERBOSE_GC" ]; then + jvmOpts="$jvmOpts -verbose:gc" + fi + jvmOpts="$jvmOpts -Xms${SLING_JVM_HEAP_MIN}m" + jvmOpts="$jvmOpts -Xmx${SLING_JVM_HEAP_MAX}m" + jvmOpts="$jvmOpts -Djava.awt.headless=true" + + if [ -n "$SLING_JVM_DEBUG" ]; then + jvmOpts="$jvmOpts -Xdebug -Xnoagent -Djava.compiler=NONE \ +-Xrunjdwp:transport=dt_$SLING_JVM_DEBUG,address=$SLING_JVM_DEBUG_PORT,\ +server=y,suspend=${SLING_JVM_DEBUG_SUSPENDED}" + fi + if [ "$SLING_JVM_PROFILE" = yjp ]; then + if [ $SLING_JAVA_VERSION = "1.4" ]; then + jvmOpts="$jvmOpts -Xrunyjpagent" + else + jvmOpts="$jvmOpts -agentlib:yjpagent" + fi + fi + jvmOpts="$jvmOpts $SLING_JVM_OPTS" + + # assemble program arguments + if [ -n "$SLING_PORT" ]; then + slingOpts="$slingOpts -p $SLING_PORT" + fi + if [ -n "$SLING_INTERFACE" ]; then + slingOpts="$slingOpts -a $SLING_INTERFACE" + fi + if [ -n "$SLING_LOGLEVEL" ]; then + slingOpts="$slingOpts -l $SLING_LOGLEVEL" + fi + if [ -w "$SLING_LOG" ]; then + slingOpts="$slingOpts -f -" + fi + + # executable string + jvmExe="$SLING_JVM $jvmOpts -jar $SLING_CONTEXT/bin/${project.build.finalName}.jar $slingOpts" + export jvmExe + + if verbose; then + dump + echo "" + echo "Execute: $jvmExe" + echo "" + fi + if [ -n "$SLING_DRY" ]; then + echo "" + echo "--dry specified. not starting engine." + exit 0 + fi + + info "Using JVM found at $SLING_JVM" + + if [ -n "$SLING_FOREGROUND" ]; then + ulimit -n $SLING_MAX_OPEN_FILES + info "Starting $SLING_TITLE in foreground" + info "hit Ctrl-C to stop $SLING_TITLE" + printDebug + info "-----------------------------------------------------------" + $jvmExe | tee -a "$SLING_LOG" 2>&1 + exit 0 # in case of failure + else + info "Starting $SLING_TITLE in background..." + printDebug + $0 psmon & + SLING_PID=`cat "$SLING_LOGDIR/sling.pid"` + while [ -z "`cat "$SLING_LOGDIR/sling.pid" 2> /dev/null`" ]; do + sleep 1 + done + info "Started." + fi + exit 0 + ;; +#--------------------------------------------------------------------- + 'psmon') # sets up the process monitor + use_stderr="NO" + if [ -z "jvmExe" ] ; then + usage + exit 0 + fi + trap '' 1 # block HUP + + # exit when TERM signal is received + trap 'info "$SLING_TITLE shutdown on TERM signal"; rm -f "$SLING_LOGDIR/monitor.pid" "$SLING_LOGDIR/sling.pid";exit 0' 15 + + echo $$ > "$SLING_LOGDIR/monitor.pid" + + SHORT_RESTARTS=0 + SLING_BGSTART=1 + export SLING_BGSTART + + while [ 0 ] ; do # forever + BEFORE=`date '+%Y%m%d%H%M%S'` + $0 terminator | $0 bgstart + AFTER=`date '+%Y%m%d%H%M%S'` + + # Check for too many restarts < 10 seconds + # Okay that this will not work across the 59-to-0 second boundary + # because we are just trying to avoid a fast infinite loop caused + # by something like another process already listening on the port + # + RUNTIME=`expr $AFTER - $BEFORE` + if [ $RUNTIME -lt 10 ] ; then + SHORT_RESTARTS=`expr $SHORT_RESTARTS + 1` + else + SHORT_RESTARTS=0 + fi + if [ $SHORT_RESTARTS -eq 3 ] ; then + err "Too many restarts - exiting!" + exit 1 + fi + done + ;; +#--------------------------------------------------------------------- + 'terminator') + use_stderr="NO" + if [ -z "$SLING_BGSTART" ] ; then + usage + exit + fi + # send QUIT to sling upon signal + trap 'slingpid=`/bin/cat "$SLING_LOGDIR/sling.pid" 2>/dev/null` ; if [ -n "$slingpid" ] ; then /bin/kill $slingpid > /dev/null 2>&1 ; fi; rm -f "$SLING_LOGDIR/terminator.pid"; exit 0' 3 6 15 + + echo $$ > "$SLING_LOGDIR/terminator.pid" + while [ 0 ] ; do # forever + sleep 5 + done + ;; +#--------------------------------------------------------------------- + 'bgstart') + use_stderr="NO" + if [ -z "$SLING_BGSTART" ] ; then + usage + exit + fi + ulimit -n $SLING_MAX_OPEN_FILES + echo $$ > "$SLING_LOGDIR/sling.pid" + exec $jvmExe >> "$SLING_LOG" 2>&1 + rm -f "$SLING_LOGDIR/sling.pid" + ;; +#--------------------------------------------------------------------- + 'stop') + use_stderr="YES" + termpid=`/bin/cat "$SLING_LOGDIR/terminator.pid" 2>/dev/null` + monitorpid=`/bin/cat "$SLING_LOGDIR/monitor.pid" 2>/dev/null` + slingpid=`/bin/cat "$SLING_LOGDIR/sling.pid" 2>/dev/null` + if [ -z "$termpid$monitorpid$slingpid" ]; then + echo "$SLING_TITLE not running." + exit 0; + fi + + printf "stopping $SLING_TITLE..." + if [ -n "$monitorpid" ] ; then + /bin/kill $monitorpid > /dev/null 2>&1 + fi + if [ -n "$termpid" ] ; then + /bin/kill $termpid > /dev/null 2>&1 + fi + + COUNTER=0 + while [ -f "$SLING_LOGDIR/sling.pid" ] && [ $COUNTER -lt 20 ]; do + printf "." + COUNTER=`expr $COUNTER + 1` + sleep 1 + done + # this last one is just in case the terminator already failed + slingpid=`/bin/cat "$SLING_LOGDIR/sling.pid" 2>/dev/null` + if ps -p $slingpid > /dev/null 2>&1 ; then + echo "still running. sending TERM signal to PID $slingpid" + /bin/kill $slingpid > /dev/null 2>&1 + else + echo "stopped." + fi + + rm -f "$SLING_LOGDIR/monitor.pid" "$SLING_LOGDIR/terminator.pid" \ + "$SLING_LOGDIR/sling.pid" + ;; +#--------------------------------------------------------------------- + 'restart') + "$0" stop + "$0" start + ;; +#--------------------------------------------------------------------- + 'status') + slingpid=`/bin/cat "$SLING_LOGDIR/sling.pid" 2>/dev/null` + if ps -p $slingpid > /dev/null 2>&1 ; then + echo "$SLING_TITLE is running." + else + echo "$SLING_TITLE is stopped." + fi + ;; +#--------------------------------------------------------------------- + *) + usage + exit + ;; +esac + Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/serverctl ------------------------------------------------------------------------------ svn:executable = * Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start Tue Jan 13 04:04:51 2009 @@ -0,0 +1,68 @@ +#!/bin/sh +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +# +# This script configures the start information for Sling +# +# The following environment variables may be used to override the default +# defined in the HTTP Service implementation: +# +# % SLING_PORT=56000 ./start +# +# this script is a quick wrapper for the main 'serverctl' script which +# has a lot more options. see +# +# serverctl --help +# +# for details. +# + +# override the java home for use by Apache Sling +# JAVA_HOME="/usr/java/j2sdk1.4.2_14" + +# override the port which Sling should bind to +SLING_PORT='8080' + +# override the interface which communique should listen to +# this setting is not currently supported +# SLING_INTERFACE='0.0.0.0' + +# override the initial log-level prior to reading the configuration +# this overwrites the setting in the sling.properties file and is overwritten +# by the LogService configuration. Use any string of DEBUG, INFO, WARN, +# ERROR and FATAL. Default is INFO. +#SLING_LOGLEVEL='INFO' + +# override the initial heap size in mb for use by Sling +#SLING_HEAP_MIN='128' + +# override the maximum heap size in mb for use by Sling +#SLING_HEAP_MAX='256' + +# ------------------------------------------------------------------------------ +# do not configure below this point +# ------------------------------------------------------------------------------ +export JAVA_HOME +export SLING_PORT +export SLING_INTERFACE +export SLING_LOGLEVEL +export SLING_HEAP_MIN +export SLING_HEAP_MAX + +exec "`dirname $0`/serverctl" start $* Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/start ------------------------------------------------------------------------------ svn:executable = * Added: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop URL: http://svn.apache.org/viewvc/incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop?rev=734113&view=auto ============================================================================== --- incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop (added) +++ incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop Tue Jan 13 04:04:51 2009 @@ -0,0 +1,23 @@ +#!/bin/sh +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# +# +# this script stops a running instance of Sling +# +exec "`dirname $0`/serverctl" stop Propchange: incubator/sling/whiteboard/fmeschbe/launchpad/app/src/main/dist/unix/stop ------------------------------------------------------------------------------ svn:executable = *