-
Notifications
You must be signed in to change notification settings - Fork 1k
Improve test stability of ValidateTransfer test, ensure thread safety in MonitoredItem #3243
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Replaced Queue with ConcurrentQueue in MonitoredItemDataCache for thread-safe operations. Updated Publish method to use List<DataValue> for better handling of dequeued values. Enhanced logging to include SourceTime and added logs for dropped values. In DurableSubscriptionTest, added try-finally block to ensure proper session closure and disposal, preventing memory leaks. Introduced DurableSubscriptionTestLooper for stress testing under debug mode. Refactored test code for improved readability.
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## master #3243 +/- ##
==========================================
- Coverage 57.77% 57.70% -0.07%
==========================================
Files 362 362
Lines 79251 79301 +50
Branches 13840 13853 +13
==========================================
- Hits 45786 45760 -26
- Misses 29242 29293 +51
- Partials 4223 4248 +25 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
cristipogacean
approved these changes
Oct 8, 2025
…dard into teststability
romanett
reviewed
Oct 8, 2025
romanett
reviewed
Oct 8, 2025
romanett
approved these changes
Oct 8, 2025
Updated logging in `Session.cs`, `ServerBase.cs`, and `UaSCBinaryClientChannel.cs` to pass exceptions directly to the logger, enhancing error handling. Added connection state checks in `Session.cs` to prevent operations when the session is closed or never connected. Updated `Subscription.cs` to reflect session disconnection in `PublishingStopped`. Enhanced test outputs and renamed `DurableSubscriptionTestLooper` to `DurableSubscriptionTestDebug` in `DurableSubscriptionTest.cs`, reducing loop count for faster debug testing.
… allocate a free monitored item id in the table, then committing.
romanett
reviewed
Oct 9, 2025
romanett
reviewed
Oct 9, 2025
mrsuciu
approved these changes
Oct 9, 2025
Added detailed logging in `AlarmNodeManager.cs` for lifecycle events and simulation control. Introduced a `Reconnecting` property in the `ISession` interface and `Session.cs` to manage session reconnection state, replacing the `m_reconnecting` field. Enhanced logging in `Session.cs` for reconnection and publish operations. Updated `DataGenerator.cs` to use `FrozenDictionary` for performance improvements. Replaced `SyncRoot` with `m_syncRoot` in `NamespaceTable.cs` for synchronization. Improved exception message formatting in `ServiceResult.cs`. Added necessary namespaces for new data structures. Made corrections and added debugging in `DurableSubscriptionTest.cs` for better session handling.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Replaced Queue with ConcurrentQueue in MonitoredItemDataCache for thread-safe operations. Updated Publish method to use List for better handling of dequeued values. Enhanced logging to include SourceTime and added logs for dropped values.
In DurableSubscriptionTest, added try-finally block to ensure proper session closure and disposal, preventing memory leaks. Introduced DurableSubscriptionTestLooper for stress testing under debug mode. Refactored test code for improved readability.
Proposed changes
Describe the changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
Related Issues
Types of changes
What types of changes does your code introduce?
Put an
xin the boxes that apply. You can also fill these out after creating the PR.Checklist
Put an
xin the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.Further comments
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...