Skip to content
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

Add x-ms-correlation-request-id, x-ms-client-request-id header guidance #576

Closed
pakrym opened this issue Aug 15, 2019 · 5 comments
Closed
Assignees
Labels
architecture board-review Request for an Architectural Board Review

Comments

@pakrym
Copy link
Contributor

pakrym commented Aug 15, 2019

Add explicit guidance in the design guidelines on how a caller of the SDK should be able to specify a client-generated request-id and how to return server-generated correlation ids.

There is a bit of guidance around request-id header but it would be nice to solidify exactly what scenarios around these headers we want to support in client SDKs.

cc @johanste

@pakrym pakrym added architecture board-review Request for an Architectural Board Review labels Aug 15, 2019
@pakrym pakrym removed the board-review Request for an Architectural Board Review label Aug 15, 2019
@johanste
Copy link
Member

Some additional information. Semantically, we have (in theory and at least) three different concepts:

  1. client generated correlation ids. Used by the client application to group multiple requests together. A limited variation of traces/spans.
  2. client generated request ids. Used to detect/avoid processing the same request more than once on the server. Most often used to allow non-idempotent methods to be safely retried by clients.
  3. server generated correlation ids. Generated by the service and returned in responses.

Unfortunately, exactly the same header is used for 1 and 2 across the set of services that Microsoft exposes (Azure + others). And the most common header name is x-ms-request-id. And for Azure services, it usually represents the client generated correlation id. I have not seen Azure services intentionally use 2 and not cause problems/confusion.

@adrianhall adrianhall assigned bterlson and unassigned adrianhall Aug 15, 2019
@adrianhall
Copy link
Member

Should probably be discussed in arch board, with an eye to updating the Azure Core guidance for request IDs.

@mikekistler
Copy link
Member

We have updated the Azure Guidelines to recommend using the OASIS Repeatable Requests headers to achieve idempotency. So x-ms-request-id should be treated as a client-generated correlation id (#1 above).

@cataggar
Copy link
Member

@abatishchev
Copy link

Add explicit guidance in the design guidelines on how a caller of the SDK should be able to specify

It's still unclear to me how can I do this, namely to specify x-ms-correlation-request-id.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
architecture board-review Request for an Architectural Board Review
Projects
None yet
Development

No branches or pull requests

7 participants