Smalyshev has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/223208

Change subject: T104930: build all blazegraph parts into single war
......................................................................

T104930: build all blazegraph parts into single war

Change-Id: Ic86eac90be34bc279de6cbb2bb9a0c7aaebc86bf
---
M dist/pom.xml
M dist/src/assembly/dist.xml
M pom.xml
A war/pom.xml
A war/src/assembly/dist.xml
R war/src/config/web.xml
R war/src/js/workbench.js
7 files changed, 150 insertions(+), 46 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/wikidata/query/rdf 
refs/changes/08/223208/1

diff --git a/dist/pom.xml b/dist/pom.xml
index d046346..382b75e 100644
--- a/dist/pom.xml
+++ b/dist/pom.xml
@@ -21,19 +21,10 @@
 
   <dependencies>
     <dependency>
-      <groupId>com.bigdata</groupId>
-      <artifactId>bigdata</artifactId>
-      <version>${blazegraph.version}</version>
-      <type>war</type>
-    </dependency>
-    <dependency>
       <groupId>org.wikidata.query.rdf</groupId>
-      <artifactId>common</artifactId>
-    </dependency>
-    <dependency>
-      <groupId>org.wikidata.query.rdf</groupId>
-      <artifactId>blazegraph</artifactId>
+      <artifactId>blazegraph-service</artifactId>
       <version>${project.parent.version}</version>
+      <type>war</type>
     </dependency>
     <dependency>
       <groupId>org.eclipse.jetty</groupId>
diff --git a/dist/src/assembly/dist.xml b/dist/src/assembly/dist.xml
index 89d0ec7..d05d80d 100644
--- a/dist/src/assembly/dist.xml
+++ b/dist/src/assembly/dist.xml
@@ -18,19 +18,6 @@
     </fileSet>
 
     <fileSet>
-      <outputDirectory>blazegraph/WEB-INF</outputDirectory>
-      <directory>${project.basedir}/src/config</directory>
-    </fileSet>
-
-    <fileSet>
-      <outputDirectory>blazegraph/html/js</outputDirectory>
-      <directory>${project.basedir}/src/gui</directory>
-      <includes>
-        <include>workbench.js</include>
-      </includes>
-    </fileSet>
-
-    <fileSet>
       <outputDirectory>lib</outputDirectory>
       <directory>${project.basedir}/../tools/target</directory>
       <includes>
@@ -53,24 +40,9 @@
   <dependencySets>
 
     <dependencySet>
-      <outputDirectory>blazegraph</outputDirectory>
-      <unpack>true</unpack>
+      <outputDirectory></outputDirectory>
       <includes>
-        <include>com.bigdata:bigdata:war</include>
-      </includes>
-       <unpackOptions>
-         <excludes>
-           <exclude>**/workbench.js</exclude>
-           <exclude>**/web.xml</exclude>
-         </excludes>
-        </unpackOptions>
-      <useProjectArtifact>false</useProjectArtifact>
-    </dependencySet>
-
-    <dependencySet>
-      <outputDirectory>blazegraph/WEB-INF/lib</outputDirectory>
-      <includes>
-        <include>${project.groupId}:*:jar</include>
+        <include>org.wikidata.query.rdf:blazegraph-service:war</include>
       </includes>
       <useProjectArtifact>false</useProjectArtifact>
     </dependencySet>
diff --git a/pom.xml b/pom.xml
index 49237a4..1f49201 100644
--- a/pom.xml
+++ b/pom.xml
@@ -35,6 +35,12 @@
       <email>nik9000+wikid...@gmail.com</email>
       <timezone>America/New York</timezone>
     </developer>
+    <developer>
+      <id>smalyshev</id>
+      <name>Stas Malyshev</name>
+      <email>smalsy...@wikimedia.org</email>
+      <timezone>America/Los Angeles</timezone>
+    </developer>
   </developers>
 
   <scm>
@@ -191,7 +197,7 @@
                 </excludes>
                 <!-- Use as many JVMs as the test runner wants to use. -->
                 <parallelism>auto</parallelism>
-                <!-- The listeners and balancers elements do three things: 1. 
Control how output is formatted during tests 
+                <!-- The listeners and balancers elements do three things: 1. 
Control how output is formatted during tests
                   2. Dump the report to the right spot 3. Log an 
"execution-hints" file that is used to balance the load when tests are forked. 
-->
                 <listeners>
                   <report-ant-xml mavenExtensions="true" 
dir="${project.build.directory}/surefire-reports" />
@@ -258,7 +264,7 @@
               </goals>
               <configuration>
                 <quiet>true</quiet>
-                <!-- We don't want Java 8's strict javadoc checking so we use 
this trick borrowed from dropwizard to turn 
+                <!-- We don't want Java 8's strict javadoc checking so we use 
this trick borrowed from dropwizard to turn
                   it off -->
                 <additionalparam>${javadoc.doclint.none}</additionalparam>
               </configuration>
@@ -327,7 +333,7 @@
                 
<signaturesFile>${project.parent.basedir}/src/build/forbidden/core.txt</signaturesFile>
               </signaturesFiles>
               <excludes>
-                <!-- Some portions of the project need access to System.out 
and things so we contain them in inner classes 
+                <!-- Some portions of the project need access to System.out 
and things so we contain them in inner classes
                   of this form. -->
                 <exclude>**/*$ForbiddenOk**.class</exclude>
               </excludes>
@@ -539,5 +545,32 @@
         </plugins>
       </build>
     </profile>
+    <profile>
+     <id>deploy-archiva</id>
+      <distributionManagement>
+       <repository>
+         <id>wikimedia.releases</id>
+         <name>Wikimedia Release Repository</name>
+         <url>https://archiva.wikimedia.org/repository/releases/</url>
+       </repository>
+       <snapshotRepository>
+         <id>wikimedia.snapshots</id>
+         <name>Wikimedia Snapshot Repository</name>
+         <url>https://archiva.wikimedia.org/repository/snapshots/</url>
+       </snapshotRepository>
+      </distributionManagement>
+      <build>
+        <plugins>
+          <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-surefire-plugin</artifactId>
+            <version>2.18.1</version>
+            <configuration>
+              <skipTests>true</skipTests>
+            </configuration>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
   </profiles>
 </project>
diff --git a/war/pom.xml b/war/pom.xml
new file mode 100644
index 0000000..386847a
--- /dev/null
+++ b/war/pom.xml
@@ -0,0 +1,60 @@
+<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>org.wikidata.query.rdf</groupId>
+    <artifactId>parent</artifactId>
+    <version>0.0.3-SNAPSHOT</version>
+  </parent>
+  <artifactId>blazegraph-service</artifactId>
+  <packaging>pom</packaging>
+
+  <name>Wikibase RDF Query Service</name>
+  <description>Service to host Wikidata RDF Query Service.</description>
+  <licenses>
+    <license>
+      <name>The Apache Software License, Version 2.0</name>
+      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
+      <distribution>repo</distribution>
+    </license>
+  </licenses>
+
+  <dependencies>
+    <dependency>
+      <groupId>com.bigdata</groupId>
+      <artifactId>bigdata</artifactId>
+      <version>${blazegraph.version}</version>
+      <type>war</type>
+    </dependency>
+    <dependency>
+      <groupId>org.wikidata.query.rdf</groupId>
+      <artifactId>common</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.wikidata.query.rdf</groupId>
+      <artifactId>blazegraph</artifactId>
+      <version>${project.parent.version}</version>
+    </dependency>
+  </dependencies>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-assembly-plugin</artifactId>
+        <configuration>
+          <descriptor>src/assembly/dist.xml</descriptor>
+        </configuration>
+        <executions>
+          <execution>
+            <phase>package</phase>
+            <goals>
+              <goal>single</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+
+</project>
diff --git a/war/src/assembly/dist.xml b/war/src/assembly/dist.xml
new file mode 100644
index 0000000..22177c6
--- /dev/null
+++ b/war/src/assembly/dist.xml
@@ -0,0 +1,49 @@
+<assembly 
xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0";
+          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
+          
xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.0
 http://maven.apache.org/xsd/assembly-1.1.0.xsd";>
+
+  <id>dist</id>
+  <includeBaseDirectory>false</includeBaseDirectory>
+
+  <formats>
+    <format>war</format>
+  </formats>
+
+  <fileSets>
+    <fileSet>
+      <outputDirectory>WEB-INF</outputDirectory>
+      <directory>${project.basedir}/src/config</directory>
+    </fileSet>
+
+    <fileSet>
+      <outputDirectory>html/js</outputDirectory>
+      <directory>${project.basedir}/src/js</directory>
+    </fileSet>
+  </fileSets>
+
+  <dependencySets>
+    <dependencySet>
+      <outputDirectory></outputDirectory>
+      <unpack>true</unpack>
+      <includes>
+        <include>com.bigdata:bigdata:war</include>
+      </includes>
+       <unpackOptions>
+         <excludes>
+           <exclude>**/workbench.js</exclude>
+           <exclude>**/web.xml</exclude>
+         </excludes>
+        </unpackOptions>
+      <useProjectArtifact>false</useProjectArtifact>
+    </dependencySet>
+
+    <dependencySet>
+      <outputDirectory>WEB-INF/lib</outputDirectory>
+      <includes>
+        <include>${project.groupId}:*:jar</include>
+      </includes>
+      <useProjectArtifact>false</useProjectArtifact>
+    </dependencySet>
+  </dependencySets>
+
+</assembly>
diff --git a/dist/src/config/web.xml b/war/src/config/web.xml
similarity index 98%
rename from dist/src/config/web.xml
rename to war/src/config/web.xml
index 42e2754..0996785 100644
--- a/dist/src/config/web.xml
+++ b/war/src/config/web.xml
@@ -24,8 +24,7 @@
    <!-- the servlet container. The "ant war" target rewrites this to be -->
    <!-- relative to the root of the servlet container by default.       -->
    <param-name>propertyFile</param-name>
-   <!-- from blazegraph/WEB-INF/ -->
-   <param-value>../../RWStore.properties</param-value>
+   <param-value>RWStore.properties</param-value>
   </context-param>
   <context-param>
    <description>The default bigdata namespace of for the triple or quad store
diff --git a/dist/src/gui/workbench.js b/war/src/js/workbench.js
similarity index 100%
rename from dist/src/gui/workbench.js
rename to war/src/js/workbench.js

-- 
To view, visit https://gerrit.wikimedia.org/r/223208
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ic86eac90be34bc279de6cbb2bb9a0c7aaebc86bf
Gerrit-PatchSet: 1
Gerrit-Project: wikidata/query/rdf
Gerrit-Branch: master
Gerrit-Owner: Smalyshev <smalys...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to