-
Notifications
You must be signed in to change notification settings - Fork 3
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
feat(uat): implement GGMQ scenario based on GGAD-1-T25 #385
feat(uat): implement GGMQ scenario based on GGAD-1-T25 #385
Conversation
And message "Test message" received on "subscriber" from "iot_data_0" topic within 5 seconds | ||
And I rename connection "publisher" to "publisher_old" | ||
|
||
# Reconnect publisher with the same device id |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How can we check that the old client loses the connection due to duplicate client ID?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Such a step is not implemented at this moment. Original GGAD T25 did not have such a check
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do you know if this works? Do you have logs showing that the duplicate client was disconnected?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In that T25 we just check second connection is alive and we can publishing messages over it.
It repeat the same steps as original GGAD-1-T25.
We expecting add steps to checking disconnection when implement T26 scenario.
In addition when T26 will ready we can update T25 to add step with check connection has been really disconnected.
We expecting T26 takes a time to implement that check.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do you know that this actually creates a new connection and doesn't just reuse the existing connection? Can you show me a log showing the disconnect and new connect call?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure we can show the logs, each connection has unique connection_id number also disconnection event is logged.
To observe these events on steps level we need pass it via control to the EventStore.
I know you decided it is over complicated but despite of evergreen assert() checks are not used in the OTF and we just follows the OTF style and architecture.
@eschastlivtsev Could you attach client's and test's console logs to the task in new Test Results block ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've attached additional logs, where we can see that broker disconnects the previous connection
In client log:
2023-08-01T17:42:25.260Z [INFO] (Copier) aws.greengrass.client.Mqtt5JavaPahoClient: stdout. [INFO ] 2023-08-01 20:42:25.261 [grpc-default-executor-0] GRPCControlServer - createMqttConnection: clientId gg-df6909aca85d4c94507b-publisher broker 192.168.100.20:8883. {scriptName=services.aws.greengrass.client.Mqtt5JavaPahoClient.lifecycle.Run, serviceName=aws.greengrass.client.Mqtt5JavaPahoClient, currentState=RUNNING}
2023-08-01T17:42:26.468Z [INFO] (Copier) aws.greengrass.client.Mqtt5JavaPahoClient: stdout. [INFO ] 2023-08-01 20:42:26.467 [MQTT Rec: gg-df6909aca85d4c94507b-publisher] MqttConnectionImpl - MQTT connectionId 1 disconnected error 'null' disconnectInfo 'com.aws.greengrass.testing.mqtt5.client.GRPCClient$DisconnectInfo@42609add'. {scriptName=services.aws.greengrass.client.Mqtt5JavaPahoClient.lifecycle.Run, serviceName=aws.greengrass.client.Mqtt5JavaPahoClient, currentState=RUNNING}
2023-08-01T17:42:26.477Z [INFO] (Copier) aws.greengrass.client.Mqtt5JavaPahoClient: stdout. [INFO ] 2023-08-01 20:42:26.476 [grpc-default-executor-0] GRPCControlServer - Publish: connectionId 3 topic 'iot_data_0' QoS 1 retain false. {scriptName=services.aws.greengrass.client.Mqtt5JavaPahoClient.lifecycle.Run, serviceName=aws.greengrass.client.Mqtt5JavaPahoClient, currentState=RUNNING}
2023-08-01T17:42:26.486Z [INFO] (Copier) aws.greengrass.client.Mqtt5JavaPahoClient: stdout. [INFO ] 2023-08-01 20:42:26.483 [grpc-default-executor-0] GRPCControlServer - Publish response: connectionId 3 reason code 0 reason string ''. {scriptName=services.aws.greengrass.client.Mqtt5JavaPahoClient.lifecycle.Run, serviceName=aws.greengrass.client.Mqtt5JavaPahoClient, currentState=RUNNING}
In test console log:
[INFO ] 2023-08-01 20:42:26.581 [grpc-default-executor-0] GRPCDiscoveryServer - OnMqttDisconnect: agentId aws.greengrass.client.Mqtt5JavaPahoClient connectionId 1 disconnect 'reasonCode: 142
' error ''
[INFO ] 2023-08-01 20:42:26.584 [grpc-default-executor-0] MqttControlSteps - MQTT client disconnected. Error:
@eschastlivtsev I put PR on draft to add paho-java client before merge. |
7e351b8
to
ba58062
Compare
Issue #, if available:
Implement GGMQ scenario based on GGAD-1-T25
Description of changes:
Why is this change necessary:
Implement scenarios
How was this change tested:
Run scenario locally
Test results:
All clients (except Java Paho):
Client Log:
Test console log:
Any additional information or context required to review the change:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.