Skip to content

Conversation

@jakub-id
Copy link
Contributor

No description provided.

validate that transaction has a selected supplier when accepting
requesting agency message, this avoid cryptic errors logged later
when the message cannot be send out by the client
@jakub-id jakub-id requested a review from Copilot August 27, 2025 11:56
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR consolidates error handling for supplier validation by merging multiple error constants into a single, more generic error message and implementing comprehensive supplier validation for requesting agency messages.

  • Replaces distinct supplier error constants with a unified SupplierNotFoundOrInvalid error
  • Adds supplier validation logic to requesting agency message handling
  • Updates tests to cover new validation scenarios including wrong symbols and skipped suppliers

Reviewed Changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.

File Description
broker/handler/iso18626-handler.go Consolidates error constants and adds supplier validation to requesting agency message handler
broker/client/client.go Makes broker symbol variable private for consistency
broker/test/handler/iso18626-handler_test.go Updates test assertions and adds comprehensive test cases for supplier validation
broker/test/testdata/reqmsg-notification.xml Adds test data file for notification message testing

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@jakub-id jakub-id requested a review from adamdickmeiss August 27, 2025 13:02
@jakub-id jakub-id merged commit 5a22edf into main Aug 27, 2025
4 checks passed
@jakub-id jakub-id deleted the handler-validate-supplier branch August 27, 2025 18:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants