anchor.diff:      ;;
   
     stop_storm)
  -    kill_storm 
  +    kill_process $STORM_PID_FILE
       ;;
   
      stop_storm_ui)
  -     kill `cat $STORM_UI_PID_FILE`
  +     kill_process $STORM_UI_PID_FILE
      ;;
   
     *)
  
positive.code: }
  
  function start_storm() {
    exec chpst -u vcap:vcap \
         $JOB_DIR/bin/storm-mesos nimbus \
         1>>$LOG_DIR/$JOB_NAME.stdout.log \
         2>>$LOG_DIR/$JOB_NAME.stderr.log &
  
    echo $! > $PID_FILE
  }
  
  function start_storm_ui() {
    export STORM_UI_PID_FILE=/var/vcap/sys/run/$JOB_NAME/$JOB_NAME-ui.pid
    exec chpst -u vcap:vcap \
         $JOB_DIR/bin/storm ui \
         1>>$LOG_DIR/$JOB_NAME-ui.stdout.log \
         2>>$LOG_DIR/$JOB_NAME-ui.stderr.log &
    
    echo $! > $STORM_UI_PID_FILE
  }
  
  function kill_storm() {
    kill `cat $PID_FILE`
  }
  
  function set_up() {
  
negative.code: #!/bin/bash
  set -e
  set -u
  
  JOB_NAME=storm
  JOB_DIR=/var/vcap/packages/$JOB_NAME
  
  export STORM_PID_FILE=/var/vcap/sys/run/$JOB_NAME/$JOB_NAME.pid
  export STORM_UI_PID_FILE=/var/vcap/sys/run/$JOB_NAME/$JOB_NAME-ui.pid
  
  function setup_java_environment() {
    export JAVA_HOME=/var/vcap/packages/jre7
  