<commit_before>#!/bin/sh
# Fixes https://github.com/gitlabhq/gitlabhq/issues/9891 :
# mailroom respawn loop pinning the CPU.

if [ x$2 = x15 ] ; then
  # mailroom received SIGTERM (15) so this is probably a
  # user-initiated restart. Skip the waiting.
  exit 0
fi

# If the user runs 'gitlab-ctl restart mailroom' during this sleep
# they may get a timeout, unfortunately.
wait=30
echo "Runit: waiting ${wait} seconds before restarting mail_room"
sleep ${wait}<commit_msg>We don't want a timeout which will cause reconfigure to fail<commit_after>#!/bin/sh
# Fixes https://github.com/gitlabhq/gitlabhq/issues/9891 :
# mailroom respawn loop pinning the CPU.

if [ x$2 = x15 ] ; then
  # mailroom received SIGTERM (15) so this is probably a
  # user-initiated restart. Skip the waiting.
  exit 0
fi

wait=5
echo "Runit: waiting ${wait} seconds before restarting mail_room"
sleep ${wait}
{'fraction_non_alphanumeric': 0.10180995475113122, 'fraction_numerical': 0.026018099547511313, 'mean_word_length': 4.175438596491228, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, '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': '2371371', 'n_tokens_mistral': 309, 'n_tokens_neox': 293, 'n_words': 107}