Skip to content

Comments

Add how-to doc for customizing ARM long-running operation headers#3957

Open
Copilot wants to merge 7 commits intomainfrom
copilot/add-how-to-customize-arm
Open

Add how-to doc for customizing ARM long-running operation headers#3957
Copilot wants to merge 7 commits intomainfrom
copilot/add-how-to-customize-arm

Conversation

Copy link
Contributor

Copilot AI commented Feb 21, 2026

  • Explore repo structure, existing docs format, and ARM LRO templates
  • Create how-to document for customizing ARM LROs at website/src/content/docs/docs/howtos/ARM/long-running-operations.md
    • Introduction explaining LRO header customization via LroHeaders template parameter
    • LRO Header Types reference table
    • Section for PUT (CreateOrUpdate) operations — default, Location header, both headers
    • Section for PATCH (Update) operations — default, Azure-AsyncOperation header, both headers
    • Section for DELETE operations — default, Azure-AsyncOperation header, both headers (FinalResult = void)
    • Section for POST (Resource Action) operations — with response and no-content variants
    • Each section shows default headers and how to customize while retaining correct FinalResult
  • Format the document with prettier
  • Simplify ArmLroLocationHeader and ArmAsyncOperationHeader usages to use named FinalResult parameter with template defaults
  • Fix intro text: LRO headers appear in 201 Created for PUT and 202 Accepted for PATCH/DELETE/POST
  • Simplify ArmCombinedLroHeaders usages to use named FinalResult parameter with template defaults
  • Run pnpm format on all changed markdown files
  • Run code review — no issues found
  • Run CodeQL checker — no code changes to analyze

🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Co-authored-by: markcowl <1054056+markcowl@users.noreply.github.com>
Copilot AI changed the title [WIP] Add how-to document for customizing long-running operations Add how-to doc for customizing ARM long-running operation headers Feb 21, 2026
Copilot AI requested a review from markcowl February 21, 2026 01:30
@markcowl
Copy link
Member

@copilot You can simplify the usage of ArmLroLocationHeader and ArmAsyncOperationHeader templates by taking the template defaultsand providing the FinalResult value explicitly. For example, ArmLroLocationHeader<FinalResult = MyResource>

Co-authored-by: markcowl <1054056+markcowl@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 21, 2026

@copilot You can simplify the usage of ArmLroLocationHeader and ArmAsyncOperationHeader templates by taking the template defaultsand providing the FinalResult value explicitly. For example, `ArmLroLo...

Simplified all ArmLroLocationHeader and ArmAsyncOperationHeader usages to rely on template defaults and only specify FinalResult explicitly (e.g., ArmLroLocationHeader<FinalResult = MyResource>). Commit: 46ce5cf

@markcowl
Copy link
Member

@copilot. It is not strctly true that LroHeaders changes only the headers in 202 response for all operation types [although this is always true for delete and POST operations] (for example, it changes the headers in the 201 response to PUT operations)

Co-authored-by: markcowl <1054056+markcowl@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 21, 2026

@copilot. It is not strctly true that LroHeaders changes only the headers in 202 response for all operation types [although this is always true for delete and POST operations] (for example, it change...

Fixed the intro to clarify that LRO headers appear in the 201 Created response for PUT operations and in the 202 Accepted response for PATCH, DELETE, and POST operations. Commit: accd7f9

@markcowl markcowl marked this pull request as ready for review February 21, 2026 02:01
@azure-sdk
Copy link
Collaborator

No changes needing a change description found.

@markcowl
Copy link
Member

@copilot You can similarly simplify the usage of ArmCombinedLroHeaders to simply use the FinalResult parameter explicitly.

Co-authored-by: markcowl <1054056+markcowl@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 21, 2026

@copilot You can similarly simplify the usage of ArmCombinedLroHeaders to simply use the FinalResult parameter explicitly.

Simplified all ArmCombinedLroHeaders usages to use the named FinalResult parameter (e.g., ArmCombinedLroHeaders<FinalResult = MyResource> instead of ArmCombinedLroHeaders<ArmOperationStatus, MyResource>). Commit: 03c78f8

@azure-sdk
Copy link
Collaborator

You can try these changes here

🛝 Playground 🌐 Website

@markcowl
Copy link
Member

@copilot please run pnpm format over all changed markdown files in this pr

Co-authored-by: markcowl <1054056+markcowl@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 21, 2026

@copilot please run pnpm format over all changed markdown files in this pr

Ran pnpm format on the changed markdown file. Prettier adjusted line wrapping in two code blocks. Commit: 4d3f3b0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants