mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Valery Kharseko
5 hours ago f251af3f68a38e2f83154ed80be92667326d286c
.github/scripts/replication/collect.sh
@@ -48,6 +48,7 @@
# The summary of the run, into $OUT/summary.md and, in GitHub Actions, the job summary
summarize() { # <result>
  local completed=0
  {
    echo "### Replication convergence ($TOPOLOGY): $1"
    echo
@@ -57,13 +58,19 @@
    echo "| load | $DURATION s on each directory server, at most $LOAD_MOD_RATE modifications and $LOAD_ADD_RATE adds or deletes a second |"
    echo "| seeded users | $SAMPLE_DATA |"
    if [ -s "$OUT/disturbances.txt" ]; then
      completed=$(wc -l <"$OUT/disturbances.txt")
      awk -v start="${LOAD_START_MS:-0}" '{ printf "| disturbance | %s of %s %d s into the load, serving again %d s later |\n",
                                            $4, $3, ($1 - start) / 1000, ($2 - $1) / 1000 }' "$OUT/disturbances.txt"
    elif [ "$DISTURBANCE" != none ] && [ -z "${LOAD_START_MS:-}" ]; then
    fi
    if [ "$DISTURBANCE" != none ] && [ -z "${LOAD_START_MS:-}" ]; then
      # run.sh sets LOAD_START_MS as the load starts
      echo "| disturbance | $DISTURBANCE at $DISTURB_AT s into the load, not started: the run ended before the load |"
    elif [ "$DISTURBANCE" != none ]; then
      echo "| disturbance | $DISTURBANCE at $DISTURB_AT s into the load, not completed |"
    elif [ "$DISTURBANCE" != none ] && [ "$completed" -lt "$DISTURB_STEPS" ]; then
      if [ "$completed" -eq 0 ]; then
        echo "| disturbance | $DISTURBANCE scheduled at $DISTURB_AT s into the load, not completed: 0 of $DISTURB_STEPS steps completed |"
      else
        echo "| disturbance | $DISTURBANCE not completed: $((completed)) of $DISTURB_STEPS steps completed |"
      fi
    fi
    echo "| converged | ${CONVERGED_IN:--} s after the load |"
    if [ -s "$OUT/samples.txt" ]; then
@@ -96,7 +103,7 @@
    fi
    if ls "$OUT"/logs/*.expected >/dev/null 2>&1; then
      echo
      echo "Handshakes failed while a disturbed server came back, which the disturbance expects (logs/*.expected):"
      echo "Errors logged while a disturbed server went down and came back, which the disturbance expects - failed handshakes, and what a kill leaves behind (logs/*.expected):"
      echo
      echo '```'
      for f in "$OUT"/logs/*.expected; do