Skip to content

Commit

Permalink
Step Metadata Update on Index Rollover Timeout
Browse files Browse the repository at this point in the history
Signed-off-by: harycash <harycash@amazon.com>
  • Loading branch information
harycash committed May 29, 2024
1 parent ce33ce5 commit a8d7379
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -332,17 +332,17 @@ object ManagedIndexRunner :
val info = mapOf("message" to "Action timed out")
logger.error("Action=${action.type} has timed out")

val updatedMetaData = managedIndexMetaData.copy(
val updatedIndexMetaData = managedIndexMetaData.copy(
actionMetaData = currentActionMetaData?.copy(failed = true),
stepMetaData = step?.let { StepMetaData(it.name, System.currentTimeMillis(), Step.StepStatus.TIMED_OUT) },
info = info,
)

val updated = updateManagedIndexMetaData(updatedMetaData)
val updated = updateManagedIndexMetaData(updatedIndexMetaData)

if (updated.metadataSaved) {
disableManagedIndexConfig(managedIndexConfig)
publishErrorNotification(policy, updatedMetaData)
publishErrorNotification(policy, updatedIndexMetaData)
}
return
}
Expand Down

0 comments on commit a8d7379

Please sign in to comment.