diff --git a/src/informatica/HISTORY.rst b/src/informatica/HISTORY.rst index abbff5a61a7..98b8d5add1e 100644 --- a/src/informatica/HISTORY.rst +++ b/src/informatica/HISTORY.rst @@ -3,6 +3,10 @@ Release History =============== +1.0.0b2 ++++++ +* Updated description for commands and command groups. + 1.0.0b1 ++++++ * Initial release. \ No newline at end of file diff --git a/src/informatica/README.md b/src/informatica/README.md index c158b7febe6..0b692365251 100644 --- a/src/informatica/README.md +++ b/src/informatica/README.md @@ -22,7 +22,7 @@ az group create -n testrg -l eastus ``` # Create Informatica Organization ``` -az informatica data-management organization create --resource-group {resource_group} --org-name {name} --subscription {subscription} --location {location} --company-details '{"company-name": "{company_name}", "office-address": "{office_address}", "country": "{country}", "domain": "{domain}", "number-of-employees": {number_of_employee}}' --marketplace-details '{"marketplace-subscription-id": "{marketplace_subscription_id}", "offer-details": {"offer-id": "{offer_id}", "plan-id": "{plan_id}", "plan-name": "{plan_name}", "publisher-id": "{publisher_id}", "term-unit": "{term_unit}", "term-id": "{term_id}"}}' --user-details '{"first-name": "{user_first_name}", "last-name": "{user_last_name}", "email-address": "{user_email}", "upn": "{user_upn}", "phone-number": "{user_phone}"}' --informatica-properties '{"organization-id": "{org_id}", "organization-name": "{org_name}", "informatica-region": "{informatica_region}"}' --link-organization '{"token": "{link_token}"}' +az informatica data-management organization create --resource-group {resource_group} --organization-name {name} --subscription {subscription} --location {location} --company-details '{"company-name": "{company_name}", "office-address": "{office_address}", "country": "{country}", "domain": "{domain}", "number-of-employees": {number_of_employee}}' --marketplace-details '{"marketplace-subscription-id": "{marketplace_subscription_id}", "offer-details": {"offer-id": "{offer_id}", "plan-id": "{plan_id}", "plan-name": "{plan_name}", "publisher-id": "{publisher_id}", "term-unit": "{term_unit}", "term-id": "{term_id}"}}' --user-details '{"first-name": "{user_first_name}", "last-name": "{user_last_name}", "email-address": "{user_email}", "upn": "{user_upn}", "phone-number": "{user_phone}"}' --informatica-properties '{"organization-id": "{org_id}", "organization-name": "{org_name}", "informatica-region": "{informatica_region}"}' --link-organization '{"token": "{link_token}"}' ``` # Show an Informatica Organization Resource ``` diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/__cmd_group.py b/src/informatica/azext_informatica/aaz/latest/informatica/__cmd_group.py index 35eaf44b7f7..5021c003587 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/__cmd_group.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/__cmd_group.py @@ -15,7 +15,7 @@ "informatica", ) class __CMDGroup(AAZCommandGroup): - """Manage Informatica + """Manage all resources related to Informatica within the Azure CLI. """ pass diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/__cmd_group.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/__cmd_group.py index f3c253e1ca3..4d4f7334636 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/__cmd_group.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/__cmd_group.py @@ -15,7 +15,7 @@ "informatica data-management", ) class __CMDGroup(AAZCommandGroup): - """Manage Informatica + """Manage all resources related to Informatica within the Azure CLI. """ pass diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/__cmd_group.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/__cmd_group.py index 9645879ba05..e77d2a37241 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/__cmd_group.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/__cmd_group.py @@ -15,7 +15,7 @@ "informatica data-management organization", ) class __CMDGroup(AAZCommandGroup): - """Manage Informatica organization + """Manage organization-level resources for Informatica. """ pass diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_create.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_create.py index d71a11c29fa..0c47e9a8b47 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_create.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_create.py @@ -15,10 +15,7 @@ "informatica data-management organization create", ) class Create(AAZCommand): - """Create a InformaticaOrganizationResource - - :example: Create or Update an Organization - az informatica data-management organization create -n demoOrg -g demoResourceGroup --subscription ae37d5a8-dff3-49a3-bfcd-139a4f7db98x -l westUS2 + """Create a new organization resource in Informatica via Azure. """ _aaz_info = { @@ -45,8 +42,8 @@ def _build_arguments_schema(cls, *args, **kwargs): # define Arg Group "" _args_schema = cls._args_schema - _args_schema.org_name = AAZStrArg( - options=["-n", "--name", "--org-name"], + _args_schema.organization_name = AAZStrArg( + options=["-n", "--name", "--organization-name"], help="Name of the Organizations resource", required=True, fmt=AAZStrArgFormat( @@ -54,7 +51,6 @@ def _build_arguments_schema(cls, *args, **kwargs): ), ) _args_schema.resource_group = AAZResourceGroupNameArg( - help="Resource group name", required=True, ) @@ -315,7 +311,7 @@ def error_format(self): def url_parameters(self): parameters = { **self.serialize_url_param( - "organizationName", self.ctx.args.org_name, + "organizationName", self.ctx.args.organization_name, required=True, ), **self.serialize_url_param( diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_delete.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_delete.py index 338811bac92..59614433522 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_delete.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_delete.py @@ -16,10 +16,7 @@ confirmation="Are you sure you want to perform this operation?", ) class Delete(AAZCommand): - """Delete a InformaticaOrganizationResource - - :example: Delete Organizations - az informatica data-management organization delete -n demoOrg -g demoResourceGroup --subscription ae37d5a8-dff3-49a3-bfcd-139a4f7db98x + """Delete an existing organization resource in Informatica via Azure. """ _aaz_info = { @@ -46,8 +43,8 @@ def _build_arguments_schema(cls, *args, **kwargs): # define Arg Group "" _args_schema = cls._args_schema - _args_schema.org_name = AAZStrArg( - options=["-n", "--name", "--org-name"], + _args_schema.organization_name = AAZStrArg( + options=["-n", "--name", "--organization-name"], help="Name of the Organizations resource", required=True, id_part="name", @@ -56,7 +53,6 @@ def _build_arguments_schema(cls, *args, **kwargs): ), ) _args_schema.resource_group = AAZResourceGroupNameArg( - help="Resource group name", required=True, ) return cls._args_schema @@ -129,7 +125,7 @@ def error_format(self): def url_parameters(self): parameters = { **self.serialize_url_param( - "organizationName", self.ctx.args.org_name, + "organizationName", self.ctx.args.organization_name, required=True, ), **self.serialize_url_param( diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_list.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_list.py index 370c18ab7f5..3787026de78 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_list.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_list.py @@ -15,10 +15,7 @@ "informatica data-management organization list", ) class List(AAZCommand): - """List InformaticaOrganizationResource resources by subscription ID - - :example: List organizations by subscription - az informatica data-management organization list --subscription ae37d5a8-dff3-49a3-bfcd-139a4f7db98x + """List all Informatica organization resources under the current subscription. """ _aaz_info = { @@ -46,19 +43,17 @@ def _build_arguments_schema(cls, *args, **kwargs): # define Arg Group "" _args_schema = cls._args_schema - _args_schema.resource_group = AAZResourceGroupNameArg( - help="Resource group name", - ) + _args_schema.resource_group = AAZResourceGroupNameArg() return cls._args_schema def _execute_operations(self): self.pre_operations() - condition_0 = has_value(self.ctx.args.resource_group) and has_value(self.ctx.subscription_id) - condition_1 = has_value(self.ctx.subscription_id) and has_value(self.ctx.args.resource_group) is not True + condition_0 = has_value(self.ctx.subscription_id) and has_value(self.ctx.args.resource_group) is not True + condition_1 = has_value(self.ctx.args.resource_group) and has_value(self.ctx.subscription_id) if condition_0: - self.OrganizationsListByResourceGroup(ctx=self.ctx)() - if condition_1: self.OrganizationsListBySubscription(ctx=self.ctx)() + if condition_1: + self.OrganizationsListByResourceGroup(ctx=self.ctx)() self.post_operations() @register_callback @@ -74,7 +69,7 @@ def _output(self, *args, **kwargs): next_link = self.deserialize_output(self.ctx.vars.instance.next_link) return result, next_link - class OrganizationsListByResourceGroup(AAZHttpOperation): + class OrganizationsListBySubscription(AAZHttpOperation): CLIENT_TYPE = "MgmtClient" def __call__(self, *args, **kwargs): @@ -88,7 +83,7 @@ def __call__(self, *args, **kwargs): @property def url(self): return self.client.format_url( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Informatica.DataManagement/organizations", + "/subscriptions/{subscriptionId}/providers/Informatica.DataManagement/organizations", **self.url_parameters ) @@ -103,10 +98,6 @@ def error_format(self): @property def url_parameters(self): parameters = { - **self.serialize_url_param( - "resourceGroupName", self.ctx.args.resource_group, - required=True, - ), **self.serialize_url_param( "subscriptionId", self.ctx.subscription_id, required=True, @@ -309,7 +300,7 @@ def _build_schema_on_200(cls): return cls._schema_on_200 - class OrganizationsListBySubscription(AAZHttpOperation): + class OrganizationsListByResourceGroup(AAZHttpOperation): CLIENT_TYPE = "MgmtClient" def __call__(self, *args, **kwargs): @@ -323,7 +314,7 @@ def __call__(self, *args, **kwargs): @property def url(self): return self.client.format_url( - "/subscriptions/{subscriptionId}/providers/Informatica.DataManagement/organizations", + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Informatica.DataManagement/organizations", **self.url_parameters ) @@ -338,6 +329,10 @@ def error_format(self): @property def url_parameters(self): parameters = { + **self.serialize_url_param( + "resourceGroupName", self.ctx.args.resource_group, + required=True, + ), **self.serialize_url_param( "subscriptionId", self.ctx.subscription_id, required=True, diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_show.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_show.py index 5db0fcf9939..cce2d9b7a16 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_show.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_show.py @@ -15,10 +15,7 @@ "informatica data-management organization show", ) class Show(AAZCommand): - """Get an InformaticaOrganizationResource - - :example: Get an Informatica Organization - az informatica data-management organization show -g demoResourceGroup -n demoOrg + """Retrieve details of a specific Informatica organization resource. """ _aaz_info = { @@ -44,8 +41,8 @@ def _build_arguments_schema(cls, *args, **kwargs): # define Arg Group "" _args_schema = cls._args_schema - _args_schema.org_name = AAZStrArg( - options=["-n", "--name", "--org-name"], + _args_schema.organization_name = AAZStrArg( + options=["-n", "--name", "--organization-name"], help="Name of the Organizations resource", required=True, id_part="name", @@ -54,7 +51,6 @@ def _build_arguments_schema(cls, *args, **kwargs): ), ) _args_schema.resource_group = AAZResourceGroupNameArg( - help="Resource group name", required=True, ) return cls._args_schema @@ -106,7 +102,7 @@ def error_format(self): def url_parameters(self): parameters = { **self.serialize_url_param( - "organizationName", self.ctx.args.org_name, + "organizationName", self.ctx.args.organization_name, required=True, ), **self.serialize_url_param( diff --git a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_wait.py b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_wait.py index e0bf386532e..8a9c91def7b 100644 --- a/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_wait.py +++ b/src/informatica/azext_informatica/aaz/latest/informatica/data_management/organization/_wait.py @@ -40,8 +40,8 @@ def _build_arguments_schema(cls, *args, **kwargs): # define Arg Group "" _args_schema = cls._args_schema - _args_schema.org_name = AAZStrArg( - options=["-n", "--name", "--org-name"], + _args_schema.organization_name = AAZStrArg( + options=["-n", "--name", "--organization-name"], help="Name of the Organizations resource", required=True, id_part="name", @@ -50,7 +50,6 @@ def _build_arguments_schema(cls, *args, **kwargs): ), ) _args_schema.resource_group = AAZResourceGroupNameArg( - help="Resource group name", required=True, ) return cls._args_schema @@ -102,7 +101,7 @@ def error_format(self): def url_parameters(self): parameters = { **self.serialize_url_param( - "organizationName", self.ctx.args.org_name, + "organizationName", self.ctx.args.organization_name, required=True, ), **self.serialize_url_param( diff --git a/src/informatica/azext_informatica/azext_metadata.json b/src/informatica/azext_informatica/azext_metadata.json index b1e08d1f4b1..e506328978c 100644 --- a/src/informatica/azext_informatica/azext_metadata.json +++ b/src/informatica/azext_informatica/azext_metadata.json @@ -1,4 +1,4 @@ { "azext.isPreview": true, - "azext.minCliCoreVersion": "2.61.0" + "azext.minCliCoreVersion": "2.70.0" } \ No newline at end of file diff --git a/src/informatica/azext_informatica/tests/latest/recordings/test_informatica.yaml b/src/informatica/azext_informatica/tests/latest/recordings/test_informatica.yaml index c2e9bbdee2e..5de7696e757 100644 --- a/src/informatica/azext_informatica/tests/latest/recordings/test_informatica.yaml +++ b/src/informatica/azext_informatica/tests/latest/recordings/test_informatica.yaml @@ -25,7 +25,7 @@ interactions: Content-Type: - application/json ParameterSetName: - - --resource-group --org-name --subscription --location --company-details --marketplace-details + - --resource-group --organization-name --subscription --location --company-details --marketplace-details --user-details --informatica-properties --link-organization User-Agent: - AZURECLI/2.61.0 azsdk-python-core/1.28.0 Python/3.11.0 (Windows-10-10.0.22631-SP0) @@ -86,7 +86,7 @@ interactions: Connection: - keep-alive ParameterSetName: - - --resource-group --org-name --subscription --location --company-details --marketplace-details + - --resource-group --organization-name --subscription --location --company-details --marketplace-details --user-details --informatica-properties --link-organization User-Agent: - AZURECLI/2.61.0 azsdk-python-core/1.28.0 Python/3.11.0 (Windows-10-10.0.22631-SP0) @@ -133,7 +133,7 @@ interactions: Connection: - keep-alive ParameterSetName: - - --resource-group --org-name --subscription --location --company-details --marketplace-details + - --resource-group --organization-name --subscription --location --company-details --marketplace-details --user-details --informatica-properties --link-organization User-Agent: - AZURECLI/2.61.0 azsdk-python-core/1.28.0 Python/3.11.0 (Windows-10-10.0.22631-SP0) @@ -180,7 +180,7 @@ interactions: Connection: - keep-alive ParameterSetName: - - --resource-group --org-name --subscription --location --company-details --marketplace-details + - --resource-group --organization-name --subscription --location --company-details --marketplace-details --user-details --informatica-properties --link-organization User-Agent: - AZURECLI/2.61.0 azsdk-python-core/1.28.0 Python/3.11.0 (Windows-10-10.0.22631-SP0) diff --git a/src/informatica/azext_informatica/tests/latest/test_informatica.py b/src/informatica/azext_informatica/tests/latest/test_informatica.py index 925f2ad8b86..8b28154dbcb 100644 --- a/src/informatica/azext_informatica/tests/latest/test_informatica.py +++ b/src/informatica/azext_informatica/tests/latest/test_informatica.py @@ -53,7 +53,7 @@ def test_informatica(self, resource_group): }) # Create Informatica Organization - self.cmd('az informatica data-management organization create --resource-group {resource_group} --org-name {name} --subscription {subscription} --location {location} --company-details \'{{"company-name": "{company_name}", "office-address": "{office_address}", "country": "{country}", "domain": "{domain}", "number-of-employees": {number_of_employee}}}\' --marketplace-details \'{{"marketplace-subscription-id": "{marketplace_subscription_id}", "offer-details": {{"offer-id": "{offer_id}", "plan-id": "{plan_id}", "plan-name": "{plan_name}", "publisher-id": "{publisher_id}", "term-unit": "{term_unit}", "term-id": "{term_id}"}}}}\' --user-details \'{{"first-name": "{user_first_name}", "last-name": "{user_last_name}", "email-address": "{user_email}", "upn": "{user_upn}", "phone-number": "{user_phone}"}}\' --informatica-properties \'{{"organization-id": "{org_id}", "organization-name": "{org_name}", "informatica-region": "{informatica_region}"}}\' --link-organization \'{{"token": "{link_token}"}}\'', + self.cmd('az informatica data-management organization create --resource-group {resource_group} --organization-name {name} --subscription {subscription} --location {location} --company-details \'{{"company-name": "{company_name}", "office-address": "{office_address}", "country": "{country}", "domain": "{domain}", "number-of-employees": {number_of_employee}}}\' --marketplace-details \'{{"marketplace-subscription-id": "{marketplace_subscription_id}", "offer-details": {{"offer-id": "{offer_id}", "plan-id": "{plan_id}", "plan-name": "{plan_name}", "publisher-id": "{publisher_id}", "term-unit": "{term_unit}", "term-id": "{term_id}"}}}}\' --user-details \'{{"first-name": "{user_first_name}", "last-name": "{user_last_name}", "email-address": "{user_email}", "upn": "{user_upn}", "phone-number": "{user_phone}"}}\' --informatica-properties \'{{"organization-id": "{org_id}", "organization-name": "{org_name}", "informatica-region": "{informatica_region}"}}\' --link-organization \'{{"token": "{link_token}"}}\'', checks=[ self.check('name', '{name}'), self.check('informaticaProperties.organizationName', '{org_name}'), diff --git a/src/informatica/setup.py b/src/informatica/setup.py index 20b7a601b4b..9ae03ea8f37 100644 --- a/src/informatica/setup.py +++ b/src/informatica/setup.py @@ -10,7 +10,7 @@ # HISTORY.rst entry. -VERSION = '1.0.0b1' +VERSION = '1.0.0b2' # The full list of classifiers is available at # https://pypi.python.org/pypi?%3Aaction=list_classifiers