Skip to content
Open
Show file tree
Hide file tree
Changes from 47 commits
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
24a2db9
Create extension
Oct 22, 2025
f5b4378
Update src/migrate/azext_migrate/__init__.py
saifaldin14 Oct 22, 2025
67bb359
Fix import issues
Oct 22, 2025
70c525b
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Oct 22, 2025
c3021fb
Update src/migrate/setup.py
saifaldin14 Oct 22, 2025
f6e2dd8
Small
Oct 22, 2025
0174a38
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Oct 22, 2025
ae26651
Small lint
Oct 22, 2025
09ff801
Small
Oct 22, 2025
749bd43
disable lint for this check
Oct 22, 2025
8002b06
Add json
Oct 22, 2025
be276db
Fix licesnse issue
Oct 22, 2025
8da3466
fix small
Oct 22, 2025
d9fa098
Small
Oct 22, 2025
68f0d46
Get rid of unused variables
Oct 22, 2025
f916208
Add service name and code owner
Oct 23, 2025
9ad08a3
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Oct 23, 2025
8ae69d2
New version
Oct 23, 2025
532cbb3
Style
Oct 23, 2025
f216aa3
Small
Oct 23, 2025
77d8eb0
Update
Oct 23, 2025
f7558d6
Follow standard
Oct 23, 2025
ea8d636
Add suggestions
Oct 23, 2025
7117986
Small
Oct 23, 2025
143028f
Not preview
Oct 23, 2025
242fb99
Add flag to become experimental
Oct 23, 2025
4dae020
Merge branch 'Azure:main' into main
saifaldin14 Oct 23, 2025
6a1f184
Update history
Oct 23, 2025
4178016
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Oct 23, 2025
8874d5e
Fix
Oct 23, 2025
38b0de2
small
Oct 23, 2025
0f7acb7
Create get job and remove replication commands
Oct 24, 2025
6cd9f31
Revert "Create get job and remove replication commands"
Oct 28, 2025
ce78b73
Merge branch 'Azure:main' into main
saifaldin14 Oct 28, 2025
047528f
Update version
Oct 28, 2025
60c647f
Sync with other branch
Jan 15, 2026
9d6fdaf
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Jan 15, 2026
2310bc0
Merge branch 'Azure:main' into main
saifaldin14 Mar 5, 2026
1fa76db
Fix error in init command
Mar 11, 2026
3b50625
Merge branch 'Azure:main' into main
saifaldin14 Mar 11, 2026
f1897de
Remove duplicate files
Mar 11, 2026
00dc1b6
Merge branch 'main' of https://github.com/saifaldin14/azure-cli-exten…
Mar 11, 2026
eb04141
Fix local issues
Mar 11, 2026
f17cbe1
Select correct fabric
Mar 11, 2026
ab10e2b
Process project name
Mar 11, 2026
0f85861
Merge remote-tracking branch 'upstream/main'
Jun 30, 2026
b636cf8
Rename protected item id to target object id
Jun 30, 2026
69a102e
Potential fix for pull request finding
saifaldin14 Jun 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/migrate/azext_migrate/_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@
Note: This command uses a preview API version
and may experience breaking changes in future releases.
parameters:
- name: --protected-item-id
- name: --target-object-id
short-summary: Full ARM resource ID of the protected item to migrate.
long-summary: >
The complete ARM resource ID of the replicating server.
Expand All @@ -581,11 +581,11 @@
- name: Start migration for a protected item
text: |
az migrate local start-migration \\
--protected-item-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem"
--target-object-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem"
- name: Start migration and turn off source server
text: |
az migrate local start-migration \\
--protected-item-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem" \\
--target-object-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem" \\
--turn-off-source-server
- name: Start migration using short parameter names
text: |
Expand All @@ -595,6 +595,6 @@
- name: Start migration with specific subscription
text: |
az migrate local start-migration \\
--protected-item-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem" \\
--target-object-id "/subscriptions/xxxx/resourceGroups/myRG/providers/Microsoft.DataReplication/replicationVaults/myVault/protectedItems/myItem" \\
--subscription-id "12345678-1234-1234-1234-123456789012"
"""
2 changes: 1 addition & 1 deletion src/migrate/azext_migrate/_params.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ def load_arguments(self, _):
with self.argument_context('migrate local start-migration') as c:
c.argument(
'protected_item_id',
options_list=['--protected-item-id', '--id'],
options_list=['--target-object-id', '--id'],
help='The full ARM resource ID of the protected item to migrate. '
Comment on lines 261 to 263
'This can be obtained from the list or get replication commands.',
required=True)
Expand Down
2 changes: 1 addition & 1 deletion src/migrate/azext_migrate/custom.py
Original file line number Diff line number Diff line change
Expand Up @@ -533,7 +533,7 @@ def start_local_server_migration(cmd,
# Validate that either ID or name is provided
if not protected_item_id:
raise CLIError(
"The --protected-item-id parameter must be provided."
"The --target-object-id parameter must be provided."
)

# Determine the operation mode
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5193,7 +5193,7 @@ def test_start_migration_with_protected_item_name(self, mock_get_sub_id,
)

# Verify error message
self.assertIn("--protected-item-id parameter must be provided",
self.assertIn("--target-object-id parameter must be provided",
str(context.exception))

@mock.patch('azure.cli.core.commands.client_factory.get_subscription_id')
Expand All @@ -5208,7 +5208,7 @@ def test_start_migration_missing_parameters(self, mock_get_sub_id):
with self.assertRaises(CLIError) as context:
start_local_server_migration(cmd=mock_cmd)

self.assertIn("--protected-item-id parameter must be provided",
self.assertIn("--target-object-id parameter must be provided",
Comment thread
saifaldin14 marked this conversation as resolved.
Outdated
str(context.exception))

@mock.patch('azure.cli.core.commands.client_factory.get_subscription_id')
Expand All @@ -5225,7 +5225,7 @@ def test_start_migration_name_without_resource_group(self, mock_get_sub_id):
cmd=mock_cmd
)

self.assertIn("--protected-item-id parameter must be provided",
self.assertIn("--target-object-id parameter must be provided",
str(context.exception))

@mock.patch('azext_migrate.helpers._utils.get_resource_by_id')
Expand Down
Loading