Commit Graph

14 Commits

Author SHA1 Message Date
Marc Schier 9830e5d53e Enable roslynizer and fix all analyzer issues (#3157)
* Fix warnings and suggestions
* Enable roslynator
2025-08-16 04:10:24 -07:00
romanett 978dfe9fd6 [Server] Add Support for Sampling Groups to CustomNodeManager (#3075)
* extend MonitoredItem manager
* Update MonitoredItem List with event montiored items
* Update comments
* Add SetMonitoringMode function call to SubscriptionTest
* Enable use of Sampling Groups in Reference Node Manager
* set minimum sampling interval for Sampling Groups
* Dispose SamplingGroups on shutdown and cleanup
2025-08-06 18:41:09 +02:00
Martin Regen a1c2216c2c Improvements for client keep alive timers and locks in subscriptions and sessions (#2427)
Issue: 
- On high load, the keep alive timers keep firing and may get blocked in locks, leading to thread starvation.
- The `AsyncAutoResetEvent` for subscriptions is triggered from the reader loop inside a lock and the following execution on the subscription workload blocks the reader thread.
- A reconnect is never triggered on a 'BadSessionIdInvalid`

Fixes: 
- Use periodic timer for platforms supporting it
- Make the `PublishingStopped` and lastkeepalive non blocking by using interlocked variables.
- To decouple the reader loop from the subscription processing, create the TaskCompletionSource with `TaskCreationOptions.RunContinuationsAsynchronously` option.
- Trigger a reconnect if the KeepAlive read request returns with a bad service result.
- Remove unnecessary locks around events, changed calls to be thread safe
2023-12-29 12:29:00 +01:00
Martin Regen abfbde3bec Improvements for docker hosting and fix for GetEndpoints (#2123)
- Add environment variables as parameter to support docker hosting where command line parameter are not available
- bump some Nuget packages
- only warn on cert validation error on startup, e.g. when the CRL becomes outdated allow to start and print warning.
- Let GetEndpoints return endpoints which match the DNS name used. DNS names must be specified as alternate hostnames in the configuration.
2023-04-18 18:09:55 +02:00
Martin Regen 1fec89b073 Complex types improvements (#1915)
Improvements for complex types.

- Support to encode/decode complex type structures with multidimensional arrays.
- Perf improvements for type loader using new NodeCache fetch multiple interfaces.
- DataTypeDictionary validation when dependencies are used.
- interface for complex type resolver, to build custom types in code.
- improvements of console client to demonstrate browse/read of custom values

+++ Breaking changes +++

IDecoder interface change of the `ReadArray` method

- Return type is now `Array` for all types of arrays. Previously the method returned an array for 1-dim and a `Matrix` type for multidimensional arrays. In addition the convention in generated code is to use `Collection` for all 1-dim arrays, and so was built the `BaseComplexType`. The new convention is to expose the native `Array` type from a complex type, in all cases, hence the return type of `ReadArray` was changed to reflect that for a consistent programming model.
- `ReadArray` has a new parameter `systemType` to efficiently read encodeable types. Previously the `Type` of an encodeable was determined by the encodingid and lookup in the type factory, even when the Type is already known by the caller.  The 'old' style is still supported.
- `ReadArray` supports to read encodeable type arrays which are directly encoded in structures. These arrays differ from standard encoding of arrays and they are handled when `BuiltInType.Null` is used as parameter.
2022-10-04 19:45:26 +02:00
Martin Regen 7072fe0771 Improve ref server for use with CTT (#1775)
- Improve formatting and log strings for new alarm node managers.
- Remove the TestData Alarms as they cause issues in the CTT tests
- Add a -ctt option to start the alarms endless for testing, stop alarms in other node managers.
- Unify the way the node managers are created in the quickstarts sample.
- Bring back 'dummy' appveyor config to disable the builds.
- fix codecov build
- add a few more unrelated tests
2022-04-19 09:29:21 +02:00
Martin Regen 8ddda78aff Fix for Usertokenpolicy Anonymous, security policy default should be None (#1756)
- Only an issue if the configuration does not specify the security policy uri for anonymous token
- If the config does not specify the security policy, for anonymous user token the security profile Basic256Sha256 was chosen. 
- This setting requires for the client to trust the server certificate if it tries to connect with security None, may cause IOP issues when no security is chosen and encryption is required for the anonymous user token.
2022-03-30 09:20:13 +02:00
Martin Regen 7d9be41cf5 Doc updates and fixes for .368 preview, ref server improvements (#1695)
- Doc, docs, docs updates for new 368 support
- fix a missing null pointer check when ConditionRefresh is run
- Ref server: move NodeManager factory API to StandardServer, decoupling the NodeManager implementation from Ref server
- Ref server: add shadow mode flag, to allow to map a docker configuration in a mapped folder.
- Ref server: sample batch files how to run Github CR and local docker images
- Improve some misleading 'delete application certificate' log messages.
2022-02-11 09:19:40 +01:00
Martin Regen a147eb55c5 Tracing and Logging improvements for the UA Core and libraries (#1631)
- support for Microsoft.Extensions.Logger.ILogger in Opc.Ua.Core as the new logging interface
- backward compatible with config and TraceEvents
- new API Utils.SetLogger allows to set ILogger
- updated Console samples to demonstrate ILogger support with Serilog
- support for EventSource logging
- see Docs/Logging.md for more info
2021-12-16 00:20:08 +01:00
Martin Regen 46ada27179 Add certificate password provider interface to support password protected pfx files. (#1291)
* Add a certificate password provider.
2021-02-23 11:31:42 +02:00
Martin Regen 19a9aa4890 Add Serilog sample to ref servers (#1263)
- the Serilog trace event logger replaces the default log output file 
- optional logging to console / debug
2021-02-02 07:19:30 +01:00
AlinMoldovean 764c481405 Update Copyright year to 2020 2020-10-07 18:04:34 +03:00
Martin Regen e7d8214798 Fix for self signed certs (#1036)
- The self signed certs should have the CA flag set
- small cleanup fixes for cert code
- make sure public key is always disposed
- breaking change: defaults for certs naming convention was not quite right and it should be a readonly, to make sure policy changes are reflected in calling code
- add test cases for validation of extension
2020-07-06 18:40:51 +02:00
Alin Moldovean 5faf85a7b9 Create Applications folder with ReferenceClient/Server (#1015)
* Clean UA Reference solution

* Move ReferenceClient/Server

* Copy Client/ServerControls libraries
Fix project references

* Rename docs to Docs

* Rename GDS libraries according to naming convention
2020-06-15 09:36:09 +03:00