[logback-dev] svn commit: r1969 - logback/trunk/logback-classic/src/test
noreply.ceki at qos.ch
noreply.ceki at qos.ch
Thu Nov 13 18:57:22 CET 2008
Author: ceki
Date: Thu Nov 13 18:57:21 2008
New Revision: 1969
Added:
logback/trunk/logback-classic/src/test/testSafeMode.sh
Log:
LBCORE-29
Experimental support for multiple JVM's writing to the same file
Added: logback/trunk/logback-classic/src/test/testSafeMode.sh
==============================================================================
--- (empty file)
+++ logback/trunk/logback-classic/src/test/testSafeMode.sh Thu Nov 13 18:57:21 2008
@@ -0,0 +1,44 @@
+echo "File name $1"
+echo "run length $2"
+
+
+
+#On windows
+#CLASSPATH="${CLASSPATH};./target/classes/"
+#CLASSPATH="${CLASSPATH};./target/test-classes/"
+#CLASSPATH="${CLASSPATH};../logback-core/target/classes"
+#CLASSPATH="${CLASSPATH};../logback-examples/lib/slf4j-api-1.5.5.jar"
+
+# On Unix
+#CLASSPATH="${CLASSPATH}:./target/classes/"
+#CLASSPATH="${CLASSPATH}:./target/test-classes/"
+#CLASSPATH="${CLASSPATH}:../logback-core/target/classes"
+#CLASSPATH="${CLASSPATH}:../logback-examples/lib/slf4j-api-1.5.5.jar"
+
+if [ -f $1 ]
+then
+ echo Removing $1 before tests
+ rm $1;
+fi
+
+if [ $# -lt 3 ]
+then
+ echo "Usage: testSafeMode.sh filename runLen stamp0 ... stampN"
+ exit 1;
+fi
+
+FILENAME=$1
+LEN=$2
+
+shift 2
+
+for stamp in $@
+do
+ echo running safe mode with $stamp
+ java ch.qos.logback.classic.multiJVM.SafeModeFileAppender $stamp $LEN $FILENAME &
+done
+
+wait
+
+echo Checking results...
+java ch.qos.logback.classic.multiJVM.Checker $LEN $FILENAME $*
More information about the logback-dev
mailing list