Azure / iot-edge-modbus

Modbus protocol module for use with the Azure IoT Edge
Other
90 stars 71 forks source link

Token and TLS handshake #35

Closed termocontrole closed 6 years ago

termocontrole commented 6 years ago

Hi @606simps,

I openned an issue with the IoT Edge team and solved it, but I have 2 doubts that they said to ask here, please, see if you can help.

All the data that is being sent by the IoT Edge is received by IoT Hub (I used Stream Analytics to measure that).

Here is my edgeHub log:

2018-03-27 13:51:03.528 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 13:51:03.529 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 13:51:03.627 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 45 with batch size 10.
2018-03-27 13:51:03.628 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 46.
2018-03-27 13:51:03.629 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 46 with batch size 10.
2018-03-27 13:51:03.629 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 46.
2018-03-27 13:51:03.858 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 13:51:04.998 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Getting new token for TC-IoT-Edge/modbus.
2018-03-27 13:51:04.999 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Existing token not found for TC-IoT-Edge/modbus. Getting new token from the client...
2018-03-27 13:51:05.000 +00:00 [WRN] [ProtocolGateway] - Closing connection for device: TC-IoT-Edge/modbus, Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnectionException: Connection closed for device TC-IoT-Edge/modbus., 
2018-03-27 13:51:05.001 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Disposing MessagingServiceClient for device Id TC-IoT-Edge/modbus because of exception - Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnectionException: Connection closed for device TC-IoT-Edge/modbus.
2018-03-27 13:51:05.002 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.DeviceProxy] - Closing device proxy for device Id TC-IoT-Edge/modbus
2018-03-27 13:51:05.002 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - Device connection removed for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.003 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnection] - Updating device TC-IoT-Edge/modbus connection status to Disconnected
2018-03-27 13:51:05.213 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Obtained new token for client TC-IoT-Edge/modbus that expires in 00:59:59.7868522
2018-03-27 13:51:05.213 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Updated cloud connection for client TC-IoT-Edge/modbus
2018-03-27 13:51:05.213 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - New cloud connection created for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.213 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Authenticator] - Successfully authenticated device TC-IoT-Edge/modbus
2018-03-27 13:51:05.214 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SasTokenDeviceIdentityProvider] - Successfully generated identity for clientId TC-IoT-Edge/modbus and username HIDDEN
2018-03-27 13:51:05.214 +00:00 [INF] [ProtocolGateway] - ClientAuthenticated, TC-IoT-Edge/modbus, 5c147a81
2018-03-27 13:51:05.214 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - Obtained cloud connection for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.216 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Binding cloud listener for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.216 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - New device connection for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.216 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnection] - Updating device TC-IoT-Edge/modbus connection status to Connected
2018-03-27 13:51:05.225 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Device.DeviceMessageHandler] - Bind device proxy for device TC-IoT-Edge/modbus
2018-03-27 13:51:05.225 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Binding message channel for device Id TC-IoT-Edge/modbus
2018-03-27 13:51:05.226 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription $iothub/twin/res/# for client TC-IoT-Edge/modbus.
2018-03-27 13:51:05.226 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription devices/TC-IoT-Edge/modules/modbus/# for client TC-IoT-Edge/modbus.
2018-03-27 13:51:05.227 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription $iothub/twin/PATCH/properties/desired/# for client TC-IoT-Edge/modbus.
2018-03-27 13:51:05.228 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStateStoragePersistenceProvider] - Set subscriptions from session state for TC-IoT-Edge/modbus
2018-03-27 13:51:05.244 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Updating reported properties for device TC-IoT-Edge/$edgeHub
2018-03-27 13:51:05.244 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Successfully sent reported properties to cloud for TC-IoT-Edge/$edgeHub and reported properties version 0
2018-03-27 13:51:05.246 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Updated cached reported property for TC-IoT-Edge/$edgeHub at reported property version 841 cloudVerified True
2018-03-27 13:51:07.360 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Updating reported properties for device TC-IoT-Edge/$edgeHub
2018-03-27 13:51:07.361 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Successfully sent reported properties to cloud for TC-IoT-Edge/$edgeHub and reported properties version 0
2018-03-27 13:51:07.365 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Updated cached reported property for TC-IoT-Edge/$edgeHub at reported property version 841 cloudVerified True
2018-03-27 13:53:34.732 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 13:53:34.732 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 13:53:34.734 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 46 with batch size 10.
2018-03-27 13:53:34.735 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 47.
2018-03-27 13:53:34.735 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 47 with batch size 10.
2018-03-27 13:53:34.736 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 47.
2018-03-27 13:53:34.941 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 13:54:46.035 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of stores
2018-03-27 13:54:46.038 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store checkpoints
2018-03-27 13:54:46.070 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store sessions
2018-03-27 13:54:46.089 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store twins
2018-03-27 13:54:46.105 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store iothub
2018-03-27 13:54:46.120 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store messages
2018-03-27 13:54:46.139 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Storage.RocksDb.DbStoreProvider] - Starting compaction of store default
2018-03-27 13:56:05.749 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 13:56:05.749 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 13:56:05.752 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 47 with batch size 10.
2018-03-27 13:56:05.847 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 48.
2018-03-27 13:56:05.848 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 48 with batch size 10.
2018-03-27 13:56:05.848 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 48.
2018-03-27 13:56:06.292 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 13:56:23.803 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Started task to cleanup processed and stale messages for endpoint iothub
2018-03-27 13:56:23.803 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Checkpoint for endpoint iothub is 47
2018-03-27 13:56:23.917 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Cleaned up 12 messages from queue for endpoint iothub and 12 messages from message store.
2018-03-27 13:56:23.918 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Total messages cleaned up from queue for endpoint iothub = 48, and total messages cleaned up for message store = 48.
2018-03-27 13:58:36.761 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 13:58:36.762 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 13:58:36.764 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 48 with batch size 10.
2018-03-27 13:58:36.766 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 49.
2018-03-27 13:58:36.767 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 49 with batch size 10.
2018-03-27 13:58:36.866 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 49.
2018-03-27 13:58:37.107 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:01:07.779 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:01:07.779 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:01:07.781 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 49 with batch size 10.
2018-03-27 14:01:07.881 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 50.
2018-03-27 14:01:07.882 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 50 with batch size 10.
2018-03-27 14:01:07.883 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 50.
2018-03-27 14:01:08.164 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:03:38.789 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:03:38.790 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:03:38.792 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 50 with batch size 10.
2018-03-27 14:03:38.794 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 51.
2018-03-27 14:03:38.795 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 51 with batch size 10.
2018-03-27 14:03:38.796 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 51.
2018-03-27 14:03:39.069 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:06:09.808 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:06:09.808 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:06:09.811 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 51 with batch size 10.
2018-03-27 14:06:09.813 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 52.
2018-03-27 14:06:09.813 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 52 with batch size 10.
2018-03-27 14:06:09.814 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 52.
2018-03-27 14:06:10.053 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:08:40.809 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:08:40.809 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:08:40.811 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 52 with batch size 10.
2018-03-27 14:08:40.904 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 53.
2018-03-27 14:08:40.904 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 53 with batch size 10.
2018-03-27 14:08:40.904 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 53.
2018-03-27 14:08:41.135 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:11:11.818 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:11:11.818 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:11:11.909 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 53 with batch size 10.
2018-03-27 14:11:11.911 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 54.
2018-03-27 14:11:11.911 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 54 with batch size 10.
2018-03-27 14:11:11.912 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 54.
2018-03-27 14:11:12.392 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:13:42.913 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:13:42.914 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:13:42.916 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 54 with batch size 10.
2018-03-27 14:13:42.918 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 55.
2018-03-27 14:13:42.919 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 55 with batch size 10.
2018-03-27 14:13:42.920 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 55.
2018-03-27 14:13:43.167 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:16:13.928 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:16:13.929 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:16:13.931 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 55 with batch size 10.
2018-03-27 14:16:13.933 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 56.
2018-03-27 14:16:13.935 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 56 with batch size 10.
2018-03-27 14:16:14.033 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 56.
2018-03-27 14:16:14.229 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:18:44.948 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:18:44.949 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:18:44.951 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 56 with batch size 10.
2018-03-27 14:18:45.049 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 57.
2018-03-27 14:18:45.049 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 57 with batch size 10.
2018-03-27 14:18:45.050 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 57.
2018-03-27 14:18:45.312 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:21:15.948 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:21:15.948 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:21:15.951 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 57 with batch size 10.
2018-03-27 14:21:15.953 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 58.
2018-03-27 14:21:15.954 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 58 with batch size 10.
2018-03-27 14:21:15.955 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 58.
2018-03-27 14:21:16.199 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:23:46.968 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:23:46.968 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:23:46.971 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 58 with batch size 10.
2018-03-27 14:23:47.078 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 59.
2018-03-27 14:23:47.085 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 59 with batch size 10.
2018-03-27 14:23:47.086 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 59.
2018-03-27 14:23:47.335 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:26:17.989 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:26:18.083 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:26:18.087 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 59 with batch size 10.
2018-03-27 14:26:18.089 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 60.
2018-03-27 14:26:18.090 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 60 with batch size 10.
2018-03-27 14:26:18.095 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 60.
2018-03-27 14:26:18.273 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:26:53.925 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Started task to cleanup processed and stale messages for endpoint iothub
2018-03-27 14:26:53.925 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Checkpoint for endpoint iothub is 59
2018-03-27 14:26:54.079 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Cleaned up 12 messages from queue for endpoint iothub and 12 messages from message store.
2018-03-27 14:26:54.079 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Total messages cleaned up from queue for endpoint iothub = 60, and total messages cleaned up for message store = 60.
2018-03-27 14:28:49.098 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:28:49.099 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:28:49.101 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 60 with batch size 10.
2018-03-27 14:28:49.103 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 61.
2018-03-27 14:28:49.103 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 61 with batch size 10.
2018-03-27 14:28:49.104 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 61.
2018-03-27 14:28:49.323 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:31:20.122 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:31:20.123 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:31:20.126 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 61 with batch size 10.
2018-03-27 14:31:20.204 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 62.
2018-03-27 14:31:20.204 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 62 with batch size 10.
2018-03-27 14:31:20.204 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 62.
2018-03-27 14:31:20.471 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:33:51.154 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:33:51.155 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:33:51.160 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 62 with batch size 10.
2018-03-27 14:33:51.261 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 63.
2018-03-27 14:33:51.263 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 63 with batch size 10.
2018-03-27 14:33:51.264 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 63.
2018-03-27 14:33:51.497 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:36:22.169 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:36:22.169 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:36:22.174 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 63 with batch size 10.
2018-03-27 14:36:22.176 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 64.
2018-03-27 14:36:22.176 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 64 with batch size 10.
2018-03-27 14:36:22.177 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 64.
2018-03-27 14:36:22.360 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:38:53.189 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:38:53.189 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:38:53.194 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 64 with batch size 10.
2018-03-27 14:38:53.287 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 65.
2018-03-27 14:38:53.295 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 65 with batch size 10.
2018-03-27 14:38:53.296 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 65.
2018-03-27 14:38:53.524 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:41:24.209 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:41:24.209 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:41:24.312 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 65 with batch size 10.
2018-03-27 14:41:24.316 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 66.
2018-03-27 14:41:24.318 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 66 with batch size 10.
2018-03-27 14:41:24.319 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 66.
2018-03-27 14:41:24.504 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:43:55.320 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:43:55.320 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:43:55.323 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 66 with batch size 10.
2018-03-27 14:43:55.327 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 67.
2018-03-27 14:43:55.328 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 67 with batch size 10.
2018-03-27 14:43:55.328 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 67.
2018-03-27 14:43:55.681 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:46:26.332 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:46:26.333 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:46:26.335 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 67 with batch size 10.
2018-03-27 14:46:26.433 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 68.
2018-03-27 14:46:26.440 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 68 with batch size 10.
2018-03-27 14:46:26.441 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 68.
2018-03-27 14:46:26.663 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:48:57.343 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:48:57.343 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:48:57.346 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 68 with batch size 10.
2018-03-27 14:48:57.348 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 69.
2018-03-27 14:48:57.348 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 69 with batch size 10.
2018-03-27 14:48:57.349 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 69.
2018-03-27 14:48:57.638 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus
2018-03-27 14:49:05.007 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Getting new token for TC-IoT-Edge/modbus.
2018-03-27 14:49:05.017 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Existing token not found for TC-IoT-Edge/modbus. Getting new token from the client...
2018-03-27 14:49:05.018 +00:00 [WRN] [ProtocolGateway] - Closing connection for device: TC-IoT-Edge/modbus, Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnectionException: Connection closed for device TC-IoT-Edge/modbus., 
2018-03-27 14:49:05.019 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Disposing MessagingServiceClient for device Id TC-IoT-Edge/modbus because of exception - Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnectionException: Connection closed for device TC-IoT-Edge/modbus.
2018-03-27 14:49:05.019 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.DeviceProxy] - Closing device proxy for device Id TC-IoT-Edge/modbus
2018-03-27 14:49:05.019 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - Device connection removed for device TC-IoT-Edge/modbus
2018-03-27 14:49:05.020 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnection] - Updating device TC-IoT-Edge/modbus connection status to Disconnected
2018-03-27 14:49:05.288 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Updating reported properties for device TC-IoT-Edge/$edgeHub
2018-03-27 14:49:05.288 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Successfully sent reported properties to cloud for TC-IoT-Edge/$edgeHub and reported properties version 0
2018-03-27 14:49:05.291 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Updated cached reported property for TC-IoT-Edge/$edgeHub at reported property version 841 cloudVerified True
2018-03-27 14:49:05.297 +00:00 [WRN] [ProtocolGateway] - TLS handshake failed., System.IO.IOException: Channel is closed, 09c67dc6
2018-03-27 14:49:05.312 +00:00 [ERR] [DotNetty.Common.ResourceLeakDetector] - LEAK: IByteBuffer.Release() was not called before it's garbage-collected. Enable advanced leak reporting to find out where the leak occurred. To enable advanced leak reporting, set environment variable io.netty.leakDetection.level to advanced or set ResourceLeakDetector.Level in code. See http://netty.io/wiki/reference-counted-objects.html for more information.
2018-03-27 14:49:05.611 +00:00 [WRN] [ProtocolGateway] - TLS handshake failed., System.IO.IOException: Channel is closed, 352bfabd
2018-03-27 14:49:06.223 +00:00 [WRN] [ProtocolGateway] - TLS handshake failed., System.IO.IOException: Channel is closed, 50ded65c
2018-03-27 14:49:07.291 +00:00 [WRN] [ProtocolGateway] - TLS handshake failed., System.IO.IOException: Channel is closed, 6f15790f
2018-03-27 14:49:08.976 +00:00 [WRN] [ProtocolGateway] - TLS handshake failed., System.IO.IOException: Channel is closed, 0a1cd124
2018-03-27 14:49:12.794 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Obtained new token for client TC-IoT-Edge/modbus that expires in 01:00:00.2050982
2018-03-27 14:49:12.795 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudConnection] - Updated cloud connection for client TC-IoT-Edge/modbus
2018-03-27 14:49:12.795 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - New cloud connection created for device TC-IoT-Edge/modbus
2018-03-27 14:49:12.796 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Authenticator] - Successfully authenticated device TC-IoT-Edge/modbus
2018-03-27 14:49:12.796 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SasTokenDeviceIdentityProvider] - Successfully generated identity for clientId TC-IoT-Edge/modbus and username HIDDEN
2018-03-27 14:49:12.797 +00:00 [INF] [ProtocolGateway] - ClientAuthenticated, TC-IoT-Edge/modbus, 0f6f8e19
2018-03-27 14:49:12.797 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - Obtained cloud connection for device TC-IoT-Edge/modbus
2018-03-27 14:49:12.799 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Binding cloud listener for device TC-IoT-Edge/modbus
2018-03-27 14:49:12.799 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.ConnectionManager] - New device connection for device TC-IoT-Edge/modbus
2018-03-27 14:49:12.800 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.EdgeHubConnection] - Updating device TC-IoT-Edge/modbus connection status to Connected
2018-03-27 14:49:12.802 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Core.Device.DeviceMessageHandler] - Bind device proxy for device TC-IoT-Edge/modbus
2018-03-27 14:49:12.802 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Binding message channel for device Id TC-IoT-Edge/modbus
2018-03-27 14:49:12.803 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription $iothub/twin/res/# for client TC-IoT-Edge/modbus.
2018-03-27 14:49:12.803 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription devices/TC-IoT-Edge/modules/modbus/# for client TC-IoT-Edge/modbus.
2018-03-27 14:49:12.804 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStatePersistenceProvider] - Adding subscription $iothub/twin/PATCH/properties/desired/# for client TC-IoT-Edge/modbus.
2018-03-27 14:49:12.806 +00:00 [INF] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.SessionStateStoragePersistenceProvider] - Set subscriptions from session state for TC-IoT-Edge/modbus
2018-03-27 14:49:12.942 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Updating reported properties for device TC-IoT-Edge/$edgeHub
2018-03-27 14:49:12.942 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Successfully sent reported properties to cloud for TC-IoT-Edge/$edgeHub and reported properties version 0
2018-03-27 14:49:12.944 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.TwinManager] - Updated cached reported property for TC-IoT-Edge/$edgeHub at reported property version 841 cloudVerified True
2018-03-27 14:51:28.349 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Mqtt.MessagingServiceClient] - Sending message for device Id TC-IoT-Edge/modbus
2018-03-27 14:51:28.350 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Routing.RoutingEdgeHub] - Received message from TC-IoT-Edge/modbus
2018-03-27 14:51:28.352 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 69 with batch size 10.
2018-03-27 14:51:28.455 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 1. Next start offset = 70.
2018-03-27 14:51:28.456 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Getting next batch for endpoint iothub starting from 70 with batch size 10.
2018-03-27 14:51:28.456 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.Core.Storage.MessageStore] - Obtained next batch for endpoint iothub with batch size 0. Next start offset = 70.
2018-03-27 14:51:28.642 +00:00 [DBG] [Microsoft.Azure.Devices.Edge.Hub.CloudProxy.CloudProxy] - Sending message for device TC-IoT-Edge/modbus

If you look at my edgeHub logs, you are going to see that the modbus token is renewed every one hour, because the token is set to expire every one hour, is this default? Can I change the validity of this token somewhere?

Another question is that sometimes appers TLS handshake failed but does't seem to cause trouble to the data. Do you have any thoughts about this?

Thank you.

stephenctw commented 6 years ago

Hi @termocontrole ,

I updated the original issue you opened at iot-edge repo. Please take a look. You may want to reopen it.

Thanks, Stephen

termocontrole commented 6 years ago

Hi @606simps,

Thank you for your support, I reopened the original issue and I will let this one open too, when we solve the doubts I close it.

termocontrole commented 6 years ago

Hi,

As mentioned in the referenced issue, the validity of the modbus token can not be changed, and the TLS handshake failed failure is being tracked by the Azure IoT Edge team in this issue.

Thank you.