Using the SecureTunneling compnent 1.0.16 I had opened a tunnel previously, and this had worked, and then later on tried to open another one and found it failed continuously. Closing the previously opened tunnels didn't help.
After I manually restarted the component with greengrass-cli component restart -n aws.greengrass.SecureTunneling I was able to connect.
I found in the logs the error messages below - is this a known issue, or is there a way to address this problem ?
2023-08-07T07:10:35.526Z [INFO] (Copier) aws.greengrass.SecureTunneling: stdout. Caused by: software.amazon.awssdk.aws.greengrass.model.ServiceError: Subscribe to topic $aws/things/my-device/tunnels/notify failed with error java.util.concurrent.CompletionException: software.amazon.awssdk.crt.CrtRuntimeException: Mqtt5 operation failed due to a disconnection event in conjunction with the client's offline queue retention policy. AWS_ERROR_MQTT5_OPERATION_FAILED_DUE_TO_OFFLINE_QUEUE_POLICY(5156). {scriptName=services.aws.greengrass.SecureTunneling.lifecycle.run.script, serviceName=aws.greengrass.SecureTunneling, currentState=RUNNING}
2023-08-07T07:10:35.527Z [INFO] (Copier) aws.greengrass.SecureTunneling: stdout. at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:?]. {scriptName=services.aws.greengrass.SecureTunneling.lifecycle.run.script, serviceName=aws.greengrass.SecureTunneling, currentState=RUNNING}
2023-08-07T07:10:35.527Z [INFO] (Copier) aws.greengrass.SecureTunneling: stdout. at jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) ~[?:?]. {scriptName=services.aws.greengrass.SecureTunneling.lifecycle.run.script, serviceName=aws.greengrass.SecureTunneling, currentState=RUNNING}
2023-08-07T07:10:35.527Z [INFO] (Copier) aws.greengrass.SecureTunneling: stdout. at jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:?]. {scriptName=services.aws.greengrass.SecureTunneling.lifecycle.run.script, serviceName=aws.greengrass.SecureTunneling, currentState=RUNNING}
2023-08-07T07:10:35.527Z [INFO] (Copier) aws.greengrass.SecureTunneling: stdout. at java.lang.reflect.Constructor.newInstance(Constructor.java:490) ~[?:?]. {scriptName=services.aws.greengrass.SecureTunneling.lifecycle.run.script, serviceName=aws.greengrass.SecureTunneling, currentState=RUNNING}
The compnent configuration was completely default as below
Component Name: aws.greengrass.SecureTunneling
Version: 1.0.16
State: RUNNING
Configuration: {"accessControl":{"aws.greengrass.ipc.mqttproxy":{"aws.greengrass.SecureTunneling:mqttproxy:1":{"operations":["aws.greengrass#SubscribeToIoTCore"],"policyDescription":"Access to tunnel notification pubsub topic","resources":["$aws/things/+/tunnels/notify"]}}},"OS_DIST_INFO":"auto"}
Thank you for reaching out to us. From the initial look of it, it looks like component is failing to subscribe to the Secure Tunneling MQTT topic. Give me some time to reproduce and investigate this issue further. It is possible that this was just an intermittent failure which happened because of bad internet connection. But let me investigate this issue further to investigate.