Skip to content

Skip logging duplicate keygen errors#58

Merged
anhthii merged 1 commit intomasterfrom
fix/skip-logging-error-if-duplicate-key
Jul 17, 2025
Merged

Skip logging duplicate keygen errors#58
anhthii merged 1 commit intomasterfrom
fix/skip-logging-error-if-duplicate-key

Conversation

@anhthii
Copy link
Contributor

@anhthii anhthii commented Jul 17, 2025

  • Introduce composeKeygenIdempotentKey to generate an idempotent key based on walletID and the NATS SessionID header

  • Update all genKeyResultQueue.Enqueue calls to use the composed idempotent key

  • Remove the verbose logger.Warn("Keygen session error", …) block to avoid logging expected duplicate‐event errors

Extend PubSub.PublishWithReply to accept a headers map and propagate a unique SessionID on each publish

  • Update keygenConsumer and signingConsumer to include a randomly generated SessionID header on every PublishWithReply call

This is to fix #56

@anhthii anhthii changed the title Skip logging duplicate keygen errors and add idempotency via SessionID Skip logging duplicate keygen errors Jul 17, 2025
@anhthii anhthii merged commit 1bad9a7 into master Jul 17, 2025
19 checks passed
@anhthii anhthii deleted the fix/skip-logging-error-if-duplicate-key branch July 17, 2025 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Repeatedly create the same walletID

1 participant

Comments