Closed tigrannajaryan closed 2 years ago
Some thoughts on this topic:
WebSocket specifics:
Plain HTTP specifics:
Give the above, I believe the following is necessary:
Upon receiving AgentToServer message one of the following can happen:
More specifically:
Alternatively, we just make everything uniform and all 4 parts keep hashes and have 4 flags for the Server to request the them.
@open-telemetry/opamp-spec-approvers @andykellr @dsvanlani what do you think?
I think your summary makes sense. In general, either the state needs to be supplied with every message or a hash needs to be supplied and the server needs a flag to be able to request the entire state.
At the protocol level, I wouldn't be opposed to some flexibility in the agent implementation. There could be a flag for each of the 4 parts and for each of the 4 components we could allow the agent to either send the entire state with each message or to send a hash.
In the reference implementation it would send the entire AgentDescription and RemoteConfigStatus and hashes of the EffectiveConfig and AgentAddonStatuses.
After thinking about this some more, I think having all 4 flags is useful, even if most implementations pass smaller components on every request.
See the comment here: https://github.com/open-telemetry/opamp-go/pull/63#issuecomment-1098526891
The spec says:
Nowhere does it says that the AgentDescription must be also included in the status report. On the contrary, the spec says:
The question is if AgentDescription must be included in every StatusReport. We need to consider what happens both for WebSocket and plain HTTP transports.