<commit_before>function karaf_kill() {
   KARAF_HOME=$1
   INSTANCES_FILE=$KARAF_HOME/instances/instance.properties
   PID=`cat $INSTANCES_FILE | grep "item.0.pid" | awk -F "=" '{print $2}'`
   kill $PID
   wait $PID
}<commit_msg>[FABRIC-407] Fix kill script so that it can wait on processes that are not children of the current shell.<commit_after>function karaf_kill() {
   KARAF_HOME=$1
   INSTANCES_FILE=$KARAF_HOME/instances/instance.properties
   PID=`cat $INSTANCES_FILE | grep "item.0.pid" | awk -F "=" '{print $2}'`
   kill $PID
      for i in {1..5};
        do
            if ps -p $PID > /dev/null; then
                echo "Fabric has been successfully stopped"
                break
            else
                sleep 3
            fi
        done
}
{'fraction_non_alphanumeric': 0.11197916666666667, 'fraction_numerical': 0.015625, 'mean_word_length': 2.300429184549356, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '683073', 'n_tokens_mistral': 275, 'n_tokens_neox': 249, 'n_words': 71}