Logging delay of submitted commands (#10912)

* Logging delay of submitted commands

This would have helped track down the timezone issue more quickly.

CHANGELOG_BEGIN
CHANGELOG_END

* Review feedback
This commit is contained in:
Oliver Seeliger 2021-09-20 08:43:22 +02:00 committed by GitHub
parent b8e21d8f48
commit b4541b5a4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -258,6 +258,7 @@ private[apiserver] final class ApiSubmissionService private[services] (
if (submissionDelay.isNegative)
submitTransaction(transactionInfo)
else {
logger.info(s"Delaying submission by $submissionDelay")
metrics.daml.commands.delayedSubmissions.mark()
val scalaDelay = scala.concurrent.duration.Duration.fromNanos(submissionDelay.toNanos)
Delayed.Future.by(scalaDelay)(submitTransaction(transactionInfo))