Skip to content

Upgrading Extensions for V2 Compatibility

Alex Weininger edited this page Sep 26, 2022 · 20 revisions

🚧 WIP 🚧

Context

Client extensions will undergo two updates related to the V2 API.

  1. Updates needed to make client extension compatible with V2 API, without actually consuming the V2 API.
  2. Full upgrade and migration to the V2 API.

This is a guide for part 1 of the upgrade.

Migrating

Extension must be using the latest version of the utils package.

  • Update utils package
  • Replace registerCommand uses with registerCommandWithTreeNodeUnwrapping
  • Resolvers must be registered with an AzExtResourceType ID The id argument when calling registerApplicationResourceResolver must be an AzExtResourceType.
  • Add V2 contributions to package.json
  • Commands should show on azureResourceGroupsV2 view instead of azureResourceGroups view
  • Change commands attached to azureResourceTypeGroup tree items to use AzExtResourceType contexts Example

Use Azure Functions as an example

Clone this wiki locally