-
Notifications
You must be signed in to change notification settings - Fork 234
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
fix(iot-service, deps, e2e): Fix issue where ConnectionState was never propagated up through DeviceTwinDevice object #525
Conversation
43c8f53
to
537a4c3
Compare
@@ -383,6 +383,16 @@ public static TwinState createFromPropertiesJson(String json) | |||
return new TwinState(null, result.getDesired(), result.getReported()); | |||
} | |||
|
|||
public String getConnectionState() |
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.
add comments for javadoc
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 thing
@@ -10,9 +10,9 @@ | |||
*/ | |||
public enum TwinConnectionState | |||
{ | |||
@SerializedName("disconnected") | |||
@SerializedName("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.
could we make this case-insensitive?
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 can't, but I can make it catch "disconnected" and "Disconnected"
return this.connectionState; | ||
} | ||
|
||
protected void setConnectionState(String connectionState) |
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.
add comments
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 thing
…r propagated up through DeviceTwinDevice object service was sending uppercase "Disconnected" and "Connected" when the SDK was expected lowercase "disconnected" and "connected"
27e898e
to
31ff847
Compare
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.
service was sending uppercase "Disconnected" and "Connected" when the SDK was expected lowercase "disconnected" and "connected"
The SDK was missing logic to propagate up this Json field to the DeviceTwinDevice object, too.