Skip to content

Commit

Permalink
Log missing chain head as warning, not trace (hyperledger#6127)
Browse files Browse the repository at this point in the history
Signed-off-by: Matthew Whitehead <matthew1001@gmail.com>
  • Loading branch information
matthew1001 authored and NickSneo committed Nov 12, 2023
1 parent 27ab0f8 commit 2fd748b
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ private ValidationResult<TransactionInvalidReason> addTransaction(
return ValidationResult.invalid(rejectReason);
}
} else {
LOG.atTrace()
LOG.atWarn()
.setMessage("Discard invalid transaction {}, reason {}")
.addArgument(transaction::toTraceLog)
.addArgument(validationResult.result::getInvalidReason)
Expand Down Expand Up @@ -420,7 +420,7 @@ private ValidationResultAndAccount validateTransaction(

final BlockHeader chainHeadBlockHeader = getChainHeadBlockHeader().orElse(null);
if (chainHeadBlockHeader == null) {
LOG.atTrace()
LOG.atWarn()
.setMessage("rejecting transaction {} due to chain head not available yet")
.addArgument(transaction::getHash)
.log();
Expand Down

0 comments on commit 2fd748b

Please sign in to comment.