Tests: add regression test for Java JUL support
[lttng-tools.git] / tests / utils / utils.sh
index a09089afd4c7313a80415dfc9d707fdc75795d4f..968a6e61305ac92d1d633856027130f712584a5a 100644 (file)
@@ -156,11 +156,9 @@ function start_lttng_sessiond()
        DIR=$(readlink -f $TESTDIR)
 
        if [ -z $(pidof lt-$SESSIOND_BIN) ]; then
-               $DIR/../src/bin/lttng-sessiond/$SESSIOND_BIN --daemonize --quiet --consumerd32-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd" --consumerd64-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd"
+               $DIR/../src/bin/lttng-sessiond/$SESSIOND_BIN --daemonize --consumerd32-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd" --consumerd64-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd"
                #$DIR/../src/bin/lttng-sessiond/$SESSIOND_BIN --consumerd32-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd" --consumerd64-path="$DIR/../src/bin/lttng-consumerd/lttng-consumerd" --verbose-consumer >>/tmp/sessiond.log 2>&1 &
                status=$?
-               # Wait for sessiond to bootstrap
-               sleep 2
                ok $status "Start session daemon"
        fi
 }
@@ -259,6 +257,23 @@ function enable_ust_lttng_event ()
        ok $? "Enable event $event_name for session $sess_name"
 }
 
+function enable_jul_lttng_event()
+{
+       sess_name=$1
+       event_name="$2"
+       channel_name=$3
+
+       if [ -z $channel_name ]; then
+               # default channel if none specified
+               chan=""
+       else
+               chan="-c $channel_name"
+       fi
+
+       $TESTDIR/../src/bin/lttng/$LTTNG_BIN enable-event "$event_name" $chan -s $sess_name -j >/dev/null 2>&1
+       ok $? "Enable JUL event $event_name for session $sess_name"
+}
+
 function enable_ust_lttng_event_filter()
 {
        sess_name="$1"
This page took 0.024582 seconds and 5 git commands to generate.