diff options
-rwxr-xr-x | fork.sh | 2 | ||||
-rw-r--r-- | server/pom.xml | 1 | ||||
-rw-r--r-- | server/sonar-server/pom.xml | 39 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/Connectors.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/Connectors.java) | 0 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/EmbeddedTomcat.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/EmbeddedTomcat.java) | 0 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/Logging.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/Logging.java) | 0 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/NullJarScanner.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/NullJarScanner.java) | 0 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/ServerProcess.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/ServerProcess.java) | 0 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/Webapp.java (renamed from server/sonar-server-app/src/main/java/org/sonar/server/app/Webapp.java) | 14 | ||||
-rw-r--r-- | server/sonar-server/src/main/java/org/sonar/server/app/package-info.java | 24 | ||||
-rw-r--r-- | server/sonar-web/pom.xml | 10 | ||||
-rw-r--r-- | server/sonar-web/src/main/webapp/META-INF/context.xml | 4 | ||||
-rw-r--r-- | sonar-application/assembly.xml | 21 | ||||
-rw-r--r-- | sonar-application/pom.xml | 8 | ||||
-rw-r--r-- | sonar-batch-protocol/pom.xml | 5 |
15 files changed, 93 insertions, 35 deletions
@@ -1,6 +1,6 @@ #!/bin/sh -mvn clean install -DskipTests -Denforcer.skip=true -pl server/sonar-search,server/sonar-process,server/sonar-server-app,server/sonar-server-app,sonar-application +mvn clean install -DskipTests -Denforcer.skip=true -pl server/sonar-search,server/sonar-process,sonar-application if [[ "$OSTYPE" == "darwin"* ]]; then OS='macosx-universal-64' diff --git a/server/pom.xml b/server/pom.xml index b26febac729..131d3efcbcd 100644 --- a/server/pom.xml +++ b/server/pom.xml @@ -14,7 +14,6 @@ <module>sonar-process</module> <module>sonar-search</module> <module>sonar-server</module> - <module>sonar-server-app</module> <module>sonar-web</module> <module>sonar-ws-client</module> </modules> diff --git a/server/sonar-server/pom.xml b/server/sonar-server/pom.xml index 1665e581eb8..92c5dbaf7d6 100644 --- a/server/sonar-server/pom.xml +++ b/server/sonar-server/pom.xml @@ -14,6 +14,39 @@ <dependencies> <dependency> + <groupId>org.slf4j</groupId> + <artifactId>jul-to-slf4j</artifactId> + </dependency> + <dependency> + <groupId>ch.qos.logback</groupId> + <artifactId>logback-access</artifactId> + </dependency> + <dependency> + <groupId>ch.qos.logback</groupId> + <artifactId>logback-classic</artifactId> + </dependency> + <dependency> + <groupId>ch.qos.logback</groupId> + <artifactId>logback-core</artifactId> + </dependency> + <dependency> + <groupId>org.apache.tomcat.embed</groupId> + <artifactId>tomcat-embed-core</artifactId> + </dependency> + <dependency> + <groupId>org.apache.tomcat.embed</groupId> + <artifactId>tomcat-embed-jasper</artifactId> + </dependency> + <dependency> + <groupId>org.apache.tomcat.embed</groupId> + <artifactId>tomcat-embed-logging-juli</artifactId> + </dependency> + <dependency> + <groupId>dom4j</groupId> + <artifactId>dom4j</artifactId> + <version>1.6.1</version> + </dependency> + <dependency> <groupId>com.google.code.gson</groupId> <artifactId>gson</artifactId> </dependency> @@ -149,12 +182,6 @@ <artifactId>elasticsearch</artifactId> </dependency> <dependency> - <groupId>org.apache.tomcat.embed</groupId> - <artifactId>tomcat-embed-core</artifactId> - <version>7.0.42</version> - <scope>provided</scope> - </dependency> - <dependency> <groupId>com.google.code.findbugs</groupId> <artifactId>jsr305</artifactId> <scope>provided</scope> diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/Connectors.java b/server/sonar-server/src/main/java/org/sonar/server/app/Connectors.java index 13276f34dbf..13276f34dbf 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/Connectors.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/Connectors.java diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/EmbeddedTomcat.java b/server/sonar-server/src/main/java/org/sonar/server/app/EmbeddedTomcat.java index 50239fe282d..50239fe282d 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/EmbeddedTomcat.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/EmbeddedTomcat.java diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/Logging.java b/server/sonar-server/src/main/java/org/sonar/server/app/Logging.java index a4d1aaeec28..a4d1aaeec28 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/Logging.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/Logging.java diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/NullJarScanner.java b/server/sonar-server/src/main/java/org/sonar/server/app/NullJarScanner.java index 4f8ac9e5312..4f8ac9e5312 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/NullJarScanner.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/NullJarScanner.java diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/ServerProcess.java b/server/sonar-server/src/main/java/org/sonar/server/app/ServerProcess.java index 35c9aba1e8f..35c9aba1e8f 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/ServerProcess.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/ServerProcess.java diff --git a/server/sonar-server-app/src/main/java/org/sonar/server/app/Webapp.java b/server/sonar-server/src/main/java/org/sonar/server/app/Webapp.java index 5ad563df59c..1120f10230a 100644 --- a/server/sonar-server-app/src/main/java/org/sonar/server/app/Webapp.java +++ b/server/sonar-server/src/main/java/org/sonar/server/app/Webapp.java @@ -20,11 +20,11 @@ package org.sonar.server.app; import org.apache.catalina.Context; +import org.apache.catalina.core.StandardContext; import org.apache.catalina.startup.Tomcat; import org.slf4j.LoggerFactory; import org.sonar.process.Props; -import java.io.File; import java.util.Map; class Webapp { @@ -36,8 +36,16 @@ class Webapp { static void configure(Tomcat tomcat, Props props) { try { String webDir = props.of("sonar.path.web"); - Context context = tomcat.addWebapp(getContextPath(props), webDir); - context.setConfigFile(new File(webDir, "META-INF/context.xml").toURI().toURL()); + StandardContext context = (StandardContext) tomcat.addWebapp(getContextPath(props), webDir); + context.setReloadable(false); + context.setUseHttpOnly(true); + context.setProcessTlds(false); + context.setTldValidation(false); + context.setTldNamespaceAware(false); + context.setXmlValidation(false); + context.setXmlNamespaceAware(false); + context.setUseNaming(false); + context.setDelegate(true); for (Map.Entry<Object, Object> entry : props.cryptedProperties().entrySet()) { String key = entry.getKey().toString(); if (key.startsWith("sonar.")) { diff --git a/server/sonar-server/src/main/java/org/sonar/server/app/package-info.java b/server/sonar-server/src/main/java/org/sonar/server/app/package-info.java new file mode 100644 index 00000000000..5cccec43c1b --- /dev/null +++ b/server/sonar-server/src/main/java/org/sonar/server/app/package-info.java @@ -0,0 +1,24 @@ +/* + * SonarQube, open source software quality management tool. + * Copyright (C) 2008-2014 SonarSource + * mailto:contact AT sonarsource DOT com + * + * SonarQube is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 3 of the License, or (at your option) any later version. + * + * SonarQube is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ + +@ParametersAreNonnullByDefault +package org.sonar.server.app; + +import javax.annotation.ParametersAreNonnullByDefault; diff --git a/server/sonar-web/pom.xml b/server/sonar-web/pom.xml index 6e3ed52fcf7..881f84e83f1 100644 --- a/server/sonar-web/pom.xml +++ b/server/sonar-web/pom.xml @@ -1,5 +1,6 @@ <?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"> +<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"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>org.codehaus.sonar</groupId> @@ -19,13 +20,6 @@ <sonar.exclusions>src/main/js/third-party/**/*,src/main/js/require.js,src/main/js/tests/**/*</sonar.exclusions> </properties> - <dependencies> - <dependency> - <groupId>org.codehaus.sonar</groupId> - <artifactId>sonar-server</artifactId> - <version>${project.version}</version> - </dependency> - </dependencies> <build> <resources> <resource> diff --git a/server/sonar-web/src/main/webapp/META-INF/context.xml b/server/sonar-web/src/main/webapp/META-INF/context.xml deleted file mode 100644 index db181e0854e..00000000000 --- a/server/sonar-web/src/main/webapp/META-INF/context.xml +++ /dev/null @@ -1,4 +0,0 @@ -<Context useHttpOnly="true" reloadable="false" processTlds="false" - useNaming="false" xmlValidation="false" xmlNamespaceAware="false" tldValidation="false" - tldNamespaceAware="false"> -</Context> diff --git a/sonar-application/assembly.xml b/sonar-application/assembly.xml index 2304815d061..50553043ab1 100644 --- a/sonar-application/assembly.xml +++ b/sonar-application/assembly.xml @@ -38,8 +38,7 @@ <exclude>org.postgresql:postgresql</exclude> <exclude>net.sourceforge.jtds:jtds</exclude> <exclude>tanukisoft:wrapper</exclude> - <exclude>tanukisoft:wrapper</exclude> - <exclude>org.codehaus.sonar:sonar-server-app</exclude> + <exclude>org.codehaus.sonar:sonar-server</exclude> <exclude>org.codehaus.sonar:sonar-web</exclude> <exclude>org.codehaus.sonar:sonar-search</exclude> <exclude>org.codehaus.sonar.plugins:*</exclude> @@ -49,12 +48,24 @@ <scope>runtime</scope> </dependencySet> + <dependencySet> + <outputDirectory>lib/common</outputDirectory> + <useTransitiveFiltering>true</useTransitiveFiltering> + <useProjectArtifact>false</useProjectArtifact> + <includes> + <include>org.elasticsearch:elasticsearch</include> + </includes> + <scope>provided</scope> + </dependencySet> + + + <dependencySet> <outputDirectory>lib/search</outputDirectory> <useProjectArtifact>false</useProjectArtifact> <useTransitiveDependencies>true</useTransitiveDependencies> - <useTransitiveFiltering>true</useTransitiveFiltering> + <useTransitiveFiltering>false</useTransitiveFiltering> <includes> <include>org.codehaus.sonar:sonar-search</include> </includes> @@ -63,16 +74,16 @@ <dependencySet> <outputDirectory>lib/server</outputDirectory> + <useProjectArtifact>false</useProjectArtifact> <useTransitiveDependencies>true</useTransitiveDependencies> <useTransitiveFiltering>true</useTransitiveFiltering> <includes> - <include>org.codehaus.sonar:sonar-server-app</include> + <include>org.codehaus.sonar:sonar-server</include> </includes> <scope>provided</scope> </dependencySet> - <dependencySet> <outputDirectory>lib/batch</outputDirectory> <useTransitiveDependencies>false</useTransitiveDependencies> diff --git a/sonar-application/pom.xml b/sonar-application/pom.xml index 52ec763c1e4..b9a5d8afa09 100644 --- a/sonar-application/pom.xml +++ b/sonar-application/pom.xml @@ -31,10 +31,15 @@ <artifactId>jsr305</artifactId> <scope>provided</scope> </dependency> + <dependency> + <groupId>org.elasticsearch</groupId> + <artifactId>elasticsearch</artifactId> + <scope>provided</scope> + </dependency> <dependency> <groupId>org.codehaus.sonar</groupId> - <artifactId>sonar-server-app</artifactId> + <artifactId>sonar-server</artifactId> <version>${project.version}</version> <scope>provided</scope> </dependency> @@ -195,7 +200,6 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> - <version>2.5</version> <configuration> <archive> <index>true</index> diff --git a/sonar-batch-protocol/pom.xml b/sonar-batch-protocol/pom.xml index e596ef0ab90..35cc8af069a 100644 --- a/sonar-batch-protocol/pom.xml +++ b/sonar-batch-protocol/pom.xml @@ -14,11 +14,6 @@ <dependencies> <dependency> - <groupId>com.esotericsoftware.kryo</groupId> - <artifactId>kryo</artifactId> - <version>2.24.0</version> - </dependency> - <dependency> <groupId>com.google.code.gson</groupId> <artifactId>gson</artifactId> </dependency> |