You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicemix.apache.org by ff...@apache.org on 2015/04/27 03:41:29 UTC

servicemix-bundles git commit: [SM-2500]Create OSGi bundle for spark-java version 2.1

Repository: servicemix-bundles
Updated Branches:
  refs/heads/master 1ab28376e -> 792496bc9


[SM-2500]Create OSGi bundle for spark-java version 2.1


Project: http://git-wip-us.apache.org/repos/asf/servicemix-bundles/repo
Commit: http://git-wip-us.apache.org/repos/asf/servicemix-bundles/commit/792496bc
Tree: http://git-wip-us.apache.org/repos/asf/servicemix-bundles/tree/792496bc
Diff: http://git-wip-us.apache.org/repos/asf/servicemix-bundles/diff/792496bc

Branch: refs/heads/master
Commit: 792496bc9f7dddfbe594497b0c0c5d977b771875
Parents: 1ab2837
Author: Freeman Fang <fr...@gmail.com>
Authored: Mon Apr 27 09:41:13 2015 +0800
Committer: Freeman Fang <fr...@gmail.com>
Committed: Mon Apr 27 09:41:13 2015 +0800

----------------------------------------------------------------------
 pom.xml                                         |   1 +
 sparkjava-core-2.1/pom.xml                      | 114 +++++++++++++++++++
 .../src/main/resources/OSGI-INF/bundle.info     |  11 ++
 3 files changed, 126 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/servicemix-bundles/blob/792496bc/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 2941408..7f9492f 100644
--- a/pom.xml
+++ b/pom.xml
@@ -48,6 +48,7 @@
         <module>docker-java-1.2.0</module>
         <module>olingo-odata2-api-2.0.3</module>
         <module>olingo-odata2-core-2.0.3</module>
+        <module>sparkjava-core-2.1</module>
     </modules>
 
 </project>

http://git-wip-us.apache.org/repos/asf/servicemix-bundles/blob/792496bc/sparkjava-core-2.1/pom.xml
----------------------------------------------------------------------
diff --git a/sparkjava-core-2.1/pom.xml b/sparkjava-core-2.1/pom.xml
new file mode 100644
index 0000000..51383e1
--- /dev/null
+++ b/sparkjava-core-2.1/pom.xml
@@ -0,0 +1,114 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<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/xsd/maven-4.0.0.xsd">
+
+    <!--
+
+        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.
+    -->
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.servicemix.bundles</groupId>
+        <artifactId>bundles-pom</artifactId>
+        <version>12</version>
+        <relativePath>../bundles-pom/pom.xml</relativePath>
+    </parent>
+
+    <groupId>org.apache.servicemix.bundles</groupId>
+    <artifactId>org.apache.servicemix.bundles.sparkjava-core</artifactId>
+    <version>2.1_1-SNAPSHOT</version>
+    <packaging>bundle</packaging>
+    <name>Apache ServiceMix :: Bundles :: ${pkgArtifactId}</name>
+
+    <properties>
+        <pkgGroupId>com.sparkjava</pkgGroupId>
+        <pkgArtifactId>spark-core</pkgArtifactId>
+        <pkgVersion>2.1</pkgVersion>
+    </properties>
+
+    <dependencies>
+        <dependency>
+            <groupId>${pkgGroupId}</groupId>
+            <artifactId>${pkgArtifactId}</artifactId>
+            <version>${pkgVersion}</version>
+        </dependency>
+
+        <!-- sources -->
+        <dependency>
+            <groupId>${pkgGroupId}</groupId>
+            <artifactId>${pkgArtifactId}</artifactId>
+            <version>${pkgVersion}</version>
+            <classifier>sources</classifier>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-shade-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <phase>package</phase>
+                        <goals>
+                            <goal>shade</goal>
+                        </goals>
+                        <configuration>
+                            <artifactSet>
+                                <includes>
+                                    <include>${pkgGroupId}:${pkgArtifactId}</include>
+                                </includes>
+                            </artifactSet>
+                            <filters>
+                                <filter>
+                                    <artifact>${pkgGroupId}:${pkgArtifactId}</artifact>
+				    <excludes>
+					<exclude>**/*</exclude>
+				    </excludes>
+                                </filter>
+                            </filters>
+                            <promoteTransitiveDependencies>true</promoteTransitiveDependencies>
+                            <createDependencyReducedPom>true</createDependencyReducedPom>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.felix</groupId>
+                <artifactId>maven-bundle-plugin</artifactId>
+                <version>2.5.3</version>
+                <extensions>true</extensions>
+                <inherited>false</inherited>
+                <configuration>
+                    <instructions>
+                        <Bundle-Name>sparkjava</Bundle-Name>
+                        <Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
+                        <Export-Package>
+			   spark.*;version="${pkgVersion}";-split-package:=merge-first
+                        </Export-Package>
+                        <Import-Package>
+			   javax.servlet*;version="[2,4)",
+                           org.eclipse.jetty*;version="[8,10)",
+                           *
+			</Import-Package>
+                        <Bundle-NativeCode>*</Bundle-NativeCode>
+                    </instructions>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+</project>

http://git-wip-us.apache.org/repos/asf/servicemix-bundles/blob/792496bc/sparkjava-core-2.1/src/main/resources/OSGI-INF/bundle.info
----------------------------------------------------------------------
diff --git a/sparkjava-core-2.1/src/main/resources/OSGI-INF/bundle.info b/sparkjava-core-2.1/src/main/resources/OSGI-INF/bundle.info
new file mode 100644
index 0000000..bef47ce
--- /dev/null
+++ b/sparkjava-core-2.1/src/main/resources/OSGI-INF/bundle.info
@@ -0,0 +1,11 @@
+\u001B[1mSYNOPSIS\u001B[0m
+    ${project.description}
+
+    Original Maven URL:
+        \u001B[33mmvn:${pkgGroupId}/${pkgArtifactId}/${pkgVersion}\u001B[0m
+
+\u001B[1mDESCRIPTION\u001B[0m
+    A Sinatra inspired java web framework
+
+\u001B[1mSEE ALSO\u001B[0m
+    \u001B[36mhttp://sparkjava.com/\u001B[0m