#!/bin/sh

# Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved.

# THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF Oracle Corp.
# The copyright notice above does not evidence any actual or intended
# publication of such source code.

if [ $# -lt 1 ] ; then
  echo Usage: startPatternMatch.sh \<wls password\> 
  exit 0
fi
. ../common/setEnv.sh

echo Starting data import for PATTERNMATCH_FACT...
../../bin/bamloadgen -XMLFile data/PATTERNMATCH_FACT.xml -duration 0 -frequency 2 -username $WLSUSERNAME -password $1 -host $WLSHOSTNAME -port $BAMPORT &

if [ $? -eq 0 ];then
   echo "Data import for PATTERNMATCH_FACT has completed successfully."
else
   echo "Failed to import data for PATTERNMATCH_FACT."
fi

echo

echo Starting data import on PATTERNMATCH_FACT_STREAM...
../../bin/bamloadgen -XMLFile data/PATTERNMATCH_FACT_STREAM.xml -frequency 2 -duration 0 -username $WLSUSERNAME -password $1 -host $WLSHOSTNAME -port $BAMPORT &

if [ $? -eq 0 ];then
   echo "Data import for PATTERNMATCH_FACT_STREAM has completed successfully."
else
   echo "Failed to import data for PATTERNMATCH_FACT_STREAM."
fi

echo 


