Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NIAD-2889: Bugfix - add additional JMS error handling #345

Merged
merged 7 commits into from
Oct 27, 2023

Conversation

benhession
Copy link
Contributor

@benhession benhession commented Oct 26, 2023

What

  • Add extra handling and logging to the JMS Listener error handler.
  • Remove unused SQL statement logging

Why

If an exception is thrown with a null cause the handler itself throws an exception. This prevents the JMS message delivery count property from being updated and leads to the message being dequeued repeatedly.

The null pointer would also prevent any logging of the exception message. Therefore, in addition to handling an unexpected exception without a cause, extra logging has been added.

SQL statement logging had been setup during development but was not configurable to be used by the end user. When saving the inbound message, the logging statement placed the statement, including the entire message on the stack. Testing the service with a very low heap size (128 MB), this logging caused an out of memory error.

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have performed a self-review of my code
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have updated the Changelog with details of my change in the UNRELEASED section if this change will affect end users
  • A corresponding change has been made to the Mapping Documentation repository

@benhession benhession marked this pull request as ready for review October 26, 2023 16:50
CHANGELOG.md Outdated Show resolved Hide resolved
@benhession benhession enabled auto-merge (squash) October 27, 2023 13:53
@benhession benhession merged commit 584c470 into main Oct 27, 2023
@benhession benhession deleted the NIAD-2889-bugfix-jms-nullpointer branch October 27, 2023 13:53
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.

2 participants