JBoss Native SVN: r2789 - trunk/build/unix.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-28 18:01:56 -0400 (Sat, 28 May 2011)
New Revision: 2789
Modified:
trunk/build/unix/package.list
Log:
Oops it is not a tag but a branch.
Modified: trunk/build/unix/package.list
===================================================================
--- trunk/build/unix/package.list 2011-05-27 15:31:48 UTC (rev 2788)
+++ trunk/build/unix/package.list 2011-05-28 22:01:56 UTC (rev 2789)
@@ -54,6 +54,6 @@
mod_cluster|1.1.2.dev|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:trunk
mod_cluster|1.0.10.GA|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:1.0.10.GA
mod_cluster|1.1.2.Final|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:1.1.2.Final
-mod_cluster|1.0.10.CP|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:MOD_CLUSTER_1_0_10_GA_CP
+mod_cluster|1.0.10.CP|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:branches/MOD_CLUSTER_1_0_10_GA_CP
traffic_server|TS_Trunk|trunk
TC7|TC7_Trunk|trunk
13 years, 7 months
JBoss Native SVN: r2788 - in trunk/build/unix/util: jbosswebtests and 1 other directory.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-27 11:31:48 -0400 (Fri, 27 May 2011)
New Revision: 2788
Modified:
trunk/build/unix/util/jbossweb/build.sh
trunk/build/unix/util/jbosswebtests/pom.xml
Log:
Add parameter for the -d32 or -d64.
Modified: trunk/build/unix/util/jbossweb/build.sh
===================================================================
--- trunk/build/unix/util/jbossweb/build.sh 2011-05-27 15:05:32 UTC (rev 2787)
+++ trunk/build/unix/util/jbossweb/build.sh 2011-05-27 15:31:48 UTC (rev 2788)
@@ -61,6 +61,15 @@
shift
done
+mvn install || exit 1
+
+(cd ../jbosswebtests
+ if $force_64; then
+ mvn -Djvmsize=64 install || exit 1
+ else
+ mvn -Djvmsize=32 install || exit 1
+) || exit 1
+
echo ""
echo "SUCCESS : `basename $0` $LastChangedDate: 2011-05-06 16:35:58 +0200 (Fri, 06 May 2011) $"
echo ""
Modified: trunk/build/unix/util/jbosswebtests/pom.xml
===================================================================
--- trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-27 15:05:32 UTC (rev 2787)
+++ trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-27 15:31:48 UTC (rev 2788)
@@ -78,6 +78,7 @@
<!-- Start jbossweb (embedded) -->
<java classname="org.jboss.test.StartJBossWeb"
spawn="true" fork="yes">
+ <jvmarg line="-d${jvmsize}" />
<jvmarg line="-Djava.util.logging.config.file=node1/conf/logging.properties" />
<jvmarg line="-Djava.util.logging.manager=org.jboss.test.ClassLoaderLogManager"/>
<classpath refid="maven.test.classpath"/>
13 years, 7 months
JBoss Native SVN: r2787 - trunk/build/unix.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-27 11:05:32 -0400 (Fri, 27 May 2011)
New Revision: 2787
Removed:
trunk/build/unix/buildtest.jboss-native.windows.sh
Modified:
trunk/build/unix/buildtest.jboss-native.sh
Log:
Arrange the test to use the new logic.
Modified: trunk/build/unix/buildtest.jboss-native.sh
===================================================================
--- trunk/build/unix/buildtest.jboss-native.sh 2011-05-27 14:33:14 UTC (rev 2786)
+++ trunk/build/unix/buildtest.jboss-native.sh 2011-05-27 15:05:32 UTC (rev 2787)
@@ -31,63 +31,13 @@
build_cache_dir=$3
IPLOCAL=$4
-# Copy java
-if [ ! -d ${base}/${root}/${JAVA_HOME} ]; then
- mkdir -p ${base}/${root}/`dirname ${JAVA_HOME}`
- cp -rp $JAVA_HOME ${base}/${root}/${JAVA_HOME}
-fi
-
-# Install jbossas
-URL=http://surfnet.dl.sourceforge.net/sourceforge/jboss/jboss-4.2.0.GA.zip
-FILE=`basename $URL`
-mkdir -p $build_cache_dir
-if [ ! -f ${build_cache_dir}/$FILE ]; then
- (cd ${build_cache_dir}
- wget --tries=0 --retry-connrefused $URL
- )
-fi
-mkdir ${base}/${root}/jbossas
-(cd ${base}/${root}/jbossas
-unzip ${build_cache_dir}/${FILE}
+# Build the big native packages
+(cd $base/util/jbossweb
+ bash files.sh
+ mvn install
)
-JBOSSDIR=`ls ${base}/${root}/jbossas`
-# Copy the package to test.
-cp -rp ${root}/bin ${base}/${root}/jbossas/${JBOSSDIR}
-
-# Add the right JAVA_HOME
-echo "JAVA_HOME=$JAVA_HOME" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/run.conf
-echo "export JAVA_HOME" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/run.conf
-
-# Add LD_LIBRARY_PATH
-echo "LD_LIBRARY_PATH=/jbossas/${JBOSSDIR}/bin/native" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/run.conf
-echo "export LD_LIBRARY_PATH" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/run.conf
-
-# Create our shutdown wrapper.
-echo "#!/bin/sh" > ${base}/${root}/jbossas/${JBOSSDIR}/bin/jshutdown.sh
-echo "DIRNAME=\`dirname \$0\`" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/jshutdown.sh
-echo ". \$DIRNAME/run.conf" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/jshutdown.sh
-echo "\$DIRNAME/shutdown.sh -S -s $IPLOCAL" >> ${base}/${root}/jbossas/${JBOSSDIR}/bin/jshutdown.sh
-chmod a+x ${base}/${root}/jbossas/${JBOSSDIR}/bin/jshutdown.sh
-
-# start the jboss
-echo "Doing CHROOT in ${base}/${root}"
-sudo /usr/sbin/chroot ${base}/${root} jbossas/${JBOSSDIR}/bin/run.sh -b ${IPLOCAL} > ${base}/${root}/jboss.out.txt &
-sleep 60
-
-grep "APR capabilities:" ${base}/${root}/jboss.out.txt
-if [ $? -ne 0 ]; then
- sudo /usr/sbin/chroot ${base}/${root} jbossas/${JBOSSDIR}/bin/jshutdown.sh
- echo "Failed APR not loaded"
- exit 1
-fi
-
-curl -v http://${IPLOCAL}:8080/ | grep "Welcome to JBoss" 2>/dev/null
-if [ $? -ne 0 ]; then
- sudo /usr/sbin/chroot ${base}/${root} jbossas/${JBOSSDIR}/bin/jshutdown.sh
- echo "Failed Connection doesn't work"
- exit 1
-fi
-
-# Stop the jboss
-sudo /usr/sbin/chroot ${base}/${root} jbossas/${JBOSSDIR}/bin/jshutdown.sh
+# Run the tests
+(cd $base/util/jbosswebtest
+ mvn install
+)
Deleted: trunk/build/unix/buildtest.jboss-native.windows.sh
===================================================================
--- trunk/build/unix/buildtest.jboss-native.windows.sh 2011-05-27 14:33:14 UTC (rev 2786)
+++ trunk/build/unix/buildtest.jboss-native.windows.sh 2011-05-27 15:05:32 UTC (rev 2787)
@@ -1,32 +0,0 @@
-#!/bin/sh
-# Copyright(c) 2008 Red Hat Middleware, LLC,
-# and individual contributors as indicated by the @authors tag.
-# See the copyright.txt in the distribution for a
-# full listing of individual contributors.
-#
-# This library 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 2 of the License, or (at your option) any later version.
-#
-# This library 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 library in the file COPYING.LIB;
-# if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
-#
-# @author Jean-Frederic Clere
-#
-#
-# Run a test of the jbossweb native components.
-#
-base=$1
-root=$2
-build_cache_dir=$3
-IPLOCAL=$4
-
-echo "Not yet supported platform"
13 years, 7 months
JBoss Native SVN: r2786 - in trunk/build/unix/util/jbosswebtests: src/main/java/org/jboss/test and 1 other directory.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-27 10:33:14 -0400 (Fri, 27 May 2011)
New Revision: 2786
Added:
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StopJBossWeb.java
Modified:
trunk/build/unix/util/jbosswebtests/pom.xml
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
Log:
Arrange the logic to get the test working.
Modified: trunk/build/unix/util/jbosswebtests/pom.xml
===================================================================
--- trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-27 12:01:18 UTC (rev 2785)
+++ trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-27 14:33:14 UTC (rev 2786)
@@ -76,14 +76,15 @@
<unjar src="${org.jboss.as:jbossweb-native:jar}" dest="node1" />
<!-- Start jbossweb (embedded) -->
- <java dir="node1" classname="org.jboss.test.StartJBossWeb"
+ <java classname="org.jboss.test.StartJBossWeb"
spawn="true" fork="yes">
- <arg line="${line}"/>
<jvmarg line="-Djava.util.logging.config.file=node1/conf/logging.properties" />
<jvmarg line="-Djava.util.logging.manager=org.jboss.test.ClassLoaderLogManager"/>
<classpath refid="maven.test.classpath"/>
</java>
+ <sleep seconds="10"/>
+
<!-- Test it -->
<delete file="index.html"/>
<exec executable="wget">
@@ -93,6 +94,11 @@
<available file="index.html" property="exist"/>
<fail unless="exist" message="Can't get test file"/>
+ <java classname="org.jboss.test.StopJBossWeb"
+ spawn="true" fork="yes">
+ <classpath refid="maven.test.classpath"/>
+ </java>
+
</tasks>
</configuration>
<goals>
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-27 12:01:18 UTC (rev 2785)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-27 14:33:14 UTC (rev 2786)
@@ -32,14 +32,20 @@
import java.io.IOException;
import java.io.FileInputStream;
import java.io.FileOutputStream;
+import java.lang.reflect.InvocationTargetException;
+import javax.naming.NamingException;
+
+import org.apache.catalina.startup.ContextConfig;
import org.apache.catalina.startup.Embedded;
import org.apache.catalina.*;
import org.apache.catalina.connector.Connector;
import org.apache.catalina.core.*;
import org.apache.catalina.startup.HostConfig;
+import org.apache.tomcat.InstanceManager;
+import org.apache.tomcat.util.IntrospectionUtils;
-public class JBossWeb extends Embedded {
+public class JBossWeb extends StandardService {
private String route = null;
@@ -57,12 +63,12 @@
public JBossWeb(String route, String host, boolean nat, String webapp, String[] Aliases) throws IOException {
- setCatalinaBase(route);
- setCatalinaHome(route);
+ System.setProperty( "catalina.base", route);
+ System.setProperty( "catalina.home", route);
this.route = route;
//Create an Engine
- StandardEngine baseEngine = (StandardEngine) createEngine();
+ StandardEngine baseEngine = new StandardEngine();
baseEngine.setName(host + "Engine" + route);
baseEngine.setDefaultHost(host);
@@ -72,7 +78,8 @@
// Create node1/webapps/ROOT and index.html
File fd = new File ( route + "/webapps/" + webapp);
- fd.mkdirs();
+ if (!fd.exists())
+ fd.mkdirs();
String docBase = fd.getAbsolutePath();
String appBase = fd.getParent();
fd = new File (route + "/webapps/" + webapp, "index.html");
@@ -81,7 +88,9 @@
out.close();
//Create Host
- Host baseHost = createHost( host, appBase);
+ StandardHost baseHost = new StandardHost();
+ baseHost.setAppBase(appBase);
+ baseHost.setName(host);
baseHost.setBackgroundProcessorDelay(1);
StandardHost stdhost = (StandardHost)baseHost;
stdhost.setConfigClass("org.apache.catalina.startup.ContextConfig");
@@ -95,30 +104,37 @@
baseEngine.addChild( baseHost );
//Create default context
- Context rootContext;
+ StandardContext rootContext;
if (webapp.equals("ROOT"))
- rootContext = createContext("/",docBase );
+ rootContext = createContext("",docBase );
else
rootContext = createContext("/" + webapp, docBase );
rootContext.setIgnoreAnnotations(true);
rootContext.setPrivileged(true);
+ rootContext.setInstanceManager(new LocalInstanceManager());
+ rootContext.setReplaceWelcomeFiles(true);
+ rootContext.addWelcomeFile("index.html");
+ rootContext.addMimeMapping("html", "text/html");
Wrapper wrapper = rootContext.createWrapper();
wrapper.setName("default");
wrapper.setServletClass("org.apache.catalina.servlets.DefaultServlet");
+ wrapper.setLoadOnStartup(0);
rootContext.addChild(wrapper);
rootContext.addServletMapping("/", "default");
+ ContextConfig config = new ContextConfig();
+ rootContext.addLifecycleListener(config);
baseHost.addChild( rootContext );
- addEngine( baseEngine );
+ setContainer( baseEngine );
baseEngine.setService(this);
this.setName(host + "Engine" + route);
}
- private Context createContext(String string, String docBase) {
+ private StandardContext createContext(String path, String docBase) {
StandardContext context = new StandardContext();
context.setDocBase(docBase);
- context.setPath(string);
- return context;
+ context.setPath(path);
+ return context;
}
void AddContext(String path, String docBase, String servletname, boolean wait) {
@@ -183,30 +199,45 @@
copyFile(fdin, fd);
}
- public Connector addConnector(int port) throws IOException {
- return addConnector(port, "https");
- }
-
- public Connector addConnector(int port, String scheme) throws IOException {
- return addConnector(port, scheme, null);
- }
-
- public Connector addConnector(int port, String scheme, String address) throws IOException {
+ public void addConnector(int port, String scheme) throws Exception {
- Connector connector = createConnector( address,
- port, scheme);
+ Connector connector = new Connector("http");
+ connector.setPort(port);
/* Set the SSL properties */
connector.setProperty("SSLCertificateFile", "newcert.pem");
connector.setProperty("SSLCertificateKeyFile", "newkey.pem");
connector.setProperty("SSLPassword", "changeit");
- connector.setProperty("SLEnabled", "true");
+ connector.setProperty("SSLEnabled", "true");
connector.setSecure(true);
connector.setScheme(scheme);
// Look in StandardService to see why it works ;-)
addConnector( connector );
+ }
+ private static class LocalInstanceManager implements InstanceManager {
+ @Override
+ public Object newInstance(String className) throws IllegalAccessException, InvocationTargetException, NamingException, InstantiationException, ClassNotFoundException {
+ return Class.forName(className).newInstance();
+ }
- return connector;
+ @Override
+ public Object newInstance(String fqcn, ClassLoader classLoader) throws IllegalAccessException, InvocationTargetException, NamingException, InstantiationException, ClassNotFoundException {
+ return Class.forName(fqcn, false, classLoader).newInstance();
+ }
+
+ @Override
+ public Object newInstance(Class<?> c) throws IllegalAccessException, InvocationTargetException, NamingException, InstantiationException {
+ return c.newInstance();
+ }
+
+ @Override
+ public void newInstance(Object o) throws IllegalAccessException, InvocationTargetException, NamingException {
+ throw new IllegalStateException();
+ }
+
+ @Override
+ public void destroyInstance(Object o) throws IllegalAccessException, InvocationTargetException {
+ }
}
}
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-27 12:01:18 UTC (rev 2785)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-27 14:33:14 UTC (rev 2786)
@@ -51,6 +51,10 @@
public class StartJBossWeb {
+ static {
+ System.setProperty( "catalina.base", "node1"); // Log :D
+ }
+
private static Logger log = Logger.getLogger(StartJBossWeb.class);
private static String address = "localhost";
private static String shutdown = "SHUTDOWN";
Added: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StopJBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StopJBossWeb.java (rev 0)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StopJBossWeb.java 2011-05-27 14:33:14 UTC (rev 2786)
@@ -0,0 +1,47 @@
+/*
+ * mod_cluster
+ *
+ * Copyright(c) 2011 Red Hat Middleware, LLC,
+ * and individual contributors as indicated by the @authors tag.
+ * See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This library 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 2 of the License, or (at your option) any later version.
+ *
+ * This library 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 library in the file COPYING.LIB;
+ * if not, write to the Free Software Foundation, Inc.,
+ * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+ *
+ * @author Jean-Frederic Clere
+ * @version $Revision$
+ */
+
+package org.jboss.test;
+
+import java.io.PrintWriter;
+import java.net.Socket;
+
+public class StopJBossWeb {
+ public static void main(String[] args) {
+ // Stop JBossWeb.
+ try {
+ Socket clientSocket = new Socket ("localhost", 8005);
+ PrintWriter out = new PrintWriter(clientSocket.getOutputStream(), true);
+ out.println("SHUTDOWN");
+ out.close();
+ } catch (Exception e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ }
+
+}
13 years, 7 months
JBoss Native SVN: r2785 - trunk/build/unix.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-27 08:01:18 -0400 (Fri, 27 May 2011)
New Revision: 2785
Modified:
trunk/build/unix/package.list
Log:
Try latest patch.
Modified: trunk/build/unix/package.list
===================================================================
--- trunk/build/unix/package.list 2011-05-18 14:59:50 UTC (rev 2784)
+++ trunk/build/unix/package.list 2011-05-27 12:01:18 UTC (rev 2785)
@@ -54,5 +54,6 @@
mod_cluster|1.1.2.dev|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:trunk
mod_cluster|1.0.10.GA|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:1.0.10.GA
mod_cluster|1.1.2.Final|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:1.1.2.Final
+mod_cluster|1.0.10.CP|2.2.15|ssl:v:0.9.8k|zlib:v:1.2.3|jk:v:1.2.30|iconv:v:1.11|expat:v:1.95.8|cluster:t:MOD_CLUSTER_1_0_10_GA_CP
traffic_server|TS_Trunk|trunk
TC7|TC7_Trunk|trunk
13 years, 7 months
JBoss Native SVN: r2784 - trunk/build/unix.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-18 10:59:50 -0400 (Wed, 18 May 2011)
New Revision: 2784
Modified:
trunk/build/unix/buildbin.TC7.sh
Log:
Stop TC7 if one of tests fails.
Modified: trunk/build/unix/buildbin.TC7.sh
===================================================================
--- trunk/build/unix/buildbin.TC7.sh 2011-05-12 16:11:01 UTC (rev 2783)
+++ trunk/build/unix/buildbin.TC7.sh 2011-05-18 14:59:50 UTC (rev 2784)
@@ -170,8 +170,19 @@
echo ""
export TS_HOME=/home/hudson/tcks/servlet/servlettck
export ANT_HOME=$TS_HOME/tools/ant
-(cd $TS_HOME/bin; ant run.all || exit 1) || exit 1
-(cd $TS_HOME/bin; ant report || exit 1) || exit 1
+(cd $TS_HOME/bin; ant run.all || exit 1)
+if [ $? -ne 0 ]; then
+ echo "Failed test failed..."
+ (cd $native_sources/output/build; bin/shutdown.sh)
+ exit 1
+else
+ (cd $TS_HOME/bin; ant report || exit 1)
+ if [ $? -ne 0 ]; then
+ echo "Failed build test report failed..."
+ (cd $native_sources/output/build; bin/shutdown.sh)
+ exit 1
+ fi
+fi
echo ""
echo "Stopping TC7..."
13 years, 7 months
JBoss Native SVN: r2783 - in trunk/build/unix/util: jbossweb/node1/conf and 4 other directories.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-12 12:11:01 -0400 (Thu, 12 May 2011)
New Revision: 2783
Added:
trunk/build/unix/util/jbosswebtests/cacert.pem
trunk/build/unix/util/jbosswebtests/newcert.pem
trunk/build/unix/util/jbosswebtests/newkey.pem
trunk/build/unix/util/jbosswebtests/node1/
trunk/build/unix/util/jbosswebtests/node1/conf/
trunk/build/unix/util/jbosswebtests/node1/conf/logging.properties
Removed:
trunk/build/unix/util/jbossweb/cacert.pem
trunk/build/unix/util/jbossweb/newcert.pem
trunk/build/unix/util/jbossweb/newkey.pem
trunk/build/unix/util/jbossweb/node1/conf/logging.properties
Modified:
trunk/build/unix/util/jbossweb/files.sh
trunk/build/unix/util/jbosswebtests/pom.xml
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
Log:
Arrange more locations.
Deleted: trunk/build/unix/util/jbossweb/cacert.pem
===================================================================
--- trunk/build/unix/util/jbossweb/cacert.pem 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbossweb/cacert.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -1,18 +0,0 @@
------BEGIN CERTIFICATE-----
-MIIC3TCCAkagAwIBAgIBADANBgkqhkiG9w0BAQUFADB2MQswCQYDVQQGEwJDSDES
-MBAGA1UECBMJTmV1Y2hhdGVsMRAwDgYDVQQKEwdSZWQgSGF0MQ4wDAYDVQQLEwVq
-Ym9zczEOMAwGA1UEAxMFamZjcGMxITAfBgkqhkiG9w0BCQEWEmpmY2xlcmVAcmVk
-aGF0LmNvbTAeFw0wODEyMDIxMzU2MzdaFw0xMTEyMDIxMzU2MzdaMHYxCzAJBgNV
-BAYTAkNIMRIwEAYDVQQIEwlOZXVjaGF0ZWwxEDAOBgNVBAoTB1JlZCBIYXQxDjAM
-BgNVBAsTBWpib3NzMQ4wDAYDVQQDEwVqZmNwYzEhMB8GCSqGSIb3DQEJARYSamZj
-bGVyZUByZWRoYXQuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDBju4V
-GAwObduuScxhPHNvBWRbjU1DAiv00fwHh6nELVxwBsyzWOY4pcUBfrr3bNsJP9dd
-ZpGHqHA7kroLZxfyXTmF/C58a1HIhhzgS4rtijOFHOh5WLD0HZICPdCR1D1IznXx
-oAoMOQ/PeGCfiPVLWzwSqrg/GDW3vhTIRlTrpwIDAQABo3sweTAJBgNVHRMEAjAA
-MCwGCWCGSAGG+EIBDQQfFh1PcGVuU1NMIEdlbmVyYXRlZCBDZXJ0aWZpY2F0ZTAd
-BgNVHQ4EFgQU3P9xfJgsEC/jPhHgr5Wt3J8iCYAwHwYDVR0jBBgwFoAU3P9xfJgs
-EC/jPhHgr5Wt3J8iCYAwDQYJKoZIhvcNAQEFBQADgYEAJoT9AdqxQ/7ezw5sx6Fn
-DSJR7DtiXVHB8zChbev3aS36Dym4qiQBXgQ+hUe+AtnMDq3YNN7LGBP/a/eT76zs
-CWsKLfZq200wkQE/54fSxLGmapy6DQuh2Xtuw+oEjAlZVBruLMv9gOQ4Dg+DteRp
-cSlORuUwHEggjl3PakQc78Q=
------END CERTIFICATE-----
Modified: trunk/build/unix/util/jbossweb/files.sh
===================================================================
--- trunk/build/unix/util/jbossweb/files.sh 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbossweb/files.sh 2011-05-12 16:11:01 UTC (rev 2783)
@@ -100,18 +100,18 @@
esac
export TYPE
- mkdir -p src/main/resources/bin/native/${PLATFORM}
+ mkdir -p src/main/resources/bin/META-INF/lib/${PLATFORM}
echo $FILE
echo $BASE
wget http://hudson.qa.jboss.com/hudson/view/Native/job/${BASE}/lastSuccessfulB... || exit 1
if [ $HTTPFILE != $FILE ]; then
mv $HTTPFILE $FILE
fi
- (cd src/main/resources/bin/native
+ (cd src/main/resources/bin/META-INF/lib
if [ $TYPE = "tar" ]; then
- tar zxvf ../../../../../$FILE
+ tar zxvf ../../../../../../$FILE
else
- unzip -o ../../../../../$FILE
+ unzip -o ../../../../../../$FILE
fi
mv bin/native ${PLATFORM}/${CPU}
rm -rf bin
Deleted: trunk/build/unix/util/jbossweb/newcert.pem
===================================================================
--- trunk/build/unix/util/jbossweb/newcert.pem 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbossweb/newcert.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -1,73 +0,0 @@
-Certificate:
- Data:
- Version: 3 (0x2)
- Serial Number: 8 (0x8)
- Signature Algorithm: sha1WithRSAEncryption
- Issuer: C=CH, ST=Neuchatel, O=Red Hat, OU=jboss, CN=jfcpc/emailAddress=jfclere(a)redhat.com
- Validity
- Not Before: May 4 07:42:13 2011 GMT
- Not After : May 3 07:42:13 2012 GMT
- Subject: C=CH, ST=Neuchatel, L=Neuchatel, O=Red Hat, OU=jboss, CN=localhost/emailAddress=jfclere(a)jfclere.org
- Subject Public Key Info:
- Public Key Algorithm: rsaEncryption
- Public-Key: (2048 bit)
- Modulus:
- 00:d9:46:dc:a0:e0:b9:b1:2c:c8:83:55:ec:a4:06:
- 5b:ee:60:0a:c0:6f:28:4b:4d:97:39:06:5c:3d:b0:
- 32:d4:4e:d6:c7:3f:22:54:e2:a7:d9:e2:c7:9c:b9:
- b9:bd:1d:66:45:53:7e:3b:25:32:76:79:c9:c1:52:
- 91:bb:d3:02:b5:1c:70:a1:a3:e8:75:94:ea:ad:61:
- 36:a7:5e:c8:59:c2:7c:94:f5:17:46:6a:65:cc:c9:
- 2c:09:49:54:ee:73:60:ec:63:ec:92:56:22:60:fc:
- b5:46:ba:7c:ca:d3:f9:85:e5:7e:20:44:b1:4d:5e:
- 71:4b:84:07:11:23:ce:0c:70:55:14:f6:74:c6:ce:
- 34:18:d0:ae:e9:da:a0:0b:ca:98:0e:19:92:d2:d8:
- 4a:90:9a:62:da:90:5f:7a:d9:f7:ff:14:7b:41:6e:
- 8d:37:cc:a5:45:c2:18:b9:d9:99:0b:3d:ae:3d:fe:
- 9c:6a:25:06:b7:25:41:ad:c3:ac:c7:c7:4f:8c:d1:
- 81:2c:bd:f9:e4:7f:26:d3:5c:84:f4:da:2a:1d:0a:
- 6a:15:1b:e1:e2:c1:c8:ef:b4:4d:92:9d:b3:3c:c9:
- 8f:e0:b3:7e:94:12:c1:24:58:6f:87:38:11:2d:e3:
- c8:c6:0f:be:50:0c:de:3a:9e:ff:e9:64:51:65:64:
- 6a:db
- Exponent: 65537 (0x10001)
- X509v3 extensions:
- X509v3 Basic Constraints:
- CA:FALSE
- Netscape Comment:
- OpenSSL Generated Certificate
- X509v3 Subject Key Identifier:
- 39:CC:FF:65:7D:6D:F3:2D:6F:88:96:8D:ED:9A:A5:5A:BE:FE:EE:E4
- X509v3 Authority Key Identifier:
- keyid:DC:FF:71:7C:98:2C:10:2F:E3:3E:11:E0:AF:95:AD:DC:9F:22:09:80
-
- Signature Algorithm: sha1WithRSAEncryption
- ae:f3:48:4c:81:6f:5a:af:76:bb:88:85:f7:a7:5b:2e:14:57:
- 31:d5:04:cb:4d:97:88:24:bd:87:e4:24:05:10:6a:2b:4d:bd:
- 05:84:d7:f4:0a:3b:de:c7:ba:31:a8:22:c8:82:80:19:5f:f3:
- 2b:d5:1e:62:20:c3:87:4b:40:b2:f3:78:b4:ef:b3:7b:00:93:
- 9e:75:ea:6e:fd:e3:e2:55:6a:23:31:b9:2a:01:71:5f:a1:f2:
- f3:a5:0c:21:cd:1d:34:e1:b4:a4:47:ac:7b:2f:30:76:a6:85:
- 9c:0e:2b:e2:64:67:f7:14:e6:44:27:52:17:93:8d:e1:0a:41:
- 29:1c
------BEGIN CERTIFICATE-----
-MIIDezCCAuSgAwIBAgIBCDANBgkqhkiG9w0BAQUFADB2MQswCQYDVQQGEwJDSDES
-MBAGA1UECBMJTmV1Y2hhdGVsMRAwDgYDVQQKEwdSZWQgSGF0MQ4wDAYDVQQLEwVq
-Ym9zczEOMAwGA1UEAxMFamZjcGMxITAfBgkqhkiG9w0BCQEWEmpmY2xlcmVAcmVk
-aGF0LmNvbTAeFw0xMTA1MDQwNzQyMTNaFw0xMjA1MDMwNzQyMTNaMIGPMQswCQYD
-VQQGEwJDSDESMBAGA1UECAwJTmV1Y2hhdGVsMRIwEAYDVQQHDAlOZXVjaGF0ZWwx
-EDAOBgNVBAoMB1JlZCBIYXQxDjAMBgNVBAsMBWpib3NzMRIwEAYDVQQDDAlsb2Nh
-bGhvc3QxIjAgBgkqhkiG9w0BCQEWE2pmY2xlcmVAamZjbGVyZS5vcmcwggEiMA0G
-CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDZRtyg4LmxLMiDVeykBlvuYArAbyhL
-TZc5Blw9sDLUTtbHPyJU4qfZ4secubm9HWZFU347JTJ2ecnBUpG70wK1HHCho+h1
-lOqtYTanXshZwnyU9RdGamXMySwJSVTuc2DsY+ySViJg/LVGunzK0/mF5X4gRLFN
-XnFLhAcRI84McFUU9nTGzjQY0K7p2qALypgOGZLS2EqQmmLakF962ff/FHtBbo03
-zKVFwhi52ZkLPa49/pxqJQa3JUGtw6zHx0+M0YEsvfnkfybTXIT02iodCmoVG+Hi
-wcjvtE2SnbM8yY/gs36UEsEkWG+HOBEt48jGD75QDN46nv/pZFFlZGrbAgMBAAGj
-ezB5MAkGA1UdEwQCMAAwLAYJYIZIAYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVk
-IENlcnRpZmljYXRlMB0GA1UdDgQWBBQ5zP9lfW3zLW+Ilo3tmqVavv7u5DAfBgNV
-HSMEGDAWgBTc/3F8mCwQL+M+EeCvla3cnyIJgDANBgkqhkiG9w0BAQUFAAOBgQCu
-80hMgW9ar3a7iIX3p1suFFcx1QTLTZeIJL2H5CQFEGorTb0FhNf0Cjvex7oxqCLI
-goAZX/Mr1R5iIMOHS0Cy83i077N7AJOedepu/ePiVWojMbkqAXFfofLzpQwhzR00
-4bSkR6x7LzB2poWcDiviZGf3FOZEJ1IXk43hCkEpHA==
------END CERTIFICATE-----
Deleted: trunk/build/unix/util/jbossweb/newkey.pem
===================================================================
--- trunk/build/unix/util/jbossweb/newkey.pem 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbossweb/newkey.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -1,30 +0,0 @@
------BEGIN RSA PRIVATE KEY-----
-Proc-Type: 4,ENCRYPTED
-DEK-Info: DES-EDE3-CBC,FC45EBADB04DB592
-
-afpHgJoopFeoG7oeI6YVeF0BPIZrmBvnZrQcbhpldYgwns/GIaZVOT1r5iPg0fEY
-SpPmeciKf842Um4wcMDMHvG8aOfDmgf/bToSKqtBHowWJBCdsMrp7Z7w2O7kjcUR
-CFzdrP9Pm3hUh4sCSwV+WwEZGSY9fbJdGsA2mJzM33m5moX7lT2zgKwLiiUjX5Qn
-7GzNmScxxCswQMThcA+q/w6G5rJk7eQlREaR2ji9mrc+hLZSorf9kQ3BLWq17HUc
-HFLsciSFlciWuv/YKoBsrniBB5XI6Ys31CQf1smRzh9uhqiiiX2GPXxxwqfP/8LK
-PH/NjlwRmB7Ex0cxPAz/QEsnKxgnjFLlTr5gJD7pDYXlWrR/I7wlxgfRaLvBbbmr
-+GNVglZLHvnJIfq83jkOFW2ggyM0Zkr3EXAp1u95HaBG43yazi8RPz6kwaiR9+rS
-gY7uKnHqqDhOhVNmzrr9DGmetJ0wCeAXrLe4cPz6oie4+wgDZ5t87jFzyUFKY/sU
-IoWvuVK0j3ykTuWTHjr9MwA4T47mwT6V98XjSvrejGfcDNp3zv583En9sTqTEeN1
-iXuqxUdJmsGAdlJZqlmOIbAcGfyZw5kAeU58pLueAMoiaN6Ne3+fG8GHYtFncaSP
-bQeZFoghTty3/E87f4M1TpBhh2hdVfJ9uizHwGceJrFWERXjp42q1DqPdYmpIWwl
-EBXkmWTJ+Nw1GPTYeOgjkkP3elAcI/R/gshJAj0p0vrjuFPoKuy/VnK5DIWHYaxf
-9CRibePWEM/NxdZ21CDzevA47+QLjadTTgLoHvuWLKWun3lHJh4oCmUJKsEotPql
-uCmkho+QEDfUpeDKlpscZRPyCJDDlyJWhPOpHin7HksehsPSK4xSlGweUMacB0DT
-S63gBpCBbpA7Gzj6WrePd8NSgreDTQqa1Io6IJr279jLgZuNLnW1Dsg606bRWWm0
-ieB+G9SgxZ7yrDE0jk82pTJN7c7DsMMSnASA/2rx8QHyvNIVKBmFRGOe7RnyYYU2
-kDG3giW5mVluN65PNNasqwtRo1rOL3TyeMDTzLwFjmT4dLbEPgxOWV27ZeVxESOi
-fXZfls2aKHR/5P18pSuQmmB2TSbT3/T8+P//t1OZ9M/VCmBfmOpq0VaVFAV+we8h
-y0EWnxLHsNQAi1Zsu33L0Xt5Sev1M/pyz5XBJiBr+JPO9YcM+VFhJuyjMM0MbCWl
-aPOUF2uESeqoj1SyHMDrZ6D9lpQk3S+RmmFG+OkAsOejVWGcuIDURwWWHIWyxo89
-9FR7lanvV1K0W6z4+RYc+VQYLI5Ldzph8n7XpVAiqLvhIeHhWBd9o2wIaoHoR2CM
-6ej6z0xxuEB7L1YX50KYGDT+mXdUopQiNorShFZlnowUMjIU3ChROEXCcEls0jYf
-XC/S5aUoSXF2NLRKvEig94pZUr1moO7GETuFNu/ZYQZJNdgG2OWCEmBNGc/Vk0AI
-16iF+QkwQkyLEwBiArTguNkDCpLE9pziW5zDXD8RU3o3vqHfXXluMlZO88MvhUR8
-BxpTFhkqWrxvhzX1M3m8erff3RccHmH8BY6DEc3NshyfUjHRC1RgBQC0vxasjyDk
------END RSA PRIVATE KEY-----
Deleted: trunk/build/unix/util/jbossweb/node1/conf/logging.properties
===================================================================
--- trunk/build/unix/util/jbossweb/node1/conf/logging.properties 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbossweb/node1/conf/logging.properties 2011-05-12 16:11:01 UTC (rev 2783)
@@ -1,51 +0,0 @@
-handlers = 1catalina.org.jboss.test.FileHandler, 2localhost.org.jboss.test.FileHandler, 3manager.org.jboss.test.FileHandler, 4admin.org.jboss.test.FileHandler, 5host-manager.org.jboss.test.FileHandler, java.util.logging.ConsoleHandler
-
-.handlers = 1catalina.org.jboss.test.FileHandler, java.util.logging.ConsoleHandler
-
-############################################################
-# Handler specific properties.
-# Describes specific configuration info for Handlers.
-############################################################
-
-1catalina.org.jboss.test.FileHandler.level = FINE
-1catalina.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
-1catalina.org.jboss.test.FileHandler.prefix = catalina.
-
-2localhost.org.jboss.test.FileHandler.level = FINE
-2localhost.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
-2localhost.org.jboss.test.FileHandler.prefix = localhost.
-
-3manager.org.jboss.test.FileHandler.level = FINE
-3manager.org.jboss.test.FileHandleorg.jboss.test.FileHandlerse}/logs
-3manager.org.jboss.test.FileHandler.prefix = manager.
-
-5host-manager.org.jboss.test.FileHandler.level = FINE
-5host-manager.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
-5host-manager.org.jboss.test.FileHandler.prefix = host-manager.
-
-java.util.logging.ConsoleHandler.level = FINE
-java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
-
-
-############################################################
-# Facility specific properties.
-# Provides extra control for each logger.
-############################################################
-
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].level = INFO
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].handlers = 2localhost.org.jboss.test.FileHandler
-
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].level = INFO
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].handlers = 3manager.org.jboss.test.FileHandler
-
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].level = INFO
-org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].handlers = 5host-manager.org.jboss.test.FileHandler
-
-# For example, set the com.xyz.foo logger to only log SEVERE
-# messages:
-#org.apache.catalina.startup.ContextConfig.level = FINE
-#org.apache.catalina.startup.HostConfig.level = FINE
-#org.apache.catalina.session.ManagerBase.level = FINE
-org.apache.catalina.core.AprLifecycleListener.level=ALL
-org.apache.catalina.level=ALL
-org.jboss.test.level=ALL
Copied: trunk/build/unix/util/jbosswebtests/cacert.pem (from rev 2782, trunk/build/unix/util/jbossweb/cacert.pem)
===================================================================
--- trunk/build/unix/util/jbosswebtests/cacert.pem (rev 0)
+++ trunk/build/unix/util/jbosswebtests/cacert.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -0,0 +1,18 @@
+-----BEGIN CERTIFICATE-----
+MIIC3TCCAkagAwIBAgIBADANBgkqhkiG9w0BAQUFADB2MQswCQYDVQQGEwJDSDES
+MBAGA1UECBMJTmV1Y2hhdGVsMRAwDgYDVQQKEwdSZWQgSGF0MQ4wDAYDVQQLEwVq
+Ym9zczEOMAwGA1UEAxMFamZjcGMxITAfBgkqhkiG9w0BCQEWEmpmY2xlcmVAcmVk
+aGF0LmNvbTAeFw0wODEyMDIxMzU2MzdaFw0xMTEyMDIxMzU2MzdaMHYxCzAJBgNV
+BAYTAkNIMRIwEAYDVQQIEwlOZXVjaGF0ZWwxEDAOBgNVBAoTB1JlZCBIYXQxDjAM
+BgNVBAsTBWpib3NzMQ4wDAYDVQQDEwVqZmNwYzEhMB8GCSqGSIb3DQEJARYSamZj
+bGVyZUByZWRoYXQuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDBju4V
+GAwObduuScxhPHNvBWRbjU1DAiv00fwHh6nELVxwBsyzWOY4pcUBfrr3bNsJP9dd
+ZpGHqHA7kroLZxfyXTmF/C58a1HIhhzgS4rtijOFHOh5WLD0HZICPdCR1D1IznXx
+oAoMOQ/PeGCfiPVLWzwSqrg/GDW3vhTIRlTrpwIDAQABo3sweTAJBgNVHRMEAjAA
+MCwGCWCGSAGG+EIBDQQfFh1PcGVuU1NMIEdlbmVyYXRlZCBDZXJ0aWZpY2F0ZTAd
+BgNVHQ4EFgQU3P9xfJgsEC/jPhHgr5Wt3J8iCYAwHwYDVR0jBBgwFoAU3P9xfJgs
+EC/jPhHgr5Wt3J8iCYAwDQYJKoZIhvcNAQEFBQADgYEAJoT9AdqxQ/7ezw5sx6Fn
+DSJR7DtiXVHB8zChbev3aS36Dym4qiQBXgQ+hUe+AtnMDq3YNN7LGBP/a/eT76zs
+CWsKLfZq200wkQE/54fSxLGmapy6DQuh2Xtuw+oEjAlZVBruLMv9gOQ4Dg+DteRp
+cSlORuUwHEggjl3PakQc78Q=
+-----END CERTIFICATE-----
Copied: trunk/build/unix/util/jbosswebtests/newcert.pem (from rev 2782, trunk/build/unix/util/jbossweb/newcert.pem)
===================================================================
--- trunk/build/unix/util/jbosswebtests/newcert.pem (rev 0)
+++ trunk/build/unix/util/jbosswebtests/newcert.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -0,0 +1,73 @@
+Certificate:
+ Data:
+ Version: 3 (0x2)
+ Serial Number: 8 (0x8)
+ Signature Algorithm: sha1WithRSAEncryption
+ Issuer: C=CH, ST=Neuchatel, O=Red Hat, OU=jboss, CN=jfcpc/emailAddress=jfclere(a)redhat.com
+ Validity
+ Not Before: May 4 07:42:13 2011 GMT
+ Not After : May 3 07:42:13 2012 GMT
+ Subject: C=CH, ST=Neuchatel, L=Neuchatel, O=Red Hat, OU=jboss, CN=localhost/emailAddress=jfclere(a)jfclere.org
+ Subject Public Key Info:
+ Public Key Algorithm: rsaEncryption
+ Public-Key: (2048 bit)
+ Modulus:
+ 00:d9:46:dc:a0:e0:b9:b1:2c:c8:83:55:ec:a4:06:
+ 5b:ee:60:0a:c0:6f:28:4b:4d:97:39:06:5c:3d:b0:
+ 32:d4:4e:d6:c7:3f:22:54:e2:a7:d9:e2:c7:9c:b9:
+ b9:bd:1d:66:45:53:7e:3b:25:32:76:79:c9:c1:52:
+ 91:bb:d3:02:b5:1c:70:a1:a3:e8:75:94:ea:ad:61:
+ 36:a7:5e:c8:59:c2:7c:94:f5:17:46:6a:65:cc:c9:
+ 2c:09:49:54:ee:73:60:ec:63:ec:92:56:22:60:fc:
+ b5:46:ba:7c:ca:d3:f9:85:e5:7e:20:44:b1:4d:5e:
+ 71:4b:84:07:11:23:ce:0c:70:55:14:f6:74:c6:ce:
+ 34:18:d0:ae:e9:da:a0:0b:ca:98:0e:19:92:d2:d8:
+ 4a:90:9a:62:da:90:5f:7a:d9:f7:ff:14:7b:41:6e:
+ 8d:37:cc:a5:45:c2:18:b9:d9:99:0b:3d:ae:3d:fe:
+ 9c:6a:25:06:b7:25:41:ad:c3:ac:c7:c7:4f:8c:d1:
+ 81:2c:bd:f9:e4:7f:26:d3:5c:84:f4:da:2a:1d:0a:
+ 6a:15:1b:e1:e2:c1:c8:ef:b4:4d:92:9d:b3:3c:c9:
+ 8f:e0:b3:7e:94:12:c1:24:58:6f:87:38:11:2d:e3:
+ c8:c6:0f:be:50:0c:de:3a:9e:ff:e9:64:51:65:64:
+ 6a:db
+ Exponent: 65537 (0x10001)
+ X509v3 extensions:
+ X509v3 Basic Constraints:
+ CA:FALSE
+ Netscape Comment:
+ OpenSSL Generated Certificate
+ X509v3 Subject Key Identifier:
+ 39:CC:FF:65:7D:6D:F3:2D:6F:88:96:8D:ED:9A:A5:5A:BE:FE:EE:E4
+ X509v3 Authority Key Identifier:
+ keyid:DC:FF:71:7C:98:2C:10:2F:E3:3E:11:E0:AF:95:AD:DC:9F:22:09:80
+
+ Signature Algorithm: sha1WithRSAEncryption
+ ae:f3:48:4c:81:6f:5a:af:76:bb:88:85:f7:a7:5b:2e:14:57:
+ 31:d5:04:cb:4d:97:88:24:bd:87:e4:24:05:10:6a:2b:4d:bd:
+ 05:84:d7:f4:0a:3b:de:c7:ba:31:a8:22:c8:82:80:19:5f:f3:
+ 2b:d5:1e:62:20:c3:87:4b:40:b2:f3:78:b4:ef:b3:7b:00:93:
+ 9e:75:ea:6e:fd:e3:e2:55:6a:23:31:b9:2a:01:71:5f:a1:f2:
+ f3:a5:0c:21:cd:1d:34:e1:b4:a4:47:ac:7b:2f:30:76:a6:85:
+ 9c:0e:2b:e2:64:67:f7:14:e6:44:27:52:17:93:8d:e1:0a:41:
+ 29:1c
+-----BEGIN CERTIFICATE-----
+MIIDezCCAuSgAwIBAgIBCDANBgkqhkiG9w0BAQUFADB2MQswCQYDVQQGEwJDSDES
+MBAGA1UECBMJTmV1Y2hhdGVsMRAwDgYDVQQKEwdSZWQgSGF0MQ4wDAYDVQQLEwVq
+Ym9zczEOMAwGA1UEAxMFamZjcGMxITAfBgkqhkiG9w0BCQEWEmpmY2xlcmVAcmVk
+aGF0LmNvbTAeFw0xMTA1MDQwNzQyMTNaFw0xMjA1MDMwNzQyMTNaMIGPMQswCQYD
+VQQGEwJDSDESMBAGA1UECAwJTmV1Y2hhdGVsMRIwEAYDVQQHDAlOZXVjaGF0ZWwx
+EDAOBgNVBAoMB1JlZCBIYXQxDjAMBgNVBAsMBWpib3NzMRIwEAYDVQQDDAlsb2Nh
+bGhvc3QxIjAgBgkqhkiG9w0BCQEWE2pmY2xlcmVAamZjbGVyZS5vcmcwggEiMA0G
+CSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDZRtyg4LmxLMiDVeykBlvuYArAbyhL
+TZc5Blw9sDLUTtbHPyJU4qfZ4secubm9HWZFU347JTJ2ecnBUpG70wK1HHCho+h1
+lOqtYTanXshZwnyU9RdGamXMySwJSVTuc2DsY+ySViJg/LVGunzK0/mF5X4gRLFN
+XnFLhAcRI84McFUU9nTGzjQY0K7p2qALypgOGZLS2EqQmmLakF962ff/FHtBbo03
+zKVFwhi52ZkLPa49/pxqJQa3JUGtw6zHx0+M0YEsvfnkfybTXIT02iodCmoVG+Hi
+wcjvtE2SnbM8yY/gs36UEsEkWG+HOBEt48jGD75QDN46nv/pZFFlZGrbAgMBAAGj
+ezB5MAkGA1UdEwQCMAAwLAYJYIZIAYb4QgENBB8WHU9wZW5TU0wgR2VuZXJhdGVk
+IENlcnRpZmljYXRlMB0GA1UdDgQWBBQ5zP9lfW3zLW+Ilo3tmqVavv7u5DAfBgNV
+HSMEGDAWgBTc/3F8mCwQL+M+EeCvla3cnyIJgDANBgkqhkiG9w0BAQUFAAOBgQCu
+80hMgW9ar3a7iIX3p1suFFcx1QTLTZeIJL2H5CQFEGorTb0FhNf0Cjvex7oxqCLI
+goAZX/Mr1R5iIMOHS0Cy83i077N7AJOedepu/ePiVWojMbkqAXFfofLzpQwhzR00
+4bSkR6x7LzB2poWcDiviZGf3FOZEJ1IXk43hCkEpHA==
+-----END CERTIFICATE-----
Copied: trunk/build/unix/util/jbosswebtests/newkey.pem (from rev 2782, trunk/build/unix/util/jbossweb/newkey.pem)
===================================================================
--- trunk/build/unix/util/jbosswebtests/newkey.pem (rev 0)
+++ trunk/build/unix/util/jbosswebtests/newkey.pem 2011-05-12 16:11:01 UTC (rev 2783)
@@ -0,0 +1,30 @@
+-----BEGIN RSA PRIVATE KEY-----
+Proc-Type: 4,ENCRYPTED
+DEK-Info: DES-EDE3-CBC,FC45EBADB04DB592
+
+afpHgJoopFeoG7oeI6YVeF0BPIZrmBvnZrQcbhpldYgwns/GIaZVOT1r5iPg0fEY
+SpPmeciKf842Um4wcMDMHvG8aOfDmgf/bToSKqtBHowWJBCdsMrp7Z7w2O7kjcUR
+CFzdrP9Pm3hUh4sCSwV+WwEZGSY9fbJdGsA2mJzM33m5moX7lT2zgKwLiiUjX5Qn
+7GzNmScxxCswQMThcA+q/w6G5rJk7eQlREaR2ji9mrc+hLZSorf9kQ3BLWq17HUc
+HFLsciSFlciWuv/YKoBsrniBB5XI6Ys31CQf1smRzh9uhqiiiX2GPXxxwqfP/8LK
+PH/NjlwRmB7Ex0cxPAz/QEsnKxgnjFLlTr5gJD7pDYXlWrR/I7wlxgfRaLvBbbmr
++GNVglZLHvnJIfq83jkOFW2ggyM0Zkr3EXAp1u95HaBG43yazi8RPz6kwaiR9+rS
+gY7uKnHqqDhOhVNmzrr9DGmetJ0wCeAXrLe4cPz6oie4+wgDZ5t87jFzyUFKY/sU
+IoWvuVK0j3ykTuWTHjr9MwA4T47mwT6V98XjSvrejGfcDNp3zv583En9sTqTEeN1
+iXuqxUdJmsGAdlJZqlmOIbAcGfyZw5kAeU58pLueAMoiaN6Ne3+fG8GHYtFncaSP
+bQeZFoghTty3/E87f4M1TpBhh2hdVfJ9uizHwGceJrFWERXjp42q1DqPdYmpIWwl
+EBXkmWTJ+Nw1GPTYeOgjkkP3elAcI/R/gshJAj0p0vrjuFPoKuy/VnK5DIWHYaxf
+9CRibePWEM/NxdZ21CDzevA47+QLjadTTgLoHvuWLKWun3lHJh4oCmUJKsEotPql
+uCmkho+QEDfUpeDKlpscZRPyCJDDlyJWhPOpHin7HksehsPSK4xSlGweUMacB0DT
+S63gBpCBbpA7Gzj6WrePd8NSgreDTQqa1Io6IJr279jLgZuNLnW1Dsg606bRWWm0
+ieB+G9SgxZ7yrDE0jk82pTJN7c7DsMMSnASA/2rx8QHyvNIVKBmFRGOe7RnyYYU2
+kDG3giW5mVluN65PNNasqwtRo1rOL3TyeMDTzLwFjmT4dLbEPgxOWV27ZeVxESOi
+fXZfls2aKHR/5P18pSuQmmB2TSbT3/T8+P//t1OZ9M/VCmBfmOpq0VaVFAV+we8h
+y0EWnxLHsNQAi1Zsu33L0Xt5Sev1M/pyz5XBJiBr+JPO9YcM+VFhJuyjMM0MbCWl
+aPOUF2uESeqoj1SyHMDrZ6D9lpQk3S+RmmFG+OkAsOejVWGcuIDURwWWHIWyxo89
+9FR7lanvV1K0W6z4+RYc+VQYLI5Ldzph8n7XpVAiqLvhIeHhWBd9o2wIaoHoR2CM
+6ej6z0xxuEB7L1YX50KYGDT+mXdUopQiNorShFZlnowUMjIU3ChROEXCcEls0jYf
+XC/S5aUoSXF2NLRKvEig94pZUr1moO7GETuFNu/ZYQZJNdgG2OWCEmBNGc/Vk0AI
+16iF+QkwQkyLEwBiArTguNkDCpLE9pziW5zDXD8RU3o3vqHfXXluMlZO88MvhUR8
+BxpTFhkqWrxvhzX1M3m8erff3RccHmH8BY6DEc3NshyfUjHRC1RgBQC0vxasjyDk
+-----END RSA PRIVATE KEY-----
Copied: trunk/build/unix/util/jbosswebtests/node1/conf/logging.properties (from rev 2782, trunk/build/unix/util/jbossweb/node1/conf/logging.properties)
===================================================================
--- trunk/build/unix/util/jbosswebtests/node1/conf/logging.properties (rev 0)
+++ trunk/build/unix/util/jbosswebtests/node1/conf/logging.properties 2011-05-12 16:11:01 UTC (rev 2783)
@@ -0,0 +1,51 @@
+handlers = 1catalina.org.jboss.test.FileHandler, 2localhost.org.jboss.test.FileHandler, 3manager.org.jboss.test.FileHandler, 4admin.org.jboss.test.FileHandler, 5host-manager.org.jboss.test.FileHandler, java.util.logging.ConsoleHandler
+
+.handlers = 1catalina.org.jboss.test.FileHandler, java.util.logging.ConsoleHandler
+
+############################################################
+# Handler specific properties.
+# Describes specific configuration info for Handlers.
+############################################################
+
+1catalina.org.jboss.test.FileHandler.level = FINE
+1catalina.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
+1catalina.org.jboss.test.FileHandler.prefix = catalina.
+
+2localhost.org.jboss.test.FileHandler.level = FINE
+2localhost.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
+2localhost.org.jboss.test.FileHandler.prefix = localhost.
+
+3manager.org.jboss.test.FileHandler.level = FINE
+3manager.org.jboss.test.FileHandleorg.jboss.test.FileHandlerse}/logs
+3manager.org.jboss.test.FileHandler.prefix = manager.
+
+5host-manager.org.jboss.test.FileHandler.level = FINE
+5host-manager.org.jboss.test.FileHandler.directory = ${catalina.base}/logs
+5host-manager.org.jboss.test.FileHandler.prefix = host-manager.
+
+java.util.logging.ConsoleHandler.level = FINE
+java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
+
+
+############################################################
+# Facility specific properties.
+# Provides extra control for each logger.
+############################################################
+
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].level = INFO
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].handlers = 2localhost.org.jboss.test.FileHandler
+
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].level = INFO
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/manager].handlers = 3manager.org.jboss.test.FileHandler
+
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].level = INFO
+org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/host-manager].handlers = 5host-manager.org.jboss.test.FileHandler
+
+# For example, set the com.xyz.foo logger to only log SEVERE
+# messages:
+#org.apache.catalina.startup.ContextConfig.level = FINE
+#org.apache.catalina.startup.HostConfig.level = FINE
+#org.apache.catalina.session.ManagerBase.level = FINE
+org.apache.catalina.core.AprLifecycleListener.level=ALL
+org.apache.catalina.level=ALL
+org.jboss.test.level=ALL
Modified: trunk/build/unix/util/jbosswebtests/pom.xml
===================================================================
--- trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-12 16:11:01 UTC (rev 2783)
@@ -34,7 +34,8 @@
<properties>
<version.junit>4.8.1</version.junit>
- <version.org.jboss.web>7.0.0.CR1</version.org.jboss.web>
+ <version.org.jboss.web>7.0.0.CR2</version.org.jboss.web>
+ <version.org.jboss.spec.javax.servlet.jboss-servlet-api_3.0_spec>1.0.0.Final</version.org.jboss.spec.javax.servlet.jboss-servlet-api_3.0_spec>
<!--
<version.org.jboss.web>2.1.11.GA</version.org.jboss.web>
-->
@@ -60,6 +61,46 @@
<enableAssertions>false</enableAssertions>
</configuration>
</plugin>
+ <plugin>
+ <artifactId>maven-antrun-plugin</artifactId>
+ <version>1.6</version>
+ <executions>
+ <execution>
+ <phase>test</phase>
+ <configuration>
+ <tasks>
+ <!-- extract the native build to test it -->
+
+ <echo>"native jar: ${org.jboss.as:jbossweb-native:jar}"</echo>
+
+ <unjar src="${org.jboss.as:jbossweb-native:jar}" dest="node1" />
+
+ <!-- Start jbossweb (embedded) -->
+ <java dir="node1" classname="org.jboss.test.StartJBossWeb"
+ spawn="true" fork="yes">
+ <arg line="${line}"/>
+ <jvmarg line="-Djava.util.logging.config.file=node1/conf/logging.properties" />
+ <jvmarg line="-Djava.util.logging.manager=org.jboss.test.ClassLoaderLogManager"/>
+ <classpath refid="maven.test.classpath"/>
+ </java>
+
+ <!-- Test it -->
+ <delete file="index.html"/>
+ <exec executable="wget">
+ <arg value="--no-check-certificate"/>
+ <arg value="https://localhost:8009/index.html"/>
+ </exec>
+ <available file="index.html" property="exist"/>
+ <fail unless="exist" message="Can't get test file"/>
+
+ </tasks>
+ </configuration>
+ <goals>
+ <goal>run</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
</plugins>
</build>
@@ -84,13 +125,23 @@
<version>${version.org.jboss.as.jbossweb-native}</version>
</dependency>
+ <dependency>
+ <groupId>org.jboss.spec.javax.servlet</groupId>
+ <artifactId>jboss-servlet-api_3.0_spec</artifactId>
+ <version>${version.org.jboss.spec.javax.servlet.jboss-servlet-api_3.0_spec}</version>
+ <scope>test</scope>
+ </dependency>
+
</dependencies>
<repositories>
<repository>
<id>jboss-public-repository-group</id>
<name>JBoss Public Repository Group</name>
+ <!--
<url>http://repository.jboss.org/nexus/content/groups/public/</url>
+ -->
+ <url>https://repository.jboss.org/nexus/content/groups/staging/</url>
<layout>default</layout>
<releases>
<enabled>true</enabled>
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-12 16:11:01 UTC (rev 2783)
@@ -62,12 +62,13 @@
this.route = route;
//Create an Engine
- Engine baseEngine = createEngine();
+ StandardEngine baseEngine = (StandardEngine) createEngine();
baseEngine.setName(host + "Engine" + route);
baseEngine.setDefaultHost(host);
baseEngine.setJvmRoute(route);
baseEngine.setRealm(null);
+ baseEngine.setBaseDir(route);
// Create node1/webapps/ROOT and index.html
File fd = new File ( route + "/webapps/" + webapp);
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-10 09:10:10 UTC (rev 2782)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-12 16:11:01 UTC (rev 2783)
@@ -81,16 +81,14 @@
AprLifecycleListener apr = new AprLifecycleListener();
server.addLifecycleListener(apr);
- final Connector connector = new Connector("HTTP/1.1");
- connector.setScheme("https");
- connector.setPort(port);
- service.addConnector(connector);
server.addService(service);
// server.addLifecycleListener(apr);
server.init();
server.start();
+
+ service.addConnector(port, "https");
} catch(IOException ex) {
ex.printStackTrace();
13 years, 7 months
JBoss Native SVN: r2782 - trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-10 05:10:10 -0400 (Tue, 10 May 2011)
New Revision: 2782
Modified:
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ProcJBossWeb.java
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ServerThread.java
trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
Log:
use jbossweb_trunk instead 2.1.x
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-10 08:15:49 UTC (rev 2781)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/JBossWeb.java 2011-05-10 09:10:10 UTC (rev 2782)
@@ -34,9 +34,6 @@
import java.io.FileOutputStream;
import org.apache.catalina.startup.Embedded;
-import org.apache.catalina.Engine;
-import org.apache.catalina.Host;
-import org.apache.catalina.Context;
import org.apache.catalina.*;
import org.apache.catalina.connector.Connector;
import org.apache.catalina.core.*;
@@ -58,51 +55,7 @@
fos.close();
}
- private static void copyFiles(File src, File dest) throws IOException {
- if (src.isDirectory()) {
- if (!dest.exists())
- dest.mkdirs();
-
- String list[] = src.list();
- for (int i = 0; i < list.length; i++) {
- File dest1 = new File(dest, list[i]);
- File src1 = new File(src, list[i]);
- copyFiles(src1 , dest1);
- }
- } else {
- //This was not a directory, so lets just copy the file
- FileInputStream fin = null;
- FileOutputStream fout = null;
- byte[] buffer = new byte[4096]; //Buffer 4K at a time (you can change this).
- int bytesRead;
- //open the files for input and output
- fin = new FileInputStream(src);
- fout = new FileOutputStream (dest);
- //while bytesRead indicates a successful read, lets write...
- while ((bytesRead = fin.read(buffer)) >= 0) {
- fout.write(buffer,0,bytesRead);
- }
- fout.close();
- fin.close();
- }
- }
- private void copyNativeDir(String route) throws IOException {
- File in = new File("bin/");
- if (!in.exists()) {
- return;
- }
- File ou = new File("node1/bin");
- if (!ou.exists()) {
- ou.mkdirs();
- }
- copyFiles(in, ou);
- }
-
public JBossWeb(String route, String host, boolean nat, String webapp, String[] Aliases) throws IOException {
- // Copy native tree...
- if (nat) {
- copyNativeDir(route);
- }
setCatalinaBase(route);
setCatalinaHome(route);
@@ -128,12 +81,9 @@
//Create Host
Host baseHost = createHost( host, appBase);
- baseHost.setDeployOnStartup(true);
baseHost.setBackgroundProcessorDelay(1);
StandardHost stdhost = (StandardHost)baseHost;
- stdhost.setDeployXML(true);
stdhost.setConfigClass("org.apache.catalina.startup.ContextConfig");
- stdhost.setUnpackWARs(true);
if (Aliases != null && Aliases.length>0) {
for (int j = 0; j < Aliases.length; j++) {
stdhost.addAlias(Aliases[j]);
@@ -162,9 +112,15 @@
addEngine( baseEngine );
baseEngine.setService(this);
this.setName(host + "Engine" + route);
- setRedirectStreams(false);
}
- void AddContext(String path, String docBase, String servletname, boolean wait) {
+ private Context createContext(String string, String docBase) {
+ StandardContext context = new StandardContext();
+ context.setDocBase(docBase);
+ context.setPath(string);
+ return context;
+ }
+
+ void AddContext(String path, String docBase, String servletname, boolean wait) {
File fd = new File ( route + "/webapps/" + docBase);
fd.mkdirs();
docBase = fd.getAbsolutePath();
@@ -252,15 +208,4 @@
return connector;
}
- public void removeContext(String path) {
- Engine engine = (Engine) getContainer();
- Container[] containers = engine.findChildren();
- for (int j = 0; j < containers.length; j++) {
- if (containers[j] instanceof StandardHost) {
- StandardHost host = (StandardHost) containers[j];
- Context context = host.map(path);
- containers[j].removeChild(context);
- }
- }
- }
}
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ProcJBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ProcJBossWeb.java 2011-05-10 08:15:49 UTC (rev 2781)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ProcJBossWeb.java 2011-05-10 09:10:10 UTC (rev 2782)
@@ -64,7 +64,7 @@
}
public void start() {
- server = (StandardServer) ServerFactory.getServer();
+ StandardService service = new StandardService();
ServerThread wait = null;
try {
@@ -78,8 +78,6 @@
System.exit(0);
} else if (cmd[0].compareToIgnoreCase("new") == 0) {
service = new JBossWeb(cmd[1], cmd[2]);
- } else if (cmd[0].compareToIgnoreCase("addConnector") == 0) {
- service.addConnector(Integer.parseInt(cmd[1]));
} else if (cmd[0].compareToIgnoreCase("addService")== 0) {
server.addService(service);
} else if (cmd[0].compareToIgnoreCase("start") == 0) {
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ServerThread.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ServerThread.java 2011-05-10 08:15:49 UTC (rev 2781)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/ServerThread.java 2011-05-10 09:10:10 UTC (rev 2782)
@@ -30,7 +30,6 @@
import java.io.IOException;
import org.apache.catalina.Engine;
-import org.apache.catalina.ServerFactory;
import org.apache.catalina.Service;
import org.apache.catalina.LifecycleListener;
import org.apache.catalina.LifecycleException;
Modified: trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java
===================================================================
--- trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-10 08:15:49 UTC (rev 2781)
+++ trunk/build/unix/util/jbosswebtests/src/main/java/org/jboss/test/StartJBossWeb.java 2011-05-10 09:10:10 UTC (rev 2782)
@@ -32,11 +32,14 @@
import java.io.IOException;
import java.io.FileInputStream;
import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.net.InetAddress;
+import java.net.ServerSocket;
+import java.net.Socket;
+import java.security.AccessControlException;
+import java.util.Random;
import org.apache.catalina.startup.Embedded;
-import org.apache.catalina.Engine;
-import org.apache.catalina.Host;
-import org.apache.catalina.Context;
import org.apache.catalina.*;
import org.apache.catalina.connector.Connector;
import org.apache.catalina.core.*;
@@ -49,6 +52,9 @@
public class StartJBossWeb {
private static Logger log = Logger.getLogger(StartJBossWeb.class);
+ private static String address = "localhost";
+ private static String shutdown = "SHUTDOWN";
+ private static Random random = null;
/* Start a JBossWEB with domain */
public static void main(String[] args) {
@@ -69,14 +75,16 @@
log.info("Starting JBossWEB on " + port + " " + node + " " + domain + " " + serverport);
try {
- server = (StandardServer) ServerFactory.getServer();
- server.setPort(serverport);
+ server = new StandardServer();
service = new JBossWeb(node, "localhost");
AprLifecycleListener apr = new AprLifecycleListener();
server.addLifecycleListener(apr);
- service.addConnector(port, "https", null);
+ final Connector connector = new Connector("HTTP/1.1");
+ connector.setScheme("https");
+ connector.setPort(port);
+ service.addConnector(connector);
server.addService(service);
// server.addLifecycleListener(apr);
@@ -93,7 +101,7 @@
}
// Wait until we are stopped...
- server.await();
+ await(serverport);
// Stop the server or services.
try {
@@ -105,4 +113,84 @@
}
}
+
+ /* Wait until we receive a stop command */
+ private static void await(int port) {
+ // Set up a server socket to wait on
+ ServerSocket serverSocket = null;
+ try {
+ serverSocket =
+ new ServerSocket(port, 1,
+ InetAddress.getByName(address));
+ } catch (IOException e) {
+ log.error("StandardServer.await: create[" + address
+ + ":" + port
+ + "]: ", e);
+ System.exit(1);
+ }
+
+ // Loop waiting for a connection and a valid command
+ while (true) {
+
+ // Wait for the next connection
+ Socket socket = null;
+ InputStream stream = null;
+ try {
+ socket = serverSocket.accept();
+ socket.setSoTimeout(10 * 1000); // Ten seconds
+ stream = socket.getInputStream();
+ } catch (AccessControlException ace) {
+ log.warn("StandardServer.accept security exception: "
+ + ace.getMessage(), ace);
+ continue;
+ } catch (IOException e) {
+ log.error("StandardServer.await: accept: ", e);
+ System.exit(1);
+ }
+
+ // Read a set of characters from the socket
+ StringBuffer command = new StringBuffer();
+ int expected = 1024; // Cut off to avoid DoS attack
+ while (expected < shutdown.length()) {
+ if (random == null)
+ random = new Random(System.currentTimeMillis());
+ expected += (random.nextInt() % 1024);
+ }
+ while (expected > 0) {
+ int ch = -1;
+ try {
+ ch = stream.read();
+ } catch (IOException e) {
+ log.warn("StandardServer.await: read: ", e);
+ ch = -1;
+ }
+ if (ch < 32) // Control character or EOF terminates loop
+ break;
+ command.append((char) ch);
+ expected--;
+ }
+
+ // Close the socket now that we are done with it
+ try {
+ socket.close();
+ } catch (IOException e) {
+ ;
+ }
+
+ // Match against our command string
+ boolean match = command.toString().equals(shutdown);
+ if (match) {
+ break;
+ } else
+ log.warn("StandardServer.await: Invalid command '" +
+ command.toString() + "' received");
+
+ }
+ // Close the server socket and return
+ try {
+ serverSocket.close();
+ } catch (IOException e) {
+ ;
+ }
+ }
}
13 years, 7 months
JBoss Native SVN: r2781 - trunk/build/unix/util/jbosswebtests.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-10 04:15:49 -0400 (Tue, 10 May 2011)
New Revision: 2781
Modified:
trunk/build/unix/util/jbosswebtests/pom.xml
Log:
Add repo and use latest version.
Modified: trunk/build/unix/util/jbosswebtests/pom.xml
===================================================================
--- trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-10 08:00:04 UTC (rev 2780)
+++ trunk/build/unix/util/jbosswebtests/pom.xml 2011-05-10 08:15:49 UTC (rev 2781)
@@ -34,7 +34,7 @@
<properties>
<version.junit>4.8.1</version.junit>
- <version.org.jboss.web>7.0.0.Beta10</version.org.jboss.web>
+ <version.org.jboss.web>7.0.0.CR1</version.org.jboss.web>
<!--
<version.org.jboss.web>2.1.11.GA</version.org.jboss.web>
-->
@@ -85,4 +85,22 @@
</dependency>
</dependencies>
+
+ <repositories>
+ <repository>
+ <id>jboss-public-repository-group</id>
+ <name>JBoss Public Repository Group</name>
+ <url>http://repository.jboss.org/nexus/content/groups/public/</url>
+ <layout>default</layout>
+ <releases>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </releases>
+ <snapshots>
+ <enabled>true</enabled>
+ <updatePolicy>never</updatePolicy>
+ </snapshots>
+ </repository>
+ </repositories>
+
</project>
13 years, 7 months
JBoss Native SVN: r2780 - trunk/build/unix/util/jbossweb.
by jbossnative-commits@lists.jboss.org
Author: jfrederic.clere(a)jboss.com
Date: 2011-05-10 04:00:04 -0400 (Tue, 10 May 2011)
New Revision: 2780
Modified:
trunk/build/unix/util/jbossweb/pom.xml
Log:
Removed now useless dependencies.
Modified: trunk/build/unix/util/jbossweb/pom.xml
===================================================================
--- trunk/build/unix/util/jbossweb/pom.xml 2011-05-10 07:32:23 UTC (rev 2779)
+++ trunk/build/unix/util/jbossweb/pom.xml 2011-05-10 08:00:04 UTC (rev 2780)
@@ -32,11 +32,6 @@
<version>6-beta-1</version>
</parent>
- <properties>
- <version.junit>4.8.1</version.junit>
- <version.org.jboss.web>7.0.0.Beta10</version.org.jboss.web>
- </properties>
-
<groupId>org.jboss.as</groupId>
<artifactId>jbossweb-native</artifactId>
<version>2.0.10-SNAPSHOT</version>
@@ -73,20 +68,4 @@
</resources>
</build>
- <dependencies>
-
- <dependency>
- <groupId>junit</groupId>
- <artifactId>junit</artifactId>
- <version>${version.junit}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.jboss.web</groupId>
- <artifactId>jbossweb</artifactId>
- <version>${version.org.jboss.web}</version>
- </dependency>
-
- </dependencies>
</project>
13 years, 7 months