You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sdap.apache.org by le...@apache.org on 2017/10/27 22:34:51 UTC
[10/21] incubator-sdap-mudrod git commit: SDAP-1 Import all code
under the SDAP SGA
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/pom.xml
----------------------------------------------------------------------
diff --git a/service/pom.xml b/service/pom.xml
new file mode 100644
index 0000000..1704c50
--- /dev/null
+++ b/service/pom.xml
@@ -0,0 +1,258 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>gov.nasa.jpl.mudrod</groupId>
+ <artifactId>mudrod-parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ <relativePath>../</relativePath>
+ </parent>
+
+ <pluginRepositories>
+ <pluginRepository>
+ <id>miredot</id>
+ <name>MireDot Releases</name>
+ <url>http://nexus.qmino.com/content/repositories/miredot</url>
+ </pluginRepository>
+ </pluginRepositories>
+
+ <artifactId>mudrod-service</artifactId>
+ <packaging>war</packaging>
+ <name>Mudrod :: Service</name>
+ <description>Mudrod WebService implementation.</description>
+
+ <dependencies>
+ <!-- Core Module -->
+ <dependency>
+ <groupId>gov.nasa.jpl.mudrod</groupId>
+ <artifactId>mudrod-core</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+
+ <!-- Static web resources -->
+ <dependency>
+ <groupId>gov.nasa.jpl.mudrod</groupId>
+ <artifactId>mudrod-web</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+
+ <!-- Logging dependencies -->
+ <dependency>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-core</artifactId>
+ </dependency>
+ <!-- End of Logging dependencies -->
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>javax.servlet-api</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.cxf</groupId>
+ <artifactId>cxf-rt-frontend-jaxrs</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.cxf</groupId>
+ <artifactId>cxf-rt-rs-client</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.google.code.gson</groupId>
+ <artifactId>gson</artifactId>
+ </dependency>
+
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.tomcat.maven</groupId>
+ <artifactId>tomcat7-maven-plugin</artifactId>
+ <version>2.2</version>
+ <configuration>
+ <port>8080</port>
+ <systemProperties>
+ <CATALINA_OPTS>-Djava.awt.headless=true
+ -Dfile.encoding=UTF-8
+ -server -Xms1536m -Xmx1536m
+ -XX:NewSize=256m -XX:MaxNewSize=256m
+ -XX:PermSize=256m
+ -XX:+DisableExplicitGC
+ -XX:+UseConcMarkSweepGC
+ -XX:+CMSIncrementalMode
+ -XX:+CMSIncrementalPacing
+ -XX:CMSIncrementalDutyCycleMin=0
+ -XX:-TraceClassUnloading
+ </CATALINA_OPTS>
+ </systemProperties>
+ <contextFile>
+ ${basedir}/src/main/webapp/META-INF/context.xml
+ </contextFile>
+ <path>/${project.build.finalName}</path>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-war-plugin</artifactId>
+ <version>2.6</version>
+ <executions>
+ <execution>
+ <id>self-contained-war</id>
+ <phase>package</phase>
+ <goals>
+ <goal>war</goal>
+ </goals>
+ <configuration>
+ <webResources>
+ <resource>
+ <directory>
+ ${project.build.directory}/war-legals/with-deps/
+ </directory>
+ <targetPath>/META-INF</targetPath>
+ </resource>
+ </webResources>
+ </configuration>
+ </execution>
+ <execution>
+ <id>war-without-deps</id>
+ <phase>package</phase>
+ <goals>
+ <goal>war</goal>
+ </goals>
+ <configuration>
+ <classifier>without-deps</classifier>
+ <packagingExcludes>WEB-INF/lib/*.jar
+ </packagingExcludes>
+ <archive>
+ <manifest>
+ <addClasspath>true</addClasspath>
+ <classpathPrefix>lib/</classpathPrefix>
+ </manifest>
+ </archive>
+ <webResources>
+ <resource>
+ <directory>
+ ${project.build.directory}/war-legals/without-deps/
+ </directory>
+ <targetPath>/META-INF</targetPath>
+ </resource>
+ </webResources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <!-- Generates the distribution package -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-assembly-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>prepare-package</id>
+ <phase>prepare-package</phase>
+ <goals>
+ <goal>single</goal>
+ </goals>
+ <configuration>
+ <attach>false</attach>
+ <finalName>war-legals</finalName>
+ <appendAssemblyId>false</appendAssemblyId>
+ <descriptors>
+ <descriptor>
+ ${basedir}/src/main/assembly/prepare-war-legals.xml
+ </descriptor>
+ </descriptors>
+ </configuration>
+ </execution>
+ </executions>
+ <configuration>
+ <descriptors>
+ <descriptor>${basedir}/src/main/assembly/with-deps.xml
+ </descriptor>
+ <descriptor>
+ ${basedir}/src/main/assembly/without-deps.xml
+ </descriptor>
+ <descriptor>
+ ${basedir}/src/main/assembly/server-embedded.xml
+ </descriptor>
+ </descriptors>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <groupId>com.qmino</groupId>
+ <artifactId>miredot-plugin</artifactId>
+ <version>2.0.3</version>
+ <executions>
+ <execution>
+ <phase>prepare-package</phase>
+ <goals>
+ <goal>restdoc</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <!-- The license key expires on may 1st, 2019, after which
+ we can apply to Miredot for a new key. -->
+ <licence>cHJvamVjdHxnb3YubmFzYS5qcGwubXVkcm9kLm11ZHJvZC1zZXJ2aWNlfDIwMTktMDUtMDJ8dHJ1ZXwtMSNNQ3dDRkZ6QXBGdzA4dUdJVGtYcml3ckJRbis5WjdLWkFoUWgyaVRZS2EwVTF3NGlObWxlRDlDVzJoaWE5UT09</licence>
+ <organizationId>f3f4ce56-816e-4f1d-963e-e7936ee846c5</organizationId>
+ <restModel>
+ <restFramework>
+ <name>jax-rs</name>
+ </restFramework>
+ </restModel>
+ <output>
+ <html></html>
+ </output>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>release</id>
+ <build>
+ <resources>
+ <resource>
+ <directory>${basedir}/../</directory>
+ <targetPath>
+ ${project.build.directory}/apidocs/META-INF
+ </targetPath>
+ <includes>
+ <include>LICENSE.txt</include>
+ <include>NOTICE.txt</include>
+ </includes>
+ </resource>
+ </resources>
+ </build>
+ </profile>
+ </profiles>
+
+</project>
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/LICENSE-server-embedded.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/LICENSE-server-embedded.txt b/service/src/main/assembly/LICENSE-server-embedded.txt
new file mode 100644
index 0000000..8c1c026
--- /dev/null
+++ b/service/src/main/assembly/LICENSE-server-embedded.txt
@@ -0,0 +1,219 @@
+
+ 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.
+
+MUDROD DEPENDENCIES:
+
+The Murdor distribution packages include a number of dependencies with
+separate copyright notices and license terms. Your use of the binaries for these
+dependencies is subject to the terms and conditions of the following licenses.
+
+For the Google Gson (https://github.com/google/gson)
+This is licensed under the Apache License v2.0, see above
+
+For the Jetty Web Container (http://mortbay.com/)
+This is licensed under the Apache License v2.0, see above
+
+For the Apache Spark components (http://www.aduna-software.org/)
+This is licensed under the Aduna BSD license, see above
+
+... TODO
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/LICENSE-with-deps.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/LICENSE-with-deps.txt b/service/src/main/assembly/LICENSE-with-deps.txt
new file mode 100644
index 0000000..8b0652f
--- /dev/null
+++ b/service/src/main/assembly/LICENSE-with-deps.txt
@@ -0,0 +1,217 @@
+
+ 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.
+
+MUDROD DEPENDENCIES:
+
+The Murdor distribution packages include a number of dependencies with
+separate copyright notices and license terms. Your use of the binaries for these
+dependencies is subject to the terms and conditions of the following licenses.
+
+For the Google Gson (https://github.com/google/gson)
+This is licensed under the Apache License v2.0, see above
+
+For the Jetty Web Container (http://mortbay.com/)
+This is licensed under the Apache License v2.0, see above
+
+For the Apache Spark components (http://www.aduna-software.org/)
+This is licensed under the Aduna BSD license, see above
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/LICENSE-without-deps.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/LICENSE-without-deps.txt b/service/src/main/assembly/LICENSE-without-deps.txt
new file mode 100644
index 0000000..ccf4044
--- /dev/null
+++ b/service/src/main/assembly/LICENSE-without-deps.txt
@@ -0,0 +1,206 @@
+
+ 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.
+
+APACHE ANY23 DEPENDENCIES:
+
+TODO
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/NOTICE-server-embedded.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/NOTICE-server-embedded.txt b/service/src/main/assembly/NOTICE-server-embedded.txt
new file mode 100644
index 0000000..e00d042
--- /dev/null
+++ b/service/src/main/assembly/NOTICE-server-embedded.txt
@@ -0,0 +1,4 @@
+Mudrod
+
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/NOTICE-with-deps.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/NOTICE-with-deps.txt b/service/src/main/assembly/NOTICE-with-deps.txt
new file mode 100644
index 0000000..6e464c1
--- /dev/null
+++ b/service/src/main/assembly/NOTICE-with-deps.txt
@@ -0,0 +1,6 @@
+Mudrod
+Copyright 2011-2012 The Apache Software Foundation
+Copyright 2008-2011 Digital Enterprise Research Institute (DERI)
+
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/NOTICE-without-deps.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/NOTICE-without-deps.txt b/service/src/main/assembly/NOTICE-without-deps.txt
new file mode 100644
index 0000000..e00d042
--- /dev/null
+++ b/service/src/main/assembly/NOTICE-without-deps.txt
@@ -0,0 +1,4 @@
+Mudrod
+
+This product includes software developed by
+The Apache Software Foundation (http://www.apache.org/).
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/README.txt
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/README.txt b/service/src/main/assembly/README.txt
new file mode 100644
index 0000000..3cf10aa
--- /dev/null
+++ b/service/src/main/assembly/README.txt
@@ -0,0 +1,110 @@
+ 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.
+
+Apache Any23 Service ${project.version} (${implementation.build.tstamp})
+
+ What is it?
+ -----------
+
+ ${project.description}
+
+ Documentation
+ -------------
+
+ The most up-to-date documentation can be found at ${project.parent.url}.
+
+ Release Notes
+ -------------
+
+ The full list of changes can be found at ${project.parent.url}/service.html.
+
+ System Requirements
+ -------------------
+
+ JDK:
+ ${javac.target.version} or above. (see http://www.oracle.com/technetwork/java/)
+ Memory:
+ No minimum requirement.
+ Disk:
+ No minimum requirement.
+ Operating System:
+ No minimum requirement. On Windows, Windows NT and above or Cygwin is required for
+ the startup scripts. Tested on Windows XP, Fedora Core and Mac OS X.
+
+ Installing Apache Any23 Service
+ ----------------
+
+** Windows 2000/XP
+
+ 1) Unzip the distribution archive, i.e. apache-${project.build.finalName}-bin.zip to the directory you wish to
+ install Apache Any23 ${project.version}.
+ These instructions assume you chose C:\Program Files\Apache Software Foundation.
+ The subdirectory apache-${project.build.finalName} will be created from the archive.
+
+ 2) Add the ANY23_HOME environment variable by opening up the system properties (WinKey + Pause),
+ selecting the "Advanced" tab, and the "Environment Variables" button, then adding the ANY23_HOME
+ variable in the user variables with the value
+ C:\Program Files\Apache Software Foundation\apache-${project.build.finalName}.
+
+ 3) In the same dialog, add the ANY23 environment variable in the user variables with the value %ANY23_HOME%\bin.
+
+ 4) Optional: In the same dialog, add the EXTRA_JVM_ARGUMENTS environment variable in the user variables to specify
+ JVM properties, e.g. the value -Xms256m -Xmx512m. This environment variable can be used to supply extra options.
+ By default, it is set to: -Xms500m -Xmx500m -XX:PermSize=128m -XX:-UseGCOverheadLimit
+
+ 5) In the same dialog, update/create the Path environment variable in the user variables and prepend the value
+ %ANY23% to add Apache Any23 available in the command line.
+
+ 6) In the same dialog, make sure that JAVA_HOME exists in your user variables or in the system variables and it is
+ set to the location of your JDK, e.g. C:\Program Files\Java\jdk1.5.0_02 and that %JAVA_HOME%\bin is in your Path
+ environment variable.
+
+ 7) Open a new command prompt (Winkey + R then type cmd) and run any23server to launch the service.
+
+** Unix-based Operating Systems (Linux, Solaris and Mac OS X)
+
+ 1) Extract the distribution archive, i.e. apache-${project.build.finalName}-bin.tar.gz to the directory you wish to
+ install Apache Any23 ${project.version}.
+ These instructions assume you chose /usr/local/apache-any23.
+ The subdirectory apache-${project.build.finalName} will be created from the archive.
+
+ 2) In a command terminal, add the ANY23_HOME environment variable, e.g.
+ export ANY23_HOME=/usr/local/apache-any23/apache-${project.build.finalName}.
+
+ 3) Add the ANY23 environment variable, e.g. export ANY23=$ANY23_HOME/bin.
+
+ 4) Optional: Add the EXTRA_JVM_ARGUMENTS environment variable to specify JVM properties, e.g.
+ export EXTRA_JVM_ARGUMENTS="-Xms256m -Xmx512m".
+ This environment variable can be used to supply extra options.
+
+ 5) Add ANY23 environment variable to your path, e.g. export PATH=$ANY23:$PATH.
+
+ 6) Make sure that JAVA_HOME is set to the location of your JDK, e.g.
+ export JAVA_HOME=/usr/java/jdk1.5.0_02 and that $JAVA_HOME/bin is in your PATH environment variable.
+
+ 7) Run any23server to launch the service.
+
+ Licensing
+ ---------
+
+ Please see the file called LICENSE.TXT
+
+ Apache Any23 URLS
+ ----------
+
+ Home Page: ${project.parent.url}/
+ Downloads: ${project.parent.url}/download.html
+ Release Notes: ${project.parent.url}/changes-report.html
+ Mailing Lists: ${project.parent.url}/mail-lists.html
+ Source Code: ${project.parent.scm.url}
+ Issue Tracking: ${project.issueManagement.url}
+ Available Plugins: ${project.parent.url}/plugins.html
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/prepare-war-legals.xml
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/prepare-war-legals.xml b/service/src/main/assembly/prepare-war-legals.xml
new file mode 100644
index 0000000..bc4ee1c
--- /dev/null
+++ b/service/src/main/assembly/prepare-war-legals.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+<assembly
+ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1 http://maven.apache.org/xsd/assembly-1.1.1.xsd">
+
+ <id>prepare-war-legals</id>
+ <formats>
+ <format>dir</format>
+ </formats>
+ <includeBaseDirectory>false</includeBaseDirectory>
+
+ <files>
+ <file>
+ <source>${basedir}/src/main/assembly/LICENSE-with-deps.txt</source>
+ <destName>LICENSE.txt</destName>
+ <outputDirectory>/with-deps</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/NOTICE-with-deps.txt</source>
+ <destName>NOTICE.txt</destName>
+ <outputDirectory>/with-deps</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/LICENSE-without-deps.txt
+ </source>
+ <destName>LICENSE.txt</destName>
+ <outputDirectory>/without-deps</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ </files>
+
+</assembly>
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/server-embedded.xml
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/server-embedded.xml b/service/src/main/assembly/server-embedded.xml
new file mode 100644
index 0000000..88e9433
--- /dev/null
+++ b/service/src/main/assembly/server-embedded.xml
@@ -0,0 +1,87 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+<assembly
+ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1 http://maven.apache.org/xsd/assembly-1.1.1.xsd">
+
+ <id>server-embedded</id>
+ <formats>
+ <format>tar.gz</format>
+ <format>zip</format>
+ </formats>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <baseDirectory>${project.build.finalName}-server-embedded</baseDirectory>
+
+ <files>
+ <file>
+ <source>${basedir}/src/main/assembly/README.txt</source>
+ <filtered>true</filtered>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/LICENSE-server-embedded.txt
+ </source>
+ <destName>LICENSE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/NOTICE-server-embedded.txt
+ </source>
+ <destName>NOTICE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/../RELEASE-NOTES.txt</source>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ </files>
+
+ <fileSets>
+ <!--
+ | shell scripts
+ -->
+ <fileSet>
+ <directory>${basedir}/src/main/bin/</directory>
+ <outputDirectory>/bin</outputDirectory>
+ <fileMode>755</fileMode>
+ <filtered>true</filtered>
+ </fileSet>
+ </fileSets>
+
+ <dependencySets>
+ <dependencySet>
+ <useProjectArtifact>true</useProjectArtifact>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>${project.groupId}:${project.artifactId}</include>
+ </includes>
+ </dependencySet>
+
+ <dependencySet>
+ <useProjectArtifact>true</useProjectArtifact>
+ <outputDirectory>/lib</outputDirectory>
+ <scope>provided</scope>
+ <includes>
+ <include>org.mortbay.jetty:jetty-runner</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+
+</assembly>
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/with-deps.xml
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/with-deps.xml b/service/src/main/assembly/with-deps.xml
new file mode 100644
index 0000000..be68d87
--- /dev/null
+++ b/service/src/main/assembly/with-deps.xml
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+<assembly
+ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1 http://maven.apache.org/xsd/assembly-1.1.1.xsd">
+
+ <id>with-deps</id>
+ <formats>
+ <format>tar.gz</format>
+ <format>zip</format>
+ </formats>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <baseDirectory>${project.build.finalName}-with-deps</baseDirectory>
+
+ <files>
+ <!-- with-deps -->
+ <file>
+ <source>${basedir}/src/main/assembly/LICENSE-with-deps.txt</source>
+ <destName>LICENSE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/NOTICE-with-deps.txt</source>
+ <destName>NOTICE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/../RELEASE-NOTES.txt</source>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ </files>
+
+ <dependencySets>
+ <dependencySet>
+ <useProjectArtifact>true</useProjectArtifact>
+ <outputDirectory>/lib</outputDirectory>
+ <includes>
+ <include>${project.groupId}:${project.artifactId}</include>
+ </includes>
+ </dependencySet>
+ </dependencySets>
+
+</assembly>
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/assembly/without-deps.xml
----------------------------------------------------------------------
diff --git a/service/src/main/assembly/without-deps.xml b/service/src/main/assembly/without-deps.xml
new file mode 100644
index 0000000..5de0965
--- /dev/null
+++ b/service/src/main/assembly/without-deps.xml
@@ -0,0 +1,56 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+<assembly
+ xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.1 http://maven.apache.org/xsd/assembly-1.1.1.xsd">
+
+ <id>without-deps</id>
+ <formats>
+ <format>tar.gz</format>
+ <format>zip</format>
+ </formats>
+ <includeBaseDirectory>true</includeBaseDirectory>
+ <baseDirectory>${project.build.finalName}-without-deps</baseDirectory>
+
+ <files>
+ <!-- without-deps -->
+ <file>
+ <source>${basedir}/src/main/assembly/LICENSE-without-deps.txt
+ </source>
+ <destName>LICENSE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/src/main/assembly/NOTICE-without-deps.txt
+ </source>
+ <destName>NOTICE.txt</destName>
+ <outputDirectory>/</outputDirectory>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>${basedir}/../RELEASE-NOTES.txt</source>
+ <fileMode>666</fileMode>
+ </file>
+ <file>
+ <source>
+ ${project.build.directory}/${project.build.finalName}-without-deps.${project.packaging}
+ </source>
+ <outputDirectory>/lib</outputDirectory>
+ </file>
+ </files>
+
+</assembly>
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/bin/mudrodserver
----------------------------------------------------------------------
diff --git a/service/src/main/bin/mudrodserver b/service/src/main/bin/mudrodserver
new file mode 100644
index 0000000..00a3675
--- /dev/null
+++ b/service/src/main/bin/mudrodserver
@@ -0,0 +1,87 @@
+#!/bin/sh
+# ----------------------------------------------------------------------------
+# 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.
+# ----------------------------------------------------------------------------
+
+BASEDIR=`dirname $0`/..
+BASEDIR=`(cd "$BASEDIR"; pwd)`
+
+# OS specific support. $var _must_ be set to either true or false.
+cygwin=false;
+darwin=false;
+case "`uname`" in
+ CYGWIN*) cygwin=true ;;
+ Darwin*) darwin=true
+ if [ -z "$JAVA_VERSION" ] ; then
+ JAVA_VERSION="CurrentJDK"
+ else
+ echo "Using Java version: $JAVA_VERSION"
+ fi
+ if [ -z "$JAVA_HOME" ] ; then
+ JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/${JAVA_VERSION}/Home
+ fi
+ ;;
+esac
+
+if [ -z "$JAVA_HOME" ] ; then
+ if [ -r /etc/gentoo-release ] ; then
+ JAVA_HOME=`java-config --jre-home`
+ fi
+fi
+
+# For Cygwin, ensure paths are in UNIX format before anything is touched
+if $cygwin ; then
+ [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
+ [ -n "$CLASSPATH" ] && CLASSPATH=`cygpath --path --unix "$CLASSPATH"`
+fi
+
+# If a specific java binary isn't specified search for the standard 'java' binary
+if [ -z "$JAVACMD" ] ; then
+ if [ -n "$JAVA_HOME" ] ; then
+ if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
+ # IBM's JDK on AIX uses strange locations for the executables
+ JAVACMD="$JAVA_HOME/jre/sh/java"
+ else
+ JAVACMD="$JAVA_HOME/bin/java"
+ fi
+ else
+ JAVACMD=`which java`
+ fi
+fi
+
+if [ ! -x "$JAVACMD" ] ; then
+ echo "Error: JAVA_HOME is not defined correctly."
+ echo " We cannot execute $JAVACMD"
+ exit 1
+fi
+
+if [ -z "$REPO" ]
+then
+ REPO="$BASEDIR"/lib
+fi
+
+EXTRA_JVM_ARGUMENTS="-Xms500m -Xmx500m -XX:PermSize=128m -XX:-UseGCOverheadLimit"
+
+# For Cygwin, switch paths to Windows format before running java
+if $cygwin; then
+ [ -n "$CLASSPATH" ] && CLASSPATH=`cygpath --path --windows "$CLASSPATH"`
+ [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"`
+ [ -n "$HOME" ] && HOME=`cygpath --path --windows "$HOME"`
+ [ -n "$BASEDIR" ] && BASEDIR=`cygpath --path --windows "$BASEDIR"`
+ [ -n "$REPO" ] && REPO=`cygpath --path --windows "$REPO"`
+fi
+
+exec "$JAVACMD" $JAVA_OPTS \
+ $EXTRA_JVM_ARGUMENTS \
+ -jar "$REPO"/jetty-runner-${jetty.runner.version}.jar \
+ --path /${project.artifactId} "$REPO"/${project.build.finalName}.${project.packaging}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/bin/mudrodserver.bat
----------------------------------------------------------------------
diff --git a/service/src/main/bin/mudrodserver.bat b/service/src/main/bin/mudrodserver.bat
new file mode 100644
index 0000000..7bee368
--- /dev/null
+++ b/service/src/main/bin/mudrodserver.bat
@@ -0,0 +1,102 @@
+@REM ----------------------------------------------------------------------------
+@REM Licensed under the Apache License, Version 2.0 (the "License");
+@REM you may not use this file except in compliance with the License.
+@REM You may obtain a copy of the License at
+
+@REM http://www.apache.org/licenses/LICENSE-2.0
+
+@REM Unless required by applicable law or agreed to in writing, software
+@REM distributed under the License is distributed on an "AS IS" BASIS,
+@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+@REM See the License for the specific language governing permissions and
+@REM limitations under the License.
+@REM ----------------------------------------------------------------------------
+@REM
+
+@echo off
+
+set ERROR_CODE=0
+
+:init
+@REM Decide how to startup depending on the version of windows
+
+@REM -- Win98ME
+if NOT "%OS%"=="Windows_NT" goto Win9xArg
+
+@REM set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" @setlocal
+
+@REM -- 4NT shell
+if "%eval[2+2]" == "4" goto 4NTArgs
+
+@REM -- Regular WinNT shell
+set CMD_LINE_ARGS=%*
+goto WinNTGetScriptDir
+
+@REM The 4NT Shell from jp software
+:4NTArgs
+set CMD_LINE_ARGS=%$
+goto WinNTGetScriptDir
+
+:Win9xArg
+@REM Slurp the command line arguments. This loop allows for an unlimited number
+@REM of arguments (up to the command line limit, anyway).
+set CMD_LINE_ARGS=
+:Win9xApp
+if %1a==a goto Win9xGetScriptDir
+set CMD_LINE_ARGS=%CMD_LINE_ARGS% %1
+shift
+goto Win9xApp
+
+:Win9xGetScriptDir
+set SAVEDIR=%CD%
+%0\
+cd %0\..\..
+set BASEDIR=%CD%
+cd %SAVEDIR%
+set SAVE_DIR=
+goto repoSetup
+
+:WinNTGetScriptDir
+set BASEDIR=%~dp0\..
+
+:repoSetup
+
+
+if "%JAVACMD%"=="" set JAVACMD=java
+
+if "%REPO%"=="" set REPO=%BASEDIR%\lib
+
+set EXTRA_JVM_ARGUMENTS=-Xms500m -Xmx500m -XX:PermSize=128m -XX:-UseGCOverheadLimit
+goto endInit
+
+@REM Reaching here means variables are defined and arguments have been captured
+:endInit
+
+%JAVACMD% %JAVA_OPTS% %EXTRA_JVM_ARGUMENTS% -jar "%REPO%"/jetty-runner-${jetty.runner.version}.jar --path /${project.artifactId} "%REPO%"/${project.build.finalName}.${project.packaging}
+if ERRORLEVEL 1 goto error
+goto end
+
+:error
+if "%OS%"=="Windows_NT" @endlocal
+set ERROR_CODE=1
+
+:end
+@REM set local scope for the variables with windows NT shell
+if "%OS%"=="Windows_NT" goto endNT
+
+@REM For old DOS remove the set variables from ENV - we assume they were not set
+@REM before we started - at least we don't leave any baggage around
+set CMD_LINE_ARGS=
+goto postExec
+
+:endNT
+@endlocal
+
+:postExec
+
+if "%FORCE_EXIT_ON_ERROR%" == "on" (
+ if %ERROR_CODE% NEQ 0 exit %ERROR_CODE%
+)
+
+exit /B %ERROR_CODE%
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/DefaultExceptionMapper.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/DefaultExceptionMapper.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/DefaultExceptionMapper.java
new file mode 100644
index 0000000..a2d2731
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/DefaultExceptionMapper.java
@@ -0,0 +1,45 @@
+/*
+ * 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.
+ */
+package gov.nasa.jpl.mudrod.services;
+
+import com.google.gson.Gson;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.Response;
+import javax.ws.rs.ext.ExceptionMapper;
+import javax.ws.rs.ext.Provider;
+import java.util.UUID;
+
+/**
+ * Created by greguska on 4/11/17.
+ */
+@Provider
+public class DefaultExceptionMapper implements ExceptionMapper<Throwable> {
+
+ private static final Logger LOG = LoggerFactory.getLogger(DefaultExceptionMapper.class);
+
+ @Override
+ @Produces("text/html")
+ public Response toResponse(Throwable e) {
+
+ UUID errorId = UUID.randomUUID();
+ LOG.error("Internal server error " + errorId.toString(), e);
+
+ String errorString = "An error occurred while processing your request. Please contact the system administrator and provide the following error log ID " + errorId.toString();
+
+ return Response.serverError().entity(new Gson().toJson(errorString)).build();
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/MudrodContextListener.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/MudrodContextListener.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/MudrodContextListener.java
new file mode 100644
index 0000000..84df5f6
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/MudrodContextListener.java
@@ -0,0 +1,73 @@
+/*
+ * 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.
+ */
+package gov.nasa.jpl.mudrod.services;
+
+import gov.nasa.jpl.mudrod.driver.ESDriver;
+import gov.nasa.jpl.mudrod.driver.SparkDriver;
+import gov.nasa.jpl.mudrod.main.MudrodEngine;
+import gov.nasa.jpl.mudrod.ontology.Ontology;
+import gov.nasa.jpl.mudrod.ontology.OntologyFactory;
+import gov.nasa.jpl.mudrod.ssearch.Ranker;
+import gov.nasa.jpl.mudrod.ssearch.Searcher;
+
+import javax.servlet.ServletContext;
+import javax.servlet.ServletContextEvent;
+import javax.servlet.ServletContextListener;
+import javax.servlet.annotation.WebListener;
+import java.util.Properties;
+
+/**
+ * Application Lifecycle Listener implementation class MudrodContextListener
+ */
+@WebListener
+public class MudrodContextListener implements ServletContextListener {
+
+ MudrodEngine me = null;
+
+ /**
+ * Default constructor.
+ */
+ public MudrodContextListener() {
+ // default constructor
+ }
+
+ /**
+ * @see ServletContextListener#contextDestroyed(ServletContextEvent)
+ */
+ @Override
+ public void contextDestroyed(ServletContextEvent arg0) {
+ me.end();
+ }
+
+ /**
+ * @see ServletContextListener#contextInitialized(ServletContextEvent)
+ */
+ @Override
+ public void contextInitialized(ServletContextEvent arg0) {
+ me = new MudrodEngine();
+ Properties props = me.loadConfig();
+ me.setESDriver(new ESDriver(props));
+ me.setSparkDriver(new SparkDriver(props));
+
+ ServletContext ctx = arg0.getServletContext();
+ Searcher searcher = new Searcher(props, me.getESDriver(), null);
+ Ranker ranker = new Ranker(props, me.getESDriver(), me.getSparkDriver(), "SparkSVM");
+ Ontology ontImpl = new OntologyFactory(props).getOntology();
+ ctx.setAttribute("MudrodInstance", me);
+ ctx.setAttribute("MudrodSearcher", searcher);
+ ctx.setAttribute("MudrodRanker", ranker);
+ ctx.setAttribute("Ontology", ontImpl);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteData.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteData.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteData.java
new file mode 100644
index 0000000..206ce00
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteData.java
@@ -0,0 +1,34 @@
+/*
+ * 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.
+ */
+package gov.nasa.jpl.mudrod.services.autocomplete;
+
+public class AutoCompleteData {
+ private final String label;
+ private final String value;
+
+ public AutoCompleteData(String label, String value) {
+ super();
+ this.label = label;
+ this.value = value;
+ }
+
+ public final String getLabel() {
+ return this.label;
+ }
+
+ public final String getValue() {
+ return this.value;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteResource.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteResource.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteResource.java
new file mode 100644
index 0000000..84dbbb7
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/AutoCompleteResource.java
@@ -0,0 +1,65 @@
+/*
+ * 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.
+ */
+package gov.nasa.jpl.mudrod.services.autocomplete;
+
+import com.google.gson.Gson;
+import gov.nasa.jpl.mudrod.main.MudrodConstants;
+import gov.nasa.jpl.mudrod.main.MudrodEngine;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.servlet.ServletContext;
+import javax.ws.rs.*;
+import javax.ws.rs.core.Context;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * An AutoCompleteResource for term autocompletion suggestion.
+ */
+@Path("/autocomplete")
+public class AutoCompleteResource {
+
+ private static final Logger LOG = LoggerFactory.getLogger(AutoCompleteResource.class);
+ private MudrodEngine mEngine;
+
+ public AutoCompleteResource(@Context ServletContext sc) {
+ this.mEngine = (MudrodEngine) sc.getAttribute("MudrodInstance");
+ }
+
+ @GET
+ @Path("/status")
+ @Produces("text/html")
+ public Response status() {
+ return Response.ok("<h1>This is MUDROD AutoCompleteResource: running correctly...</h1>").build();
+ }
+
+ @GET
+ @Path("/query")
+ @Produces(MediaType.APPLICATION_JSON)
+ @Consumes("text/plain")
+ public Response autoComplete(@QueryParam("term") String term) {
+ List<AutoCompleteData> result = new ArrayList<>();
+ List<String> suggestList = mEngine.getESDriver().autoComplete(mEngine.getConfig().getProperty(MudrodConstants.ES_INDEX_NAME), term);
+ for (final String item : suggestList) {
+ result.add(new AutoCompleteData(item, item));
+ }
+ String json = new Gson().toJson(result);
+ LOG.info("Response received: {}", json);
+ return Response.ok(json, MediaType.APPLICATION_JSON).build();
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/package-info.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/package-info.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/package-info.java
new file mode 100644
index 0000000..24aa022
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/autocomplete/package-info.java
@@ -0,0 +1,17 @@
+/*
+ * 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.
+ */
+/**
+ * Mudrod Autocompletion resources.
+ */
+package gov.nasa.jpl.mudrod.services.autocomplete;
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/OntologyResource.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/OntologyResource.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/OntologyResource.java
new file mode 100644
index 0000000..e0ade84
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/OntologyResource.java
@@ -0,0 +1,88 @@
+/*
+ * 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.
+ */
+package gov.nasa.jpl.mudrod.services.ontology;
+
+import com.google.gson.Gson;
+import gov.nasa.jpl.mudrod.ontology.Ontology;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.servlet.ServletContext;
+import javax.ws.rs.Consumes;
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+import javax.ws.rs.QueryParam;
+import javax.ws.rs.core.Context;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+/**
+ * A ontology-driven resource for user query augmentation.
+ */
+@Path("/ontology")
+public class OntologyResource {
+
+ private static final Logger LOG = LoggerFactory.getLogger(OntologyResource.class);
+ private Ontology ontImpl;
+
+ public OntologyResource(@Context ServletContext sc) {
+ this.ontImpl = (Ontology) sc.getAttribute("Ontology");
+ }
+
+ @GET
+ @Path("/status")
+ @Produces("text/html")
+ public Response status() {
+ return Response.ok("<h1>This is MUDROD Ontology-driven User Query Augmentation Resource: running correctly...</h1>").build();
+ }
+
+ @GET
+ @Path("/synonym")
+ @Produces(MediaType.APPLICATION_JSON)
+ @Consumes("text/plain")
+ public Response getOntologySynonyms(@QueryParam("query") String query) {
+ List<String> result = new ArrayList<>();
+ if (query != null) {
+ Iterator<String> synonyms = ontImpl.synonyms(query);
+ while (synonyms.hasNext()) {
+ result.add((String) synonyms.next());
+ }
+ }
+ String json = new Gson().toJson(result);
+ LOG.info("Response received: {}", json);
+ return Response.ok(json, MediaType.APPLICATION_JSON).build();
+ }
+
+ @GET
+ @Path("/subclass")
+ @Produces(MediaType.APPLICATION_JSON)
+ @Consumes("text/plain")
+ public Response getOntologySubclasses(@QueryParam("query") String query) {
+ List<String> result = new ArrayList<>();
+ if (query != null) {
+ Iterator<String> subclasses = ontImpl.subclasses(query);
+ while (subclasses.hasNext()) {
+ result.add((String) subclasses.next());
+ }
+ }
+ String json = new Gson().toJson(result);
+ LOG.info("Response received: {}", json);
+ return Response.ok(json, MediaType.APPLICATION_JSON).build();
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/package-info.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/package-info.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/package-info.java
new file mode 100644
index 0000000..55a68d6
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/ontology/package-info.java
@@ -0,0 +1,17 @@
+/*
+ * 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.
+ */
+/**
+ * Mudrod ontology resources.
+ */
+package gov.nasa.jpl.mudrod.services.ontology;
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-sdap-mudrod/blob/7b76fa16/service/src/main/java/gov/nasa/jpl/mudrod/services/package-info.java
----------------------------------------------------------------------
diff --git a/service/src/main/java/gov/nasa/jpl/mudrod/services/package-info.java b/service/src/main/java/gov/nasa/jpl/mudrod/services/package-info.java
new file mode 100644
index 0000000..ef31bb1
--- /dev/null
+++ b/service/src/main/java/gov/nasa/jpl/mudrod/services/package-info.java
@@ -0,0 +1,17 @@
+/*
+ * 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.
+ */
+/**
+ * This package includes base listeners, etc. for Mudrod services.
+ */
+package gov.nasa.jpl.mudrod.services;
\ No newline at end of file