From ee1b6ac29e834d05b011c554b5b65ad263a11c7a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Tue, 16 Jul 2024 18:59:26 +0000 Subject: [PATCH] fix minor bug in lock handler (#1486) * fix minor bug in lock handler Signed-off-by: Subhobrata Dey * dummy commit Signed-off-by: Subhobrata Dey --------- Signed-off-by: Subhobrata Dey (cherry picked from commit b7eafbda146b59b596504773a1df42b70bb122d1) Signed-off-by: github-actions[bot] --- .github/workflows/test-workflow.yml | 2 +- .../kotlin/org/opensearch/alerting/MonitorRunnerService.kt | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test-workflow.yml b/.github/workflows/test-workflow.yml index 65d32abbb..d9328214c 100644 --- a/.github/workflows/test-workflow.yml +++ b/.github/workflows/test-workflow.yml @@ -52,7 +52,7 @@ jobs: cp ./alerting/build/distributions/*.zip alerting-artifacts # This step uses the codecov-action Github action: https://github.com/codecov/codecov-action - name: Upload Coverage Report - uses: codecov/codecov-action@v1 + uses: codecov/codecov-action@v3 with: token: ${{ secrets.CODECOV_TOKEN }} # This step uses the upload-artifact Github action: https://github.com/actions/upload-artifact diff --git a/alerting/src/main/kotlin/org/opensearch/alerting/MonitorRunnerService.kt b/alerting/src/main/kotlin/org/opensearch/alerting/MonitorRunnerService.kt index e3147a2d9..b949eefdf 100644 --- a/alerting/src/main/kotlin/org/opensearch/alerting/MonitorRunnerService.kt +++ b/alerting/src/main/kotlin/org/opensearch/alerting/MonitorRunnerService.kt @@ -353,7 +353,7 @@ object MonitorRunnerService : JobRunner, CoroutineScope, AbstractLifecycleCompon } } finally { monitorCtx.client!!.suspendUntil { monitorCtx.lockService!!.release(lock, it) } - logger.debug("lock ${lock!!.lockId} released") + logger.debug("lock ${lock?.lockId} released") } } } @@ -385,7 +385,7 @@ object MonitorRunnerService : JobRunner, CoroutineScope, AbstractLifecycleCompon } } finally { monitorCtx.client!!.suspendUntil { monitorCtx.lockService!!.release(lock, it) } - logger.debug("lock ${lock!!.lockId} released") + logger.debug("lock ${lock?.lockId} released") } } }