Release date: 2023-10-31
The docker images for the Node come with Python pre-installed. The version has now been updated to 3.11.
For Nodes that run on Windows, Python has​ to be manually installed.
Previously we had JSON converters that would convert strings into DateTime, DateOnly and TimeOnly.
No conversion will be attempted for these types and they will remain as strings in the FlowMessage.
The default JsonNamingPolicy has been changed to CamelCase. Previously there was no JsonNamingPolicy.
PropertyNamingPolicy = JsonNamingPolicy.CamelCase,
DictionaryKeyPolicy = JsonNamingPolicy.CamelCase,
The default setting for the number of pings between status reports was changed from 0 to 5.
You will not get the new default settings unless you delete the configuration files. The easiest way to get the default settings is to delete all *.json files in the data folder and restart the Node.
All messages containing Flow information will now have these additional properties.
"flowDefinitionId": "62df9488-7ff3-403c-ac48-52c5eb61ae37",
"nodeId": "27929e60-a586-4f51-a512-0583391b0c86",
"nodeName": "Machine123",
Flow Status will contain the properties mentioned above, but will also have a list with reasons for the new status.
{
"flowId": "2220e7a7-9e98-4af3-afd4-a1b309128540",
"flowDefinitionId": "6faf4080-c7ce-e642-37a0-43e965904899",
"flowName": "Example MQTT Notifications",
"version": 9,
"status": "Warning",
"reason": "Flow status changed to Warning",
"reasons": [
{
"moduleId": "9c3727c6-7d64-4cb3-95eb-a597596068b2",
"moduleName": "OPC UA Reader",
"moduleType": "Crosser.EdgeNode.Modules.OPC.UA.Reader",
"version": "2.3.0",
"status": "Warning",
"reason": "Module OPC UA Reader, 2.3.0 changed to status Warning: This is a test",
"timestamp": "2023-09-28T13:22:51.743+00:00"
}
],
"nodeId": "27929e60-a586-4f51-a512-0583391b0c86",
"nodeName": "Machine123",
"timestamp": "2023-09-28T13:22:51.743+00:00"
}
Module messages (status, message dropped and dead letter) will contain the properties mentioned above, but also have moduleType included.
{
"moduleId": "9c3727c6-7d64-4cb3-95eb-a597596068b2",
"moduleName": "OPC UA Reader",
"moduleType": "Crosser.EdgeNode.Modules.OPC.UA.Reader",
"version": "2.3.0",
"status": "Warning",
"flowId": "2220e7a7-9e98-4af3-afd4-a1b309128540",
"flowDefinitionId": "6faf4080-c7ce-e642-37a0-43e965904899",
"flowName": "Example MQTT Notifications",
"reason": "Module OPC UA Reader, 2.3.0 changed to status Warning: This is a test",
"queue": {
"mode": "DropWrite",
"size": 100,
"retries": 3,
"retryDelay": 500,
"delay": 0,
"persistence": true
},
"nodeId": "27929e60-a586-4f51-a512-0583391b0c86",
"nodeName": "Machine123",
"timestamp": "2023-09-28T13:22:51.690+00:00"
}
To make it easier to understand the lifetime of external connections to the host the logging was increased for HTTP and MQTT. Additional information was added about protocol and remote IP.
[HOST ]: 2023-10-12 16:08:06.264 [Information] "HttpConnection" "127.0.0.1:49856", connection accepted: a44c1397-1255-4b51-bf11-75b668521706
[HOST ]: 2023-10-12 16:08:06.268 [Information] "HttpConnection" "127.0.0.1:49856", connection closed: a44c1397-1255-4b51-bf11-75b668521706
[HOST ]: 2023-10-12 16:10:12.266 [Information] "MqttConnection" "127.0.0.1:55568", connection started: 584cdb0e-b00b-4893-bef2-b4fc25708c7d
[HOST ]: 2023-10-12 16:10:12.290 [Information] "MqttConnection" "127.0.0.1:55568", connection accepted: 584cdb0e-b00b-4893-bef2-b4fc25708c7d
[HOST ]: 2023-10-12 16:09:17.730 [Error ] "HttpConnection" "127.0.0.1:45838", connection error: 491ec7c8-6d72-4502-86a0-7d6e4f3d8236
System.OperationCanceledException: The operation was canceled.
at System.Threading.CancellationToken.ThrowOperationCanceledException()
at System.Threading.CancellationToken.ThrowIfCancellationRequested()
at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
at System.IO.BufferedStream.ReadFromUnderlyingStreamAsync(Memory`1 buffer, CancellationToken cancellationToken, Int32 bytesAlreadySatisfied, Task semaphoreLockTask)
at Crosser.EdgeNode.Core.Net.Tcp.TcpConnection.ReadAsync(Memory`1 buff) in /home/crosser/repositories/crosser/EdgeNode/src/Core/Crosser.EdgeNode.Core/Net/Tcp/TcpConnection.cs:line 301
[HOST ]: 2023-10-12 16:09:17.731 [Information] "HttpConnection" "127.0.0.1:45838", connection closed: 491ec7c8-6d72-4502-86a0-7d6e4f3d8236
[HOST ]: 2023-10-12 16:10:43.102 [Information] "MqttConnection" "127.0.0.1:35574", connection started: c98bf944-afbf-40fd-a3d9-d80b3d467885
[HOST ]: 2023-10-12 16:10:53.147 [Error ] "MqttConnection" "127.0.0.1:35574", connection error: c98bf944-afbf-40fd-a3d9-d80b3d467885
System.OperationCanceledException: The operation was canceled.
at System.Threading.CancellationToken.ThrowOperationCanceledException()
at System.Threading.CancellationToken.ThrowIfCancellationRequested()
at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.ThrowException(SocketError error, CancellationToken cancellationToken)
at System.Net.Sockets.Socket.AwaitableSocketAsyncEventArgs.System.Threading.Tasks.Sources.IValueTaskSource<System.Int32>.GetResult(Int16 token)
at System.IO.BufferedStream.ReadFromUnderlyingStreamAsync(Memory`1 buffer, CancellationToken cancellationToken, Int32 bytesAlreadySatisfied, Task semaphoreLockTask)
at Crosser.EdgeNode.Core.Net.Mqtt.MqttConnection.ReadByteAsync() in /home/crosser/repositories/crosser/EdgeNode/src/Core/Crosser.EdgeNode.Core/Net/Mqtt/MqttConnection.cs:line 168
[HOST ]: 2023-10-12 16:10:53.147 [Information] "MqttConnection" "127.0.0.1:35574", connection closed: c98bf944-afbf-40fd-a3d9-d80b3d467885
When having retries enabled without persistence enabled there was no warning triggered when the retry attempts ran out.
When having only one module connected to a disabled module the module would still send messages to the next module.
Since query-strings was not decoded values like test=hello%20world would become
{'test': 'hello%20world' }
The result will now be:
{ 'test': 'hello world' }
This could happen when having persistence disabled and using filter properties that were not present on the incoming message.
If we have a FlowMessage {"id": 123} and then try to set id.test to foo we get a null reference exception.
The FlowMessage should respect the requested change and be altered to:
{'id': {'test': 'foo'}}
If we have a FlowMessage that looks like { 'value': 123 } and use Has<bool>("value"), for example in the C# module or the SDK, the result will be false. However, if we have { 'sensor': { 'value': 123 } } and use Has<bool>("value") the result would be true since a bug caused the method to only check that a property exist on lower level, but not that the type of T is a match.
If more than 10 connections were made to the local endpoints but no data was sent the queue would be full and no more connections could be opened.
This behavior has now been changed and new connections will not block the connections queue. A timeout has also been added for clients connecting so that we do not get idle connections using the resources.
These flows will work in remote sessions, but will fail when deployed due to a comparison on versions that will be different in remote session vs deployments.
This bug was introduced in 2.6.2 and was fixed in 3.0.0.