diff --git a/.flake8 b/.flake8 index bc451ff67fa..10e6fe8740b 100644 --- a/.flake8 +++ b/.flake8 @@ -14,11 +14,7 @@ exclude = scripts doc build_scripts - src/command_modules/azure-cli-rdbms - src/command_modules/azure-cli-sql - src/command_modules/azure-cli-vm - src/command_modules/azure-cli-acs + src/command_modules/azure-cli-backup + src/command_modules/azure-cli-batchai src/command_modules/azure-cli-cosmosdb - src/command_modules/azure-cli-dla - src/command_modules/azure-cli-dls - src/command_modules/azure-cli-monitor + src/command_modules/azure-cli-monitor diff --git a/azure-cli.pyproj b/azure-cli.pyproj index 90e3f03302b..cba403f7b62 100644 --- a/azure-cli.pyproj +++ b/azure-cli.pyproj @@ -89,7 +89,6 @@ - diff --git a/scripts/ci/build.sh b/scripts/ci/build.sh index a06143eca77..8f350cb9957 100755 --- a/scripts/ci/build.sh +++ b/scripts/ci/build.sh @@ -109,8 +109,8 @@ for name in $(ls src/command_modules | grep azure-cli-); do if [ "$name" == "azure-cli-backup" ]; then continue; fi if [ "$name" == "azure-cli-batchai" ]; then continue; fi if [ "$name" == "azure-cli-cosmosdb" ]; then continue; fi - if [ "$name" == "azure-cli-dla" ]; then continue; fi - if [ "$name" == "azure-cli-dls" ]; then continue; fi + if [ "$name" == "azure-cli-dla" ]; then continue; fi + if [ "$name" == "azure-cli-dls" ]; then continue; fi if [ "$name" == "azure-cli-eventgrid" ]; then continue; fi if [ "$name" == "azure-cli-find" ]; then continue; fi if [ "$name" == "azure-cli-interactive" ]; then continue; fi diff --git a/scripts/ci/test_static.sh b/scripts/ci/test_static.sh index 2b2196de87b..f20a585e3e3 100755 --- a/scripts/ci/test_static.sh +++ b/scripts/ci/test_static.sh @@ -49,8 +49,8 @@ run_style azure.cli.command_modules.configure run_style azure.cli.command_modules.container run_style azure.cli.command_modules.consumption #run_style azure.cli.command_modules.cosmosdb -#run_style azure.cli.command_modules.dla -#run_style azure.cli.command_modules.dls +run_style azure.cli.command_modules.dla +run_style azure.cli.command_modules.dls run_style azure.cli.command_modules.eventgrid run_style azure.cli.command_modules.extension run_style azure.cli.command_modules.feedback @@ -61,17 +61,16 @@ run_style azure.cli.command_modules.keyvault run_style azure.cli.command_modules.lab #run_style azure.cli.command_modules.monitor run_style azure.cli.command_modules.network -#run_style azure.cli.command_modules.nspkg -#run_style azure.cli.command_modules.profile -#run_style azure.cli.command_modules.rdbms +run_style azure.cli.command_modules.profile +run_style azure.cli.command_modules.rdbms run_style azure.cli.command_modules.redis run_style azure.cli.command_modules.reservations run_style azure.cli.command_modules.resource run_style azure.cli.command_modules.role run_style azure.cli.command_modules.servicefabric -#run_style azure.cli.command_modules.sql +run_style azure.cli.command_modules.sql run_style azure.cli.command_modules.storage -#run_style azure.cli.command_modules.testsdk -#run_style azure.cli.command_modules.vm +run_style azure.cli.testsdk +run_style azure.cli.command_modules.vm exit $exit_code diff --git a/src/azure-cli-core/azure/cli/core/_help.py b/src/azure-cli-core/azure/cli/core/_help.py index 9a59e9d341c..f64a8ea7f25 100644 --- a/src/azure-cli-core/azure/cli/core/_help.py +++ b/src/azure-cli-core/azure/cli/core/_help.py @@ -5,16 +5,15 @@ from __future__ import print_function -from azure.cli.core.commands import ExtensionCommandSource - from knack.help import (HelpExample, HelpFile as KnackHelpFile, CLIHelp, HelpParameter, ArgumentGroupRegistry as KnackArgumentGroupRegistry) - from knack.log import get_logger +from azure.cli.core.commands import ExtensionCommandSource + logger = get_logger(__name__) PRIVACY_STATEMENT = """ diff --git a/src/azure-cli-core/azure/cli/core/_profile.py b/src/azure-cli-core/azure/cli/core/_profile.py index 0d2b5f22e4e..46121167e2d 100644 --- a/src/azure-cli-core/azure/cli/core/_profile.py +++ b/src/azure-cli-core/azure/cli/core/_profile.py @@ -12,14 +12,14 @@ from copy import deepcopy from enum import Enum +from knack.log import get_logger +from knack.util import CLIError + from azure.cli.core._environment import get_config_dir from azure.cli.core._session import ACCOUNT from azure.cli.core.util import get_file_json, in_cloud_console from azure.cli.core.cloud import get_active_cloud, set_cloud_subscription -from knack.log import get_logger -from knack.util import CLIError - logger = get_logger(__name__) # Names below are used by azure-xplat-cli to persist account information into diff --git a/src/azure-cli-core/azure/cli/core/cloud.py b/src/azure-cli-core/azure/cli/core/cloud.py index 058b68a6e8f..b6415189d50 100644 --- a/src/azure-cli-core/azure/cli/core/cloud.py +++ b/src/azure-cli-core/azure/cli/core/cloud.py @@ -7,13 +7,13 @@ from pprint import pformat from six.moves import configparser -from azure.cli.core.profiles import API_PROFILES -from azure.cli.core._config import GLOBAL_CONFIG_DIR - from knack.log import get_logger from knack.util import CLIError from knack.config import get_config_parser +from azure.cli.core.profiles import API_PROFILES +from azure.cli.core._config import GLOBAL_CONFIG_DIR + logger = get_logger(__name__) CLOUD_CONFIG_FILE = os.path.join(GLOBAL_CONFIG_DIR, 'clouds.config') diff --git a/src/azure-cli-core/azure/cli/core/commands/__init__.py b/src/azure-cli-core/azure/cli/core/commands/__init__.py index aa7f37b2a1e..fdada5bcc8f 100644 --- a/src/azure-cli-core/azure/cli/core/commands/__init__.py +++ b/src/azure-cli-core/azure/cli/core/commands/__init__.py @@ -11,9 +11,7 @@ import sys import time from importlib import import_module - -from azure.cli.core import EXCLUDED_PARAMS -import azure.cli.core.telemetry as telemetry +import six from knack.arguments import CLICommandArgument, ignore_type, ArgumentsContext from knack.commands import CLICommand, CommandGroup @@ -21,7 +19,8 @@ from knack.log import get_logger from knack.util import CLIError -import six +from azure.cli.core import EXCLUDED_PARAMS +import azure.cli.core.telemetry as telemetry logger = get_logger(__name__) @@ -319,7 +318,7 @@ def execute(self, args): except Exception as ex: # pylint: disable=broad-except if cmd.exception_handler: cmd.exception_handler(ex) - return + return None else: six.reraise(*sys.exc_info()) diff --git a/src/azure-cli-core/azure/cli/core/commands/arm.py b/src/azure-cli-core/azure/cli/core/commands/arm.py index 1e7da554add..286cc752a41 100644 --- a/src/azure-cli-core/azure/cli/core/commands/arm.py +++ b/src/azure-cli-core/azure/cli/core/commands/arm.py @@ -7,6 +7,11 @@ import re from six import string_types +from knack.arguments import CLICommandArgument, ignore_type +from knack.introspection import extract_args_from_signature +from knack.log import get_logger +from knack.util import todict, CLIError + from azure.cli.core import AzCommandsLoader, EXCLUDED_PARAMS from azure.cli.core.commands import LongRunningOperation, _is_poller from azure.cli.core.commands.client_factory import get_mgmt_service_client @@ -14,11 +19,6 @@ from azure.cli.core.util import shell_safe_json_parse from azure.cli.core.profiles import ResourceType -from knack.arguments import CLICommandArgument, ignore_type -from knack.introspection import extract_args_from_signature -from knack.log import get_logger -from knack.util import todict, CLIError - logger = get_logger(__name__) @@ -472,20 +472,20 @@ def handler(args): try: instance = getter(**args) if wait_for_exists: - return + return None provisioning_state = get_provisioning_state(instance) # until we have any needs to wait for 'Failed', let us bail out on this if provisioning_state == 'Failed': raise CLIError('The operation failed') if wait_for_created or wait_for_updated: if provisioning_state == 'Succeeded': - return + return None if custom_condition and bool(verify_property(instance, custom_condition)): - return + return None except ClientException as ex: if getattr(ex, 'status_code', None) == 404: if wait_for_deleted: - return + return None if not any([wait_for_created, wait_for_exists, custom_condition]): raise else: diff --git a/src/azure-cli-core/azure/cli/core/commands/client_factory.py b/src/azure-cli-core/azure/cli/core/commands/client_factory.py index 88336d5dfbe..ba30ba192ce 100644 --- a/src/azure-cli-core/azure/cli/core/commands/client_factory.py +++ b/src/azure-cli-core/azure/cli/core/commands/client_factory.py @@ -4,14 +4,15 @@ # -------------------------------------------------------------------------------------------- import os + +from knack.log import get_logger +from knack.util import CLIError + from azure.cli.core import __version__ as core_version import azure.cli.core._debug as _debug from azure.cli.core.profiles._shared import get_client_class from azure.cli.core.profiles import ResourceType, get_api_version, get_sdk -from knack.log import get_logger -from knack.util import CLIError - logger = get_logger(__name__) UA_AGENT = "AZURECLI/{}".format(core_version) ENV_ADDITIONAL_USER_AGENT = 'AZURE_HTTP_USER_AGENT' diff --git a/src/azure-cli-core/azure/cli/core/commands/parameters.py b/src/azure-cli-core/azure/cli/core/commands/parameters.py index 90ca89be10b..8e68a06921a 100644 --- a/src/azure-cli-core/azure/cli/core/commands/parameters.py +++ b/src/azure-cli-core/azure/cli/core/commands/parameters.py @@ -7,15 +7,15 @@ import argparse import platform +from knack.arguments import CLIArgumentType, CaseInsensitiveList +from knack.log import get_logger +from knack.util import CLIError + from azure.cli.core.commands.validators import validate_tag, validate_tags from azure.cli.core.commands.validators import generate_deployment_name from azure.cli.core.decorators import Completer from azure.cli.core.profiles import ResourceType -from knack.arguments import CLIArgumentType, CaseInsensitiveList -from knack.log import get_logger -from knack.util import CLIError - logger = get_logger(__name__) diff --git a/src/azure-cli-core/azure/cli/core/commands/template_create.py b/src/azure-cli-core/azure/cli/core/commands/template_create.py index a6d6d1e9ae7..75684608906 100644 --- a/src/azure-cli-core/azure/cli/core/commands/template_create.py +++ b/src/azure-cli-core/azure/cli/core/commands/template_create.py @@ -6,11 +6,11 @@ from __future__ import print_function import platform -from azure.cli.core.commands.arm import resource_exists - from knack.log import get_logger from knack.util import CLIError +from azure.cli.core.commands.arm import resource_exists + logger = get_logger(__name__) diff --git a/src/azure-cli-core/azure/cli/core/commands/validators.py b/src/azure-cli-core/azure/cli/core/commands/validators.py index 356a458d04f..2d859ca9259 100644 --- a/src/azure-cli-core/azure/cli/core/commands/validators.py +++ b/src/azure-cli-core/azure/cli/core/commands/validators.py @@ -6,10 +6,11 @@ import argparse import time import random -from azure.cli.core.profiles import ResourceType from knack.log import get_logger +from azure.cli.core.profiles import ResourceType + logger = get_logger(__name__) diff --git a/src/azure-cli-core/azure/cli/core/extension.py b/src/azure-cli-core/azure/cli/core/extension.py index c862479fd83..460fba21dca 100644 --- a/src/azure-cli-core/azure/cli/core/extension.py +++ b/src/azure-cli-core/azure/cli/core/extension.py @@ -7,10 +7,10 @@ import traceback import json -from azure.cli.core._config import GLOBAL_CONFIG_DIR - from knack.log import get_logger +from azure.cli.core._config import GLOBAL_CONFIG_DIR + _CUSTOM_EXT_DIR = os.environ.get('AZURE_EXTENSION_DIR') EXTENSIONS_DIR = os.path.expanduser(_CUSTOM_EXT_DIR) if _CUSTOM_EXT_DIR else os.path.join(GLOBAL_CONFIG_DIR, diff --git a/src/azure-cli-core/azure/cli/core/extensions/transform.py b/src/azure-cli-core/azure/cli/core/extensions/transform.py index 49e4df18b9c..27b18a8c3cc 100644 --- a/src/azure-cli-core/azure/cli/core/extensions/transform.py +++ b/src/azure-cli-core/azure/cli/core/extensions/transform.py @@ -5,10 +5,10 @@ import re -from azure.cli.core.util import b64_to_hex - import knack.events as events +from azure.cli.core.util import b64_to_hex + def register(cli_ctx): cli_ctx.register_event(events.EVENT_INVOKER_TRANSFORM_RESULT, _resource_group_transform) diff --git a/src/azure-cli-core/azure/cli/core/parser.py b/src/azure-cli-core/azure/cli/core/parser.py index 55535ce3940..5bbc3c2fbfd 100644 --- a/src/azure-cli-core/azure/cli/core/parser.py +++ b/src/azure-cli-core/azure/cli/core/parser.py @@ -8,12 +8,13 @@ import argparse import argcomplete -import azure.cli.core.telemetry as telemetry - from knack.log import get_logger from knack.parser import CLICommandParser from knack.util import CLIError +import azure.cli.core.telemetry as telemetry + + logger = get_logger(__name__) diff --git a/src/azure-cli-core/azure/cli/core/telemetry.py b/src/azure-cli-core/azure/cli/core/telemetry.py index 35b2fc2f0c1..0f2bca8777b 100644 --- a/src/azure-cli-core/azure/cli/core/telemetry.py +++ b/src/azure-cli-core/azure/cli/core/telemetry.py @@ -187,7 +187,7 @@ def _user_agrees_to_telemetry(func): @wraps(func) def _wrapper(*args, **kwargs): if not _get_config().getboolean('core', 'collect_telemetry', fallback=True): - return + return None return func(*args, **kwargs) return _wrapper diff --git a/src/azure-cli-core/azure/cli/core/util.py b/src/azure-cli-core/azure/cli/core/util.py index d0cc8681179..6d90bd14dca 100644 --- a/src/azure-cli-core/azure/cli/core/util.py +++ b/src/azure-cli-core/azure/cli/core/util.py @@ -32,6 +32,7 @@ def handle_exception(ex): return 1 +# pylint: disable=inconsistent-return-statements def empty_on_404(ex): from msrestazure.azure_exceptions import CloudError if isinstance(ex, CloudError) and ex.status_code == 404: diff --git a/src/azure-cli-testsdk/azure/cli/testsdk/__init__.py b/src/azure-cli-testsdk/azure/cli/testsdk/__init__.py index 011106c1482..b437a70c8d2 100644 --- a/src/azure-cli-testsdk/azure/cli/testsdk/__init__.py +++ b/src/azure-cli-testsdk/azure/cli/testsdk/__init__.py @@ -3,10 +3,10 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core import AzCli - from azure_devtools.scenario_tests import live_only, record_only, get_sha1_hash +from azure.cli.core import AzCli + from .base import ScenarioTest, LiveScenarioTest from .preparers import (StorageAccountPreparer, ResourceGroupPreparer, RoleBasedServicePrincipalPreparer, KeyVaultPreparer) diff --git a/src/azure-cli-testsdk/azure/cli/testsdk/base.py b/src/azure-cli-testsdk/azure/cli/testsdk/base.py index 9660c212ad9..fec7cd4af71 100644 --- a/src/azure-cli-testsdk/azure/cli/testsdk/base.py +++ b/src/azure-cli-testsdk/azure/cli/testsdk/base.py @@ -70,32 +70,49 @@ def __init__(self, method_name, config_file=None, recording_name=None, self.cli_ctx = TestCli() self.name_replacer = GeneralNameReplacer() self.kwargs = {} + + default_recording_processors = [ + SubscriptionRecordingProcessor(MOCKED_SUBSCRIPTION_ID), + OAuthRequestResponsesFilter(), + LargeRequestBodyProcessor(), + LargeResponseBodyProcessor(), + DeploymentNameReplacer(), + RequestUrlNormalizer(), + self.name_replacer + ] + + default_replay_processors = [ + LargeResponseBodyReplacer(), + DeploymentNameReplacer(), + RequestUrlNormalizer(), + ] + + default_recording_patches = [patch_main_exception_handler] + + default_replay_patches = [ + patch_main_exception_handler, + patch_time_sleep_api, + patch_long_run_operation_delay, + patch_load_cached_subscriptions, + patch_retrieve_token_for_user, + patch_progress_controller, + ] + + def _merge_lists(base, patches): + merged = list(base) + if patches and not isinstance(patches, list): + patches = [patches] + if patches: + merged = list(set(merged).union(set(patches))) + return merged + super(ScenarioTest, self).__init__( method_name, config_file=config_file, - recording_processors=recording_processors or [ - SubscriptionRecordingProcessor(MOCKED_SUBSCRIPTION_ID), - OAuthRequestResponsesFilter(), - LargeRequestBodyProcessor(), - LargeResponseBodyProcessor(), - DeploymentNameReplacer(), - RequestUrlNormalizer(), - self.name_replacer, - ], - replay_processors=replay_processors or [ - LargeResponseBodyReplacer(), - DeploymentNameReplacer(), - RequestUrlNormalizer(), - ], - recording_patches=recording_patches or [patch_main_exception_handler], - replay_patches=replay_patches or [ - patch_main_exception_handler, - patch_time_sleep_api, - patch_long_run_operation_delay, - patch_load_cached_subscriptions, - patch_retrieve_token_for_user, - patch_progress_controller, - ], + recording_processors=_merge_lists(default_recording_processors, recording_processors), + replay_processors=_merge_lists(default_replay_processors, replay_processors), + recording_patches=_merge_lists(default_recording_patches, recording_patches), + replay_patches=_merge_lists(default_replay_patches, replay_patches), recording_dir=find_recording_dir(self.cli_ctx, inspect.getfile(self.__class__)), recording_name=recording_name ) diff --git a/src/azure-cli-testsdk/azure/cli/testsdk/checkers.py b/src/azure-cli-testsdk/azure/cli/testsdk/checkers.py index dc67b01141b..f25ad696539 100644 --- a/src/azure-cli-testsdk/azure/cli/testsdk/checkers.py +++ b/src/azure-cli-testsdk/azure/cli/testsdk/checkers.py @@ -61,17 +61,17 @@ def __call__(self, execution_result): class JMESPathPatternCheck(object): # pylint: disable=too-few-public-methods - def __init__(self, query, expected_result): - self._query = query - self._expected_result = expected_result - - def __call__(self, execution_result): - json_value = execution_result.get_output_in_json() - actual_result = jmespath.search(self._query, json_value, - jmespath.Options(collections.OrderedDict)) - if not re.match(self._expected_result, str(actual_result), re.IGNORECASE): - raise JMESPathCheckAssertionError(self._query, self._expected_result, actual_result, - execution_result.output) + def __init__(self, query, expected_result): + self._query = query + self._expected_result = expected_result + + def __call__(self, execution_result): + json_value = execution_result.get_output_in_json() + actual_result = jmespath.search(self._query, json_value, + jmespath.Options(collections.OrderedDict)) + if not re.match(self._expected_result, str(actual_result), re.IGNORECASE): + raise JMESPathCheckAssertionError(self._query, self._expected_result, actual_result, + execution_result.output) class NoneCheck(object): # pylint: disable=too-few-public-methods diff --git a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_docker_utils.py b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_docker_utils.py index adc2ea4c788..8fcf61a5e89 100644 --- a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_docker_utils.py +++ b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_docker_utils.py @@ -112,6 +112,7 @@ def _get_aad_token(cli_ctx, login_server, only_refresh_token, repository=None, p return access_token +# pylint: disable=inconsistent-return-statements def _get_credentials(cli_ctx, registry_name, resource_group_name, diff --git a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_utils.py b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_utils.py index 8bf01d15508..6fcefbe3b8e 100644 --- a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_utils.py +++ b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/_utils.py @@ -240,6 +240,7 @@ def _parameters(registry_name, return parameters +# pylint: disable=inconsistent-return-statements def random_storage_account_name(cli_ctx, registry_name): from datetime import datetime diff --git a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/credential.py b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/credential.py index 1332fa5428c..9454466ff12 100644 --- a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/credential.py +++ b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/credential.py @@ -8,6 +8,7 @@ from ._utils import get_registry_by_name +# pylint: disable=inconsistent-return-statements def get_acr_credentials(cli_ctx, client, registry_name, resource_group_name=None): registry, resource_group_name = get_registry_by_name(cli_ctx, registry_name, resource_group_name) @@ -21,6 +22,7 @@ def acr_credential_show(cmd, client, registry_name, resource_group_name=None): return get_acr_credentials(cmd.cli_ctx, client, registry_name, resource_group_name) +# pylint: disable=inconsistent-return-statements def acr_credential_renew(cmd, client, registry_name, password_name, resource_group_name=None): registry, resource_group_name = get_registry_by_name(cmd.cli_ctx, registry_name, resource_group_name) diff --git a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/custom.py b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/custom.py index f0b47d470b5..e4cb7ef7d9b 100644 --- a/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/custom.py +++ b/src/command_modules/azure-cli-acr/azure/cli/command_modules/acr/custom.py @@ -3,6 +3,9 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- +from knack.util import CLIError +from knack.log import get_logger + from azure.cli.core.commands import LongRunningOperation from azure.mgmt.containerregistry.v2017_10_01.models import ( @@ -12,9 +15,6 @@ Sku ) -from knack.util import CLIError -from knack.log import get_logger - from ._constants import MANAGED_REGISTRY_SKU from ._utils import ( arm_deploy_template_new_storage, diff --git a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/_validators.py b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/_validators.py index 20109b1ff41..32744234280 100644 --- a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/_validators.py +++ b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/_validators.py @@ -7,9 +7,10 @@ import os.path import re +from knack.log import get_logger + from azure.cli.core.util import CLIError import azure.cli.core.keys as keys -from knack.log import get_logger logger = get_logger(__name__) diff --git a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/acs_client.py b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/acs_client.py index 33753c0d411..5f67dea4c0b 100644 --- a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/acs_client.py +++ b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/acs_client.py @@ -148,7 +148,7 @@ def run(self, command, background=False): t = threading.Thread(target=ACSClient._run_cmd, args=(self, command)) t.daemon = True t.start() - return + return None return self._run_cmd(command) diff --git a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/custom.py b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/custom.py index 76549e26a07..0b80a0663c2 100644 --- a/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/custom.py +++ b/src/command_modules/azure-cli-acs/azure/cli/command_modules/acs/custom.py @@ -30,6 +30,9 @@ from six.moves.urllib.request import urlopen # pylint: disable=import-error from six.moves.urllib.error import URLError # pylint: disable=import-error +from knack.log import get_logger +from knack.util import CLIError + from msrestazure.azure_exceptions import CloudError from azure.cli.command_modules.acs import acs_client, proxy @@ -56,9 +59,6 @@ from azure.mgmt.containerservice.models import ManagedCluster from azure.mgmt.containerservice.models import ManagedClusterProperties -from knack.log import get_logger -from knack.util import CLIError - from ._client_factory import get_auth_management_client from ._client_factory import get_graph_rbac_management_client from ._client_factory import cf_container_services diff --git a/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/_params.py b/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/_params.py index f62b71a4ee4..0319725836d 100644 --- a/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/_params.py +++ b/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/_params.py @@ -3,8 +3,10 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core.commands.parameters import get_enum_type from knack.arguments import CLIArgumentType + +from azure.cli.core.commands.parameters import get_enum_type + from ._validators import validate_include_or_exclude, validate_ids_or_resource_group diff --git a/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/custom.py b/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/custom.py index a5edac55592..db17f05b583 100644 --- a/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/custom.py +++ b/src/command_modules/azure-cli-advisor/azure/cli/command_modules/advisor/custom.py @@ -5,9 +5,10 @@ import uuid -from azure.mgmt.advisor.models import ConfigData, ConfigDataProperties from msrestazure.azure_exceptions import CloudError +from azure.mgmt.advisor.models import ConfigData, ConfigDataProperties + def cli_advisor_generate_recommendations(client): response = client.generate(raw=True) diff --git a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_client_factory.py b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_client_factory.py index 0b99825fa69..20866fbe25a 100644 --- a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_client_factory.py +++ b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_client_factory.py @@ -4,6 +4,7 @@ # -------------------------------------------------------------------------------------------- +# pylint: disable=inconsistent-return-statements def ex_handler_factory(creating_plan=False, no_throw=False): def _polish_bad_errors(ex): import json diff --git a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_completers.py b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_completers.py index dd7437bcb3e..2ca643e264d 100644 --- a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_completers.py +++ b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_completers.py @@ -8,7 +8,7 @@ @Completer -def get_hostname_completion_list(cmd, prefix, namespace): # pylint: disable=unused-argument +def get_hostname_completion_list(cmd, prefix, namespace): # pylint: disable=unused-argument, inconsistent-return-statements if namespace.resource_group_name and namespace.webapp: rg = namespace.resource_group_name webapp = namespace.webapp diff --git a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_params.py b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_params.py index 1849902190a..d1362e29e7b 100644 --- a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_params.py +++ b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/_params.py @@ -5,11 +5,12 @@ from argcomplete.completers import FilesCompleter +from knack.arguments import CLIArgumentType + from azure.cli.core.commands.parameters import (resource_group_name_type, get_location_type, get_resource_name_completion_list, file_type, get_three_state_flag, get_enum_type) from azure.mgmt.web.models import DatabaseType, ConnectionStringType, BuiltInAuthenticationProvider -from knack.arguments import CLIArgumentType from ._completers import get_hostname_completion_list diff --git a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/custom.py b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/custom.py index 4ee8ebc99a1..e251a04f015 100644 --- a/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/custom.py +++ b/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice/custom.py @@ -12,6 +12,11 @@ from binascii import hexlify from os import urandom import OpenSSL.crypto + +from knack.prompting import prompt_pass, NoTTYException +from knack.util import CLIError +from knack.log import get_logger + from msrestazure.azure_exceptions import CloudError from msrestazure.tools import is_valid_resource_id, parse_resource_id @@ -25,10 +30,6 @@ from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.cli.core.commands import LongRunningOperation -from knack.prompting import prompt_pass, NoTTYException -from knack.util import CLIError -from knack.log import get_logger - from .vsts_cd_provider import VstsContinuousDeliveryProvider from ._params import AUTH_TYPES from ._client_factory import web_client_factory, ex_handler_factory @@ -899,6 +900,7 @@ def restore_backup(cmd, resource_group_name, webapp_name, storage_account_url, b return client.web_apps.restore(resource_group_name, webapp_name, 0, restore_request) +# pylint: disable=inconsistent-return-statements def _create_db_setting(db_name, db_type, db_connection_string): if all([db_name, db_type, db_connection_string]): return [DatabaseBackupSetting(db_type, db_name, connection_string=db_connection_string)] diff --git a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_command_type.py b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_command_type.py index aa9f4034a47..416550557a3 100644 --- a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_command_type.py +++ b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_command_type.py @@ -5,9 +5,11 @@ import json import re - from six import string_types +from knack.arguments import CLICommandArgument, IgnoreAction +from knack.introspection import extract_full_summary_from_signature, extract_args_from_signature + from azure.cli.command_modules.batch import _validators as validators from azure.cli.command_modules.batch import _format as transformers from azure.cli.command_modules.batch import _parameter_format as pformat @@ -16,8 +18,6 @@ from azure.cli.core.commands import CONFIRM_PARAM_NAME from azure.cli.core.commands import AzCommandGroup -from knack.arguments import CLICommandArgument, IgnoreAction -from knack.introspection import extract_full_summary_from_signature, extract_args_from_signature _CLASS_NAME = re.compile(r"<(.*?)>") # Strip model name from class docstring _UNDERSCORE_CASE = re.compile('(?!^)([A-Z]+)') # Convert from CamelCase to underscore_case @@ -100,6 +100,7 @@ def find_param_help(model, param): return re.sub(r"\n\s*", " ", param_doc.group(1).strip()) +# pylint: disable=inconsistent-return-statements def find_return_type(model): """Parse the parameter help info from the model docstring. :param class model: Model class. @@ -455,6 +456,7 @@ def _load_arguments(): def _load_descriptions(): return extract_full_summary_from_signature(op_handler) + # pylint: disable=inconsistent-return-statements def _execute_command(kwargs): from msrest.paging import Paged from msrest.exceptions import ValidationError, ClientRequestError diff --git a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_params.py b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_params.py index 36c6ccbf046..a457bcfce0b 100644 --- a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_params.py +++ b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/_params.py @@ -4,6 +4,9 @@ # -------------------------------------------------------------------------------------------- from argcomplete.completers import FilesCompleter + +from knack.arguments import CLIArgumentType + from azure.mgmt.batch.models.batch_management_client_enums import \ (AccountKeyType) from azure.batch.models.batch_service_client_enums import \ @@ -21,8 +24,6 @@ environment_setting_format, validate_cert_settings, resource_file_format, validate_client_parameters) -from knack.arguments import CLIArgumentType - # pylint: disable=line-too-long, too-many-statements def load_arguments(self, _): diff --git a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/custom.py b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/custom.py index c204bcfe7c5..1d1ac3ba2ba 100644 --- a/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/custom.py +++ b/src/command_modules/azure-cli-batch/azure/cli/command_modules/batch/custom.py @@ -7,7 +7,10 @@ import base64 from six.moves.urllib.parse import urlsplit # pylint: disable=import-error +from knack.log import get_logger + from msrest.exceptions import DeserializationError + from azure.mgmt.batch import BatchManagementClient from azure.mgmt.batch.models import (BatchAccountCreateParameters, AutoStorageBaseProperties, @@ -23,8 +26,6 @@ from azure.cli.core.profiles import get_sdk, ResourceType from azure.cli.core._profile import Profile -from knack.log import get_logger - logger = get_logger(__name__) MAX_TASKS_PER_REQUEST = 100 @@ -77,6 +78,7 @@ def update_account(client, resource_group_name, account_name, auto_storage=properties) +# pylint: disable=inconsistent-return-statements def login_account(cmd, client, resource_group_name, account_name, shared_key_auth=False, show=False): account = client.get(resource_group_name=resource_group_name, account_name=account_name) diff --git a/src/command_modules/azure-cli-cdn/azure/cli/command_modules/cdn/_params.py b/src/command_modules/azure-cli-cdn/azure/cli/command_modules/cdn/_params.py index d0ae9850c96..3033e667bf1 100644 --- a/src/command_modules/azure-cli-cdn/azure/cli/command_modules/cdn/_params.py +++ b/src/command_modules/azure-cli-cdn/azure/cli/command_modules/cdn/_params.py @@ -4,13 +4,13 @@ # -------------------------------------------------------------------------------------------- import argparse +from knack.arguments import CLIArgumentType + from azure.mgmt.cdn.models import QueryStringCachingBehavior, SkuName from azure.cli.core.commands.parameters import get_three_state_flag, tags_type, get_enum_type from azure.cli.core.commands.validators import get_default_location_from_resource_group -from knack.arguments import CLIArgumentType - from ._validators import validate_origin diff --git a/src/command_modules/azure-cli-cloud/azure/cli/command_modules/cloud/custom.py b/src/command_modules/azure-cli-cloud/azure/cli/command_modules/cloud/custom.py index 38139ab2758..caace4ed4f4 100644 --- a/src/command_modules/azure-cli-cloud/azure/cli/command_modules/cloud/custom.py +++ b/src/command_modules/azure-cli-cloud/azure/cli/command_modules/cloud/custom.py @@ -5,7 +5,9 @@ # pylint: disable=unused-argument from knack.util import CLIError, to_snake_case + from msrestazure.azure_cloud import _populate_from_metadata_endpoint, MetadataEndpointError + from azure.cli.core.cloud import (Cloud, get_clouds, get_cloud, diff --git a/src/command_modules/azure-cli-cognitiveservices/azure/cli/command_modules/cognitiveservices/custom.py b/src/command_modules/azure-cli-cognitiveservices/azure/cli/command_modules/cognitiveservices/custom.py index a2e20ef7a33..709d44ebdc3 100644 --- a/src/command_modules/azure-cli-cognitiveservices/azure/cli/command_modules/cognitiveservices/custom.py +++ b/src/command_modules/azure-cli-cognitiveservices/azure/cli/command_modules/cognitiveservices/custom.py @@ -2,12 +2,13 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.mgmt.cognitiveservices.models import CognitiveServicesAccountCreateParameters, Sku from knack.prompting import prompt_y_n from knack.util import CLIError from knack.log import get_logger +from azure.mgmt.cognitiveservices.models import CognitiveServicesAccountCreateParameters, Sku + logger = get_logger(__name__) diff --git a/src/command_modules/azure-cli-configure/azure/cli/command_modules/configure/custom.py b/src/command_modules/azure-cli-configure/azure/cli/command_modules/configure/custom.py index 275c100cfeb..38cffa8feee 100644 --- a/src/command_modules/azure-cli-configure/azure/cli/command_modules/configure/custom.py +++ b/src/command_modules/azure-cli-configure/azure/cli/command_modules/configure/custom.py @@ -7,6 +7,10 @@ import os from six.moves import configparser +from knack.log import get_logger +from knack.prompting import prompt, prompt_y_n, prompt_choice_list, prompt_pass, NoTTYException +from knack.util import CLIError + from azure.cli.command_modules.configure._consts import (OUTPUT_LIST, LOGIN_METHOD_LIST, MSG_INTRO, MSG_CLOSING, @@ -20,10 +24,6 @@ MSG_PROMPT_FILE_LOGGING) from azure.cli.command_modules.configure._utils import get_default_from_config -from knack.log import get_logger -from knack.prompting import prompt, prompt_y_n, prompt_choice_list, prompt_pass, NoTTYException -from knack.util import CLIError - answers = {} logger = get_logger(__name__) diff --git a/src/command_modules/azure-cli-container/azure/cli/command_modules/container/custom.py b/src/command_modules/azure-cli-container/azure/cli/command_modules/container/custom.py index 51bccf3c63b..1b6db21b636 100644 --- a/src/command_modules/azure-cli-container/azure/cli/command_modules/container/custom.py +++ b/src/command_modules/azure-cli-container/azure/cli/command_modules/container/custom.py @@ -95,6 +95,7 @@ def create_container(client, return client.create_or_update(resource_group_name, name, cgroup) +# pylint: disable=inconsistent-return-statements def create_resource_requirements(cpu, memory): """Create resource requirements. """ if cpu or memory: @@ -154,6 +155,7 @@ def create_azure_file_volume(azure_file_volume_share_name, azure_file_volume_acc return [Volume(name=AZURE_FILE_VOLUME_NAME, azure_file=azure_file_volume)] if azure_file_volume else None +# pylint: disable=inconsistent-return-statements def create_azure_file_volume_mount(azure_file_volume, azure_file_volume_mount_path): """Create Azure File volume mount. """ if azure_file_volume_mount_path: @@ -163,6 +165,7 @@ def create_azure_file_volume_mount(azure_file_volume, azure_file_volume_mount_pa return [VolumeMount(name=AZURE_FILE_VOLUME_NAME, mount_path=azure_file_volume_mount_path)] +# pylint: disable=inconsistent-return-statements def create_ip_address(ip_address, ports): """Create IP address. """ if ip_address and ip_address.lower() == 'public': diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/__init__.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/__init__.py index 659a98a6ff7..5dd7e7192ef 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/__init__.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/__init__.py @@ -3,12 +3,29 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- # pylint: disable=unused-import -import azure.cli.command_modules.dla._help +from azure.cli.core import AzCommandsLoader -def load_params(_): - import azure.cli.command_modules.dla._params # pylint: disable=redefined-outer-name, unused-variable +from azure.cli.command_modules.dla._help import helps # pylint: disable=unused-import -def load_commands(): - import azure.cli.command_modules.dla.commands # pylint: disable=redefined-outer-name, unused-variable +class DataLakeAnalyticsCommandsLoader(AzCommandsLoader): + + def __init__(self, cli_ctx=None): + from azure.cli.core.commands import CliCommandType + dla_custom = CliCommandType(operations_tmpl='azure.cli.command_modules.dla.custom#{}') + super(DataLakeAnalyticsCommandsLoader, self).__init__(cli_ctx=cli_ctx, + min_profile='2017-03-10-profile', + custom_command_type=dla_custom) + + def load_command_table(self, args): + from azure.cli.command_modules.dla.commands import load_command_table + load_command_table(self, args) + return self.command_table + + def load_arguments(self, command): + from azure.cli.command_modules.dla._params import load_arguments + load_arguments(self, command) + + +COMMAND_LOADER_CLS = DataLakeAnalyticsCommandsLoader diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_client_factory.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_client_factory.py index 116abf22beb..5eebc1ea663 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_client_factory.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_client_factory.py @@ -2,78 +2,81 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core._profile import CLOUD -def cf_dla_account(_): +def cf_dla_account(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient - return get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).account + return get_mgmt_service_client(cli_ctx, DataLakeAnalyticsAccountManagementClient).account -def cf_dla_account_firewall(_): +def cf_dla_account_firewall(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient - return get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).firewall_rules + return get_mgmt_service_client(cli_ctx, DataLakeAnalyticsAccountManagementClient).firewall_rules -def cf_dla_account_compute_policy(_): +def cf_dla_account_compute_policy(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient - return get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).compute_policies + return get_mgmt_service_client(cli_ctx, DataLakeAnalyticsAccountManagementClient).compute_policies -def cf_dla_account_storage(_): +def cf_dla_account_storage(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient - return get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).storage_accounts + return get_mgmt_service_client(cli_ctx, DataLakeAnalyticsAccountManagementClient).storage_accounts -def cf_dla_account_adls(_): +def cf_dla_account_adls(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient - return get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).data_lake_store_accounts + return get_mgmt_service_client(cli_ctx, DataLakeAnalyticsAccountManagementClient).data_lake_store_accounts -def cf_dla_catalog(_): +def cf_dla_catalog(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.catalog import DataLakeAnalyticsCatalogManagementClient return get_mgmt_service_client( + cli_ctx, DataLakeAnalyticsCatalogManagementClient, subscription_bound=False, base_url_bound=False, - resource=CLOUD.endpoints.active_directory_data_lake_resource_id, - adla_catalog_dns_suffix=CLOUD.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).catalog + resource=cli_ctx.cloud.endpoints.active_directory_data_lake_resource_id, + adla_catalog_dns_suffix=cli_ctx.cloud.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).catalog -def cf_dla_job(_): +def cf_dla_job(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.job import DataLakeAnalyticsJobManagementClient return get_mgmt_service_client( + cli_ctx, DataLakeAnalyticsJobManagementClient, subscription_bound=False, base_url_bound=False, - resource=CLOUD.endpoints.active_directory_data_lake_resource_id, - adla_job_dns_suffix=CLOUD.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).job + resource=cli_ctx.cloud.endpoints.active_directory_data_lake_resource_id, + adla_job_dns_suffix=cli_ctx.cloud.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).job -def cf_dla_job_recurrence(_): +def cf_dla_job_recurrence(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.job import DataLakeAnalyticsJobManagementClient return get_mgmt_service_client( + cli_ctx, DataLakeAnalyticsJobManagementClient, subscription_bound=False, base_url_bound=False, - resource=CLOUD.endpoints.active_directory_data_lake_resource_id, - adla_job_dns_suffix=CLOUD.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).recurrence + resource=cli_ctx.cloud.endpoints.active_directory_data_lake_resource_id, + adla_job_dns_suffix=cli_ctx.cloud.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).recurrence -def cf_dla_job_pipeline(_): +def cf_dla_job_pipeline(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.job import DataLakeAnalyticsJobManagementClient return get_mgmt_service_client( + cli_ctx, DataLakeAnalyticsJobManagementClient, subscription_bound=False, base_url_bound=False, - resource=CLOUD.endpoints.active_directory_data_lake_resource_id, - adla_job_dns_suffix=CLOUD.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).pipeline + resource=cli_ctx.cloud.endpoints.active_directory_data_lake_resource_id, + adla_job_dns_suffix=cli_ctx.cloud.suffixes.azure_datalake_analytics_catalog_and_job_endpoint).pipeline diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_params.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_params.py index 2588cff1e49..21d055dc68f 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_params.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_params.py @@ -3,80 +3,99 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- from argcomplete.completers import FilesCompleter -from azure.cli.core.commands import register_cli_argument -from azure.cli.core.commands.parameters import tags_type, get_resource_name_completion_list, resource_group_name_type - -from azure.cli.command_modules.dla._validators import (validate_resource_group_name, - datetime_format, - process_dla_job_submit_namespace) - - -from azure.mgmt.datalake.analytics.account.models.data_lake_analytics_account_management_client_enums \ - import (FirewallState, - TierType, - FirewallAllowAzureIpsState, - AADObjectType) - -from azure.mgmt.datalake.analytics.job.models.data_lake_analytics_job_management_client_enums \ - import (CompileMode, - JobState, - JobResult) - -from knack.arguments import CLIArgumentType, enum_choice_list - -# ARGUMENT DEFINITIONS -# pylint: disable=line-too-long -datalake_analytics_name_type = CLIArgumentType(help='Name of the Data Lake Analytics account.', options_list=('--account_name',), completer=get_resource_name_completion_list('Microsoft.DataLakeAnalytics/accounts'), id_part='name') - -# PARAMETER REGISTRATIONS -# data lake analytics common params -register_cli_argument('dla', 'resource_group_name', resource_group_name_type, id_part=None, required=False, help='If not specified, will attempt to discover the resource group for the specified Data Lake Analytics account.', validator=validate_resource_group_name) -register_cli_argument('dla', 'top', help='Maximum number of items to return.', type=int) -register_cli_argument('dla', 'skip', help='The number of items to skip over before returning elements.', type=int) -register_cli_argument('dla', 'count', help='The Boolean value of true or false to request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.', type=bool) - -# account params -register_cli_argument('dla', 'account_name', datalake_analytics_name_type, options_list=('--account', '-n')) -register_cli_argument('dla account', 'tags', tags_type) -register_cli_argument('dla account', 'tier', help='The desired commitment tier for this account to use.', **enum_choice_list(TierType)) -register_cli_argument('dla account create', 'resource_group_name', resource_group_name_type, validator=None) -register_cli_argument('dla account create', 'account_name', datalake_analytics_name_type, options_list=('--account', '-n'), completer=None) -register_cli_argument('dla account update', 'firewall_state', help='Enable/disable existing firewall rules.', **enum_choice_list(FirewallState)) -register_cli_argument('dla account update', 'allow_azure_ips', help='Allow/block Azure originating IPs through the firewall', **enum_choice_list(FirewallAllowAzureIpsState)) -register_cli_argument('dla account update', 'max_job_count', help='The maximum supported jobs running under the account at the same time.', type=int) -register_cli_argument('dla account update', 'max_degree_of_parallelism', help='The maximum supported degree of parallelism for this account.', type=int) -register_cli_argument('dla account update', 'query_store_retention', help='The number of days that job metadata is retained.', type=int) -register_cli_argument('dla account list', 'resource_group_name', resource_group_name_type, validator=None) - -# storage parameters -register_cli_argument('dla account blob-storage', 'access_key', help='the access key associated with this Azure Storage account that will be used to connect to it') -register_cli_argument('dla account blob-storage', 'suffix', help='the optional suffix for the storage account') - -# Job params -# pylint: disable=line-too-long -register_cli_argument('dla job submit', 'compile_mode', help='Indicates the type of compilation to be done on this job. Valid values are: \'Semantic\' (Only performs semantic checks and necessary sanity checks), \'Full\' (full compilation) and \'SingleBox\' (Full compilation performed locally)', **enum_choice_list(CompileMode)) -register_cli_argument('dla job submit', 'compile_only', help='Indicates that the submission should only build the job and not execute if set to true.', action='store_true') -register_cli_argument('dla job submit', 'script', completer=FilesCompleter(), help="The script to submit. This is either the script contents or use `@` to load the script from a file", validator=process_dla_job_submit_namespace) -register_cli_argument('dla job wait', 'max_wait_time_sec', help='The maximum amount of time to wait before erroring out. Default value is to never timeout. Any value <= 0 means never timeout', type=int) -register_cli_argument('dla job wait', 'wait_interval_sec', help='The polling interval between checks for the job status, in seconds.', type=int) -register_cli_argument('dla job list', 'submitted_after', help='A filter which returns jobs only submitted after the specified time, in ISO-8601 format.', type=datetime_format) -register_cli_argument('dla job list', 'submitted_before', help='A filter which returns jobs only submitted before the specified time, in ISO-8601 format.', type=datetime_format) -register_cli_argument('dla job list', 'state', help='A filter which returns jobs with only the specified state(s).', nargs='*', **enum_choice_list(JobState)) -register_cli_argument('dla job list', 'result', help='A filter which returns jobs with only the specified result(s).', nargs='*', **enum_choice_list(JobResult)) -register_cli_argument('dla job list', 'submitter', help='A filter which returns jobs only by the specified submitter.') -register_cli_argument('dla job list', 'name', help='A filter which returns jobs only by the specified friendly name.') -register_cli_argument('dla job list', 'pipeline_id', help='A filter which returns jobs only containing the specified pipeline_id.') -register_cli_argument('dla job list', 'recurrence_id', help='A filter which returns jobs only containing the specified recurrence_id.') - -# credential params -register_cli_argument('dla catalog credential create', 'credential_user_password', options_list=('--password', '-p'), help='Password for the credential user. Will prompt if not given.') -register_cli_argument('dla catalog credential create', 'credential_user_name', options_list=('--user-name',)) -register_cli_argument('dla catalog credential update', 'credential_user_name', options_list=('--user-name',)) -register_cli_argument('dla catalog credential update', 'credential_user_password', options_list=('--password', '-p'), help='Current password for the credential user. Will prompt if not given.') -register_cli_argument('dla catalog credential update', 'new_credential_user_password', options_list=('--new-password',), help='New password for the credential user. Will prompt if not given.') - -# compute policy params -register_cli_argument('dla account compute_policy', 'max_dop_per_job', help='The maximum degree of parallelism allowed per job for this policy. At least one of --min-priority-per-job and --max-dop-per-job must be specified.', type=int) -register_cli_argument('dla account compute_policy', 'min_priority_per_job', help='The minimum priority allowed per job for this policy. At least one of --min-priority-per-job and --max-dop-per-job must be specified.', type=int) -register_cli_argument('dla account compute_policy create', 'object_id', help='The Azure Active Directory object ID of the user, group or service principal to apply the policy to.') -register_cli_argument('dla account compute_policy create', 'object_type', help='The Azure Active Directory object type associated with the supplied object id.', **enum_choice_list(AADObjectType)) + +from knack.arguments import CLIArgumentType + +from azure.cli.core.commands.parameters import ( + tags_type, get_resource_name_completion_list, resource_group_name_type, get_enum_type) + +from azure.cli.command_modules.dla._validators import validate_resource_group_name, datetime_format + +from azure.mgmt.datalake.analytics.account.models.data_lake_analytics_account_management_client_enums import ( + FirewallState, + TierType, + FirewallAllowAzureIpsState, + AADObjectType) + +from azure.mgmt.datalake.analytics.job.models.data_lake_analytics_job_management_client_enums import ( + CompileMode, + JobState, + JobResult) + + +# pylint: disable=line-too-long, too-many-statements +def load_arguments(self, _): + + datalake_analytics_name_type = CLIArgumentType(help='Name of the Data Lake Analytics account.', options_list=('--account_name',), completer=get_resource_name_completion_list('Microsoft.DataLakeAnalytics/accounts'), id_part='name') + + # PARAMETER REGISTRATIONS + # common + with self.argument_context('dla') as c: + c.argument('resource_group_name', resource_group_name_type, id_part=None, required=False, help='If not specified, will attempt to discover the resource group for the specified Data Lake Analytics account.', validator=validate_resource_group_name) + c.argument('top', help='Maximum number of items to return.', type=int) + c.argument('skip', help='The number of items to skip over before returning elements.', type=int) + c.argument('count', help='The Boolean value of true or false to request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.', type=bool) + c.argument('account_name', datalake_analytics_name_type, options_list=['--account', '-n']) + + # account + with self.argument_context('dla account') as c: + c.argument('tags', tags_type) + c.argument('tier', arg_type=get_enum_type(TierType), help='The desired commitment tier for this account to use.') + + with self.argument_context('dla account create') as c: + c.argument('resource_group_name', resource_group_name_type, validator=None) + c.argument('account_name', datalake_analytics_name_type, options_list=('--account', '-n'), completer=None) + + with self.argument_context('dla account update') as c: + c.argument('firewall_state', help='Enable/disable existing firewall rules.', arg_type=get_enum_type(FirewallState)) + c.argument('allow_azure_ips', help='Allow/block Azure originating IPs through the firewall', arg_type=get_enum_type(FirewallAllowAzureIpsState)) + c.argument('max_job_count', help='The maximum supported jobs running under the account at the same time.', type=int) + c.argument('max_degree_of_parallelism', help='The maximum supported degree of parallelism for this account.', type=int) + c.argument('query_store_retention', help='The number of days that job metadata is retained.', type=int) + + with self.argument_context('dla account list') as c: + c.argument('resource_group_name', resource_group_name_type, validator=None) + + # storage + with self.argument_context('dla account blob-storage') as c: + c.argument('access_key', help='the access key associated with this Azure Storage account that will be used to connect to it') + c.argument('suffix', help='the optional suffix for the storage account') + + # job + with self.argument_context('dla job submit') as c: + c.argument('compile_mode', arg_type=get_enum_type(CompileMode), help='Indicates the type of compilation to be done on this job. Valid values are: \'Semantic\' (Only performs semantic checks and necessary sanity checks), \'Full\' (full compilation) and \'SingleBox\' (Full compilation performed locally)') + c.argument('compile_only', help='Indicates that the submission should only build the job and not execute if set to true.', action='store_true') + c.argument('script', completer=FilesCompleter(), help="The script to submit. This is either the script contents or use `@` to load the script from a file") + + with self.argument_context('dla job wait') as c: + c.argument('max_wait_time_sec', help='The maximum amount of time to wait before erroring out. Default value is to never timeout. Any value <= 0 means never timeout', type=int) + c.argument('wait_interval_sec', help='The polling interval between checks for the job status, in seconds.', type=int) + + with self.argument_context('dla job list') as c: + c.argument('submitted_after', help='A filter which returns jobs only submitted after the specified time, in ISO-8601 format.', type=datetime_format) + c.argument('submitted_before', help='A filter which returns jobs only submitted before the specified time, in ISO-8601 format.', type=datetime_format) + c.argument('state', arg_type=get_enum_type(JobState), help='A filter which returns jobs with only the specified state(s).', nargs='*') + c.argument('result', arg_type=get_enum_type(JobResult), help='A filter which returns jobs with only the specified result(s).', nargs='*') + c.argument('submitter', help='A filter which returns jobs only by the specified submitter.') + c.argument('name', help='A filter which returns jobs only by the specified friendly name.') + c.argument('pipeline_id', help='A filter which returns jobs only containing the specified pipeline_id.') + c.argument('recurrence_id', help='A filter which returns jobs only containing the specified recurrence_id.') + + # credential + with self.argument_context('dla catalog credential create') as c: + c.argument('credential_user_password', options_list=['--password', '-p'], help='Password for the credential user. Will prompt if not given.') + c.argument('credential_user_name', options_list=['--user-name']) + + with self.argument_context('dla catalog credential update') as c: + c.argument('credential_user_name', options_list=['--user-name']) + c.argument('credential_user_password', options_list=['--password', '-p'], help='Current password for the credential user. Will prompt if not given.') + c.argument('new_credential_user_password', options_list=['--new-password'], help='New password for the credential user. Will prompt if not given.') + + # compute policy + with self.argument_context('dla account compute_policy') as c: + c.argument('max_dop_per_job', help='The maximum degree of parallelism allowed per job for this policy. At least one of --min-priority-per-job and --max-dop-per-job must be specified.', type=int) + c.argument('min_priority_per_job', help='The minimum priority allowed per job for this policy. At least one of --min-priority-per-job and --max-dop-per-job must be specified.', type=int) + + with self.argument_context('dla account compute_policy create') as c: + c.argument('object_id', help='The Azure Active Directory object ID of the user, group or service principal to apply the policy to.') + c.argument('object_type', arg_type=get_enum_type(AADObjectType), help='The Azure Active Directory object type associated with the supplied object id.') diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_validators.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_validators.py index b2d6cb30c03..43d1f13b10d 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_validators.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/_validators.py @@ -5,10 +5,12 @@ from msrest.serialization import Deserializer from msrest.exceptions import DeserializationError +from msrestazure.tools import parse_resource_id + +from knack.util import CLIError + from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.analytics.account import DataLakeAnalyticsAccountManagementClient -from azure.cli.core.commands.arm import parse_resource_id -from knack.util import CLIError # Helpers @@ -29,10 +31,10 @@ def _get_resource_group_from_account_name(client, account_name): # COMMAND NAMESPACE VALIDATORS -def validate_resource_group_name(ns): +def validate_resource_group_name(cmd, ns): if not ns.resource_group_name: account_name = ns.account_name - client = get_mgmt_service_client(DataLakeAnalyticsAccountManagementClient).account + client = get_mgmt_service_client(cmd.cli_ctx, DataLakeAnalyticsAccountManagementClient).account group_name = _get_resource_group_from_account_name(client, account_name) ns.resource_group_name = group_name diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/commands.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/commands.py index fcf448f7e96..4d82ab043fb 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/commands.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/commands.py @@ -4,121 +4,185 @@ # -------------------------------------------------------------------------------------------- # pylint: disable=line-too-long -from azure.cli.core.commands import cli_command -from azure.cli.core.profiles import supported_api_version, PROFILE_TYPE -from azure.cli.command_modules.dla._client_factory import (cf_dla_account, - cf_dla_account_firewall, - cf_dla_account_adls, - cf_dla_account_storage, - cf_dla_job, - cf_dla_catalog, - cf_dla_job_pipeline, - cf_dla_job_recurrence, - cf_dla_account_compute_policy) - -if not supported_api_version(PROFILE_TYPE, max_api='2017-03-09-profile'): - adla_format_path = 'azure.mgmt.datalake.analytics.{}.operations.{}#{}.{}' - adla_custom_format_path = 'azure.cli.command_modules.dla.custom#{}' +from azure.cli.core.commands import CliCommandType +from azure.cli.command_modules.dla._client_factory import ( + cf_dla_account, + cf_dla_account_firewall, + cf_dla_account_adls, + cf_dla_account_storage, + cf_dla_job, + cf_dla_catalog, + cf_dla_job_pipeline, + cf_dla_job_recurrence, + cf_dla_account_compute_policy) +from azure.cli.command_modules.dla._validators import process_dla_job_submit_namespace + + +# pylint: disable=too-many-statements +def load_command_table(self, _): + + adla_format_path = 'azure.mgmt.datalake.analytics.{}.operations.{}#{}.{{}}' + + dla_account_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('account', 'account_operations', 'AccountOperations'), + client_factory=cf_dla_account) + + dla_firewall_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('account', 'firewall_rules_operations', 'FirewallRulesOperations'), + client_factory=cf_dla_account_firewall) + + dla_job_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('job', 'job_operations', 'JobOperations'), + client_factory=cf_dla_job) + + dla_job_pipeline_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('job', 'pipeline_operations', 'PipelineOperations'), + client_factory=cf_dla_job_pipeline) + + dla_job_recurrence_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('job', 'recurrence_operations', 'RecurrenceOperations'), + client_factory=cf_dla_job_recurrence) + + dla_storage_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('account', 'storage_accounts_operations', 'StorageAccountsOperations'), + client_factory=cf_dla_account_storage) + + dla_dls_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('account', 'data_lake_store_accounts_operations', 'DataLakeStoreAccountsOperations'), + client_factory=cf_dla_account_adls + ) + + dla_catalog_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations'), + client_factory=cf_dla_catalog + ) + + dla_compute_policy_sdk = CliCommandType( + operations_tmpl=adla_format_path.format('account', 'compute_policies_operations', 'ComputePoliciesOperations'), + client_factory=cf_dla_account_compute_policy + ) # account operations - cli_command(__name__, 'dla account create', adla_custom_format_path.format('create_adla_account'), cf_dla_account) - cli_command(__name__, 'dla account update', adla_custom_format_path.format('update_adla_account'), cf_dla_account) - cli_command(__name__, 'dla account list', adla_custom_format_path.format('list_adla_account'), cf_dla_account) - cli_command(__name__, 'dla account show', adla_format_path.format('account', 'account_operations', 'AccountOperations', 'get'), cf_dla_account) - cli_command(__name__, 'dla account delete', adla_format_path.format('account', 'account_operations', 'AccountOperations', 'delete'), cf_dla_account) + with self.command_group('dla account', dla_account_sdk, client_factory=cf_dla_account) as g: + g.custom_command('create', 'create_adla_account') + g.custom_command('update', 'update_adla_account') + g.custom_command('list', 'list_adla_account') + g.command('show', 'get') + g.command('delete', 'delete') # account fire wall operations - cli_command(__name__, 'dla account firewall create', adla_custom_format_path.format('add_adla_firewall_rule'), cf_dla_account_firewall) - cli_command(__name__, 'dla account firewall update', adla_format_path.format('account', 'firewall_rules_operations', 'FirewallRulesOperations', 'update'), cf_dla_account_firewall) - cli_command(__name__, 'dla account firewall list', adla_format_path.format('account', 'firewall_rules_operations', 'FirewallRulesOperations', 'list_by_account'), cf_dla_account_firewall) - cli_command(__name__, 'dla account firewall show', adla_format_path.format('account', 'firewall_rules_operations', 'FirewallRulesOperations', 'get'), cf_dla_account_firewall) - cli_command(__name__, 'dla account firewall delete', adla_format_path.format('account', 'firewall_rules_operations', 'FirewallRulesOperations', 'delete'), cf_dla_account_firewall) + with self.command_group('dla account firewall', dla_firewall_sdk, client_factory=cf_dla_account_firewall) as g: + g.custom_command('create', 'add_adla_firewall_rule') + g.command('update', 'update') + g.command('list', 'list_by_account') + g.command('show', 'get') + g.command('delete', 'delete') # job operations # todo: update to allow for inclusion of statistics/debug data in show - cli_command(__name__, 'dla job submit', adla_custom_format_path.format('submit_adla_job'), cf_dla_job) - cli_command(__name__, 'dla job wait', adla_custom_format_path.format('wait_adla_job'), cf_dla_job) - cli_command(__name__, 'dla job show', adla_format_path.format('job', 'job_operations', 'JobOperations', 'get'), cf_dla_job) - cli_command(__name__, 'dla job cancel', adla_format_path.format('job', 'job_operations', 'JobOperations', 'cancel'), cf_dla_job) - cli_command(__name__, 'dla job list', adla_custom_format_path.format('list_adla_jobs'), cf_dla_job) + with self.command_group('dla job', dla_job_sdk, client_factory=cf_dla_job) as g: + g.custom_command('submit', 'submit_adla_job', validator=process_dla_job_submit_namespace) + g.custom_command('wait', 'wait_adla_job') + g.command('show', 'get') + g.command('cancel', 'cancel') + g.custom_command('list', 'list_adla_jobs') # job relationship operations - cli_command(__name__, 'dla job pipeline show', adla_format_path.format('job', 'pipeline_operations', 'PipelineOperations', 'get'), cf_dla_job_pipeline) - cli_command(__name__, 'dla job pipeline list', adla_format_path.format('job', 'pipeline_operations', 'PipelineOperations', 'list'), cf_dla_job_pipeline) - cli_command(__name__, 'dla job recurrence show', adla_format_path.format('job', 'recurrence_operations', 'RecurrenceOperations', 'get'), cf_dla_job_recurrence) - cli_command(__name__, 'dla job recurrence list', adla_format_path.format('job', 'recurrence_operations', 'RecurrenceOperations', 'list'), cf_dla_job_recurrence) + with self.command_group('dla job pipeline', dla_job_pipeline_sdk) as g: + g.command('show', 'get') + g.command('list', 'list') - # account data source operations - cli_command(__name__, 'dla account blob-storage show', adla_format_path.format('account', 'storage_accounts_operations', 'StorageAccountsOperations', 'get'), cf_dla_account_storage) - cli_command(__name__, 'dla account blob-storage add', adla_custom_format_path.format('add_adla_blob_storage'), cf_dla_account_storage) - cli_command(__name__, 'dla account blob-storage update', adla_custom_format_path.format('update_adla_blob_storage'), cf_dla_account_storage) - cli_command(__name__, 'dla account blob-storage delete', adla_format_path.format('account', 'storage_accounts_operations', 'StorageAccountsOperations', 'delete'), cf_dla_account_storage) - cli_command(__name__, 'dla account blob-storage list', adla_format_path.format('account', 'storage_accounts_operations', 'StorageAccountsOperations', 'list_by_account'), cf_dla_account_storage) + with self.command_group('dla job recurrence', dla_job_recurrence_sdk) as g: + g.command('show', 'get') + g.command('list', 'list') - cli_command(__name__, 'dla account data-lake-store show', adla_format_path.format('account', 'data_lake_store_accounts_operations', 'DataLakeStoreAccountsOperations', 'get'), cf_dla_account_adls) - cli_command(__name__, 'dla account data-lake-store list', adla_format_path.format('account', 'data_lake_store_accounts_operations', 'DataLakeStoreAccountsOperations', 'list_by_account'), cf_dla_account_adls) - cli_command(__name__, 'dla account data-lake-store add', adla_format_path.format('account', 'data_lake_store_accounts_operations', 'DataLakeStoreAccountsOperations', 'add'), cf_dla_account_adls) - cli_command(__name__, 'dla account data-lake-store delete', adla_format_path.format('account', 'data_lake_store_accounts_operations', 'DataLakeStoreAccountsOperations', 'delete'), cf_dla_account_adls) + # account data source operations + with self.command_group('dla account blob-storage', dla_storage_sdk, client_factory=cf_dla_account_storage) as g: + g.command('show', 'get') + g.custom_command('add', 'add_adla_blob_storage') + g.custom_command('update', 'update_adla_blob_storage') + g.command('delete', 'delete') + g.command('list', 'list_by_account') + + with self.command_group('dla account data-lake-store', dla_dls_sdk) as g: + g.command('show', 'get') + g.command('list', 'list_by_account') + g.command('add', 'add') + g.command('delete', 'delete') # catalog operations # credential - cli_command(__name__, 'dla catalog credential create', adla_custom_format_path.format('create_adla_catalog_credential'), cf_dla_catalog) - cli_command(__name__, 'dla catalog credential show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_credential'), cf_dla_catalog) - cli_command(__name__, 'dla catalog credential update', adla_custom_format_path.format('update_adla_catalog_credential'), cf_dla_catalog) - cli_command(__name__, 'dla catalog credential list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_credentials'), cf_dla_catalog) - cli_command(__name__, 'dla catalog credential delete', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'delete_credential'), cf_dla_catalog) + with self.command_group('dla catalog credential', dla_catalog_sdk, client_factory=cf_dla_catalog) as g: + g.custom_command('create', 'create_adla_catalog_credential') + g.command('show', 'get_credential') + g.custom_command('update', 'update_adla_catalog_credential') + g.command('list', 'list_credentials') + g.command('delete', 'delete_credential') # database - cli_command(__name__, 'dla catalog database show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_database'), cf_dla_catalog) - cli_command(__name__, 'dla catalog database list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_databases'), cf_dla_catalog) + with self.command_group('dla catalog database', dla_catalog_sdk) as g: + g.command('show', 'get_database') + g.command('list', 'list_databases') # schema - cli_command(__name__, 'dla catalog schema show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_schema'), cf_dla_catalog) - cli_command(__name__, 'dla catalog schema list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_schemas'), cf_dla_catalog) + with self.command_group('dla catalog schema', dla_catalog_sdk) as g: + g.command('show', 'get_schema') + g.command('list', 'list_schemas') # table - cli_command(__name__, 'dla catalog table show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_table'), cf_dla_catalog) - cli_command(__name__, 'dla catalog table list', adla_custom_format_path.format('list_catalog_tables'), cf_dla_catalog) + with self.command_group('dla catalog table', dla_catalog_sdk, client_factory=cf_dla_catalog) as g: + g.command('show', 'get_table') + g.custom_command('list', 'list_catalog_tables') # assembly - cli_command(__name__, 'dla catalog assembly show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_assembly'), cf_dla_catalog) - cli_command(__name__, 'dla catalog assembly list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_assemblies'), cf_dla_catalog) + with self.command_group('dla catalog assembly', dla_catalog_sdk) as g: + g.command('show', 'get_assembly') + g.command('list', 'list_assemblies') # external data source - cli_command(__name__, 'dla catalog external-data-source show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_external_data_source'), cf_dla_catalog) - cli_command(__name__, 'dla catalog external-data-source list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_external_data_sources'), cf_dla_catalog) + with self.command_group('dla catalog external-data-source', dla_catalog_sdk) as g: + g.command('show', 'get_external_data_source') + g.command('list', 'list_external_data_sources') # get procedure - cli_command(__name__, 'dla catalog procedure show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_procedure'), cf_dla_catalog) - cli_command(__name__, 'dla catalog procedure list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_procedures'), cf_dla_catalog) + with self.command_group('dla catalog procedure', dla_catalog_sdk) as g: + g.command('show', 'get_procedure') + g.command('list', 'list_procedures') # get table partition - cli_command(__name__, 'dla catalog table-partition show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_table_partition'), cf_dla_catalog) - cli_command(__name__, 'dla catalog table-partition list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_table_partitions'), cf_dla_catalog) + with self.command_group('dla catalog table-partition', dla_catalog_sdk) as g: + g.command('show', 'get_table_partition') + g.command('list', 'list_table_partitions') # get table statistics - cli_command(__name__, 'dla catalog table-stats show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_table_statistic'), cf_dla_catalog) - cli_command(__name__, 'dla catalog table-stats list', adla_custom_format_path.format('list_catalog_table_statistics'), cf_dla_catalog) + with self.command_group('dla catalog table-stats', dla_catalog_sdk, client_factory=cf_dla_catalog) as g: + g.command('show', 'get_table_statistic') + g.custom_command('list', 'list_catalog_table_statistics') # get table types - cli_command(__name__, 'dla catalog table-type show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_table_type'), cf_dla_catalog) - cli_command(__name__, 'dla catalog table-type list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_table_types'), cf_dla_catalog) + with self.command_group('dla catalog table-type', dla_catalog_sdk) as g: + g.command('show', 'get_table_type') + g.command('list', 'list_table_types') # get table valued functions - cli_command(__name__, 'dla catalog tvf show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_table_valued_function'), cf_dla_catalog) - cli_command(__name__, 'dla catalog tvf list', adla_custom_format_path.format('list_catalog_tvfs'), cf_dla_catalog) + with self.command_group('dla catalog tvf', dla_catalog_sdk, client_factory=cf_dla_catalog) as g: + g.command('show', 'get_table_valued_function') + g.custom_command('list', 'list_catalog_tvfs') # get views - cli_command(__name__, 'dla catalog view show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_view'), cf_dla_catalog) - cli_command(__name__, 'dla catalog view list', adla_custom_format_path.format('list_catalog_views'), cf_dla_catalog) + with self.command_group('dla catalog view', dla_catalog_sdk, client_factory=cf_dla_catalog) as g: + g.command('show', 'get_view') + g.custom_command('list', 'list_catalog_views') # get packages - cli_command(__name__, 'dla catalog package show', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'get_package'), cf_dla_catalog) - cli_command(__name__, 'dla catalog package list', adla_format_path.format('catalog', 'catalog_operations', 'CatalogOperations', 'list_packages'), cf_dla_catalog) + with self.command_group('dla catalog package', dla_catalog_sdk) as g: + g.command('show', 'get_package') + g.command('list', 'list_packages') # compute policy - cli_command(__name__, 'dla account compute-policy create', adla_custom_format_path.format('create_adla_compute_policy'), cf_dla_account_compute_policy) - cli_command(__name__, 'dla account compute-policy update', adla_custom_format_path.format('update_adla_compute_policy'), cf_dla_account_compute_policy) - cli_command(__name__, 'dla account compute-policy list', adla_format_path.format('account', 'compute_policies_operations', 'ComputePoliciesOperations', 'list_by_account'), cf_dla_account_compute_policy) - cli_command(__name__, 'dla account compute-policy show', adla_format_path.format('account', 'compute_policies_operations', 'ComputePoliciesOperations', 'get'), cf_dla_account_compute_policy) - cli_command(__name__, 'dla account compute-policy delete', adla_format_path.format('account', 'compute_policies_operations', 'ComputePoliciesOperations', 'delete'), cf_dla_account_compute_policy) + with self.command_group('dla account compute-policy', dla_compute_policy_sdk, client_factory=cf_dla_account_compute_policy) as g: + g.custom_command('create', 'create_adla_compute_policy') + g.custom_command('update', 'update_adla_compute_policy') + g.command('list', 'list_by_account') + g.command('show', 'get') + g.command('delete', 'delete') diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/custom.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/custom.py index 3b9f59936ab..1b634f1c364 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/custom.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/custom.py @@ -5,6 +5,10 @@ import time import uuid +from knack.log import get_logger +from knack.prompting import prompt_pass, NoTTYException +from knack.util import CLIError + from azure.mgmt.datalake.analytics.account.models import (DataLakeAnalyticsAccountUpdateParameters, FirewallRule, DataLakeAnalyticsAccount, @@ -22,28 +26,18 @@ DataLakeAnalyticsCatalogCredentialUpdateParameters) from azure.cli.core.commands.client_factory import get_mgmt_service_client -from knack.prompting import prompt_pass, NoTTYException -from knack.util import CLIError +logger = get_logger(__name__) -# account customiaztions +# region account def list_adla_account(client, resource_group_name=None): account_list = client.list_by_resource_group(resource_group_name=resource_group_name) \ if resource_group_name else client.list() return list(account_list) -def list_adla_jobs(client, - account_name, - top=500, - name=None, - submitter=None, - submitted_after=None, - submitted_before=None, - state=None, - result=None, - pipeline_id=None, - recurrence_id=None): +def list_adla_jobs(client, account_name, top=500, name=None, submitter=None, submitted_after=None, + submitted_before=None, state=None, result=None, pipeline_id=None, recurrence_id=None): odata_filter_list = [] if submitter: odata_filter_list.append("submitter eq '{}'".format(submitter)) @@ -84,19 +78,11 @@ def list_adla_jobs(client, return to_return -def create_adla_account(client, - resource_group_name, - account_name, - default_data_lake_store, - location=None, - tags=None, - max_degree_of_parallelism=30, - max_job_count=3, - query_store_retention=30, - tier=None): +def create_adla_account(cmd, client, resource_group_name, account_name, default_data_lake_store, location=None, + tags=None, max_degree_of_parallelism=30, max_job_count=3, query_store_retention=30, tier=None): adls_list = list() adls_list.append(DataLakeStoreAccountInfo(default_data_lake_store)) - location = location or _get_resource_group_location(resource_group_name) + location = location or _get_resource_group_location(cmd.cli_ctx, resource_group_name) create_params = DataLakeAnalyticsAccount(location, default_data_lake_store, adls_list, @@ -109,15 +95,8 @@ def create_adla_account(client, return client.create(resource_group_name, account_name, create_params).result() -def update_adla_account(client, - account_name, - resource_group_name, - tags=None, - max_degree_of_parallelism=None, - max_job_count=None, - query_store_retention=None, - tier=None, - firewall_state=None, +def update_adla_account(client, account_name, resource_group_name, tags=None, max_degree_of_parallelism=None, + max_job_count=None, query_store_retention=None, tier=None, firewall_state=None, allow_azure_ips=None): update_params = DataLakeAnalyticsAccountUpdateParameters( tags=tags, @@ -129,15 +108,11 @@ def update_adla_account(client, firewall_allow_azure_ips=allow_azure_ips) return client.update(resource_group_name, account_name, update_params).result() +# endregion -# storage customizations -def add_adla_blob_storage(client, - account_name, - storage_account_name, - access_key, - resource_group_name, - suffix=None): +# region storage +def add_adla_blob_storage(client, account_name, storage_account_name, access_key, resource_group_name, suffix=None): return client.add(resource_group_name, account_name, storage_account_name, @@ -145,42 +120,29 @@ def add_adla_blob_storage(client, suffix) -def update_adla_blob_storage(client, - account_name, - storage_account_name, - access_key, - resource_group_name, - suffix=None): +def update_adla_blob_storage(client, account_name, storage_account_name, access_key, resource_group_name, suffix=None): return client.update(resource_group_name, account_name, storage_account_name, access_key, suffix) +# endregion -# firewall customizations -def add_adla_firewall_rule(client, - account_name, - firewall_rule_name, - start_ip_address, - end_ip_address, +# region firewall +def add_adla_firewall_rule(client, account_name, firewall_rule_name, start_ip_address, end_ip_address, resource_group_name): create_params = FirewallRule(start_ip_address, end_ip_address) return client.create_or_update(resource_group_name, account_name, firewall_rule_name, create_params) +# endregion -# compute policy customizations -def create_adla_compute_policy(client, - account_name, - compute_policy_name, - object_id, - object_type, - resource_group_name, - max_dop_per_job=None, - min_priority_per_job=None): +# region compute policy +def create_adla_compute_policy(client, account_name, compute_policy_name, object_id, object_type, + resource_group_name, max_dop_per_job=None, min_priority_per_job=None): if not max_dop_per_job and not min_priority_per_job: raise CLIError('Please specify at least one of --max-dop-per-job and --min-priority-per-job') @@ -199,12 +161,8 @@ def create_adla_compute_policy(client, create_params) -def update_adla_compute_policy(client, - account_name, - compute_policy_name, - resource_group_name, - max_dop_per_job=None, - min_priority_per_job=None): +def update_adla_compute_policy(client, account_name, compute_policy_name, resource_group_name, + max_dop_per_job=None, min_priority_per_job=None): if not max_dop_per_job and not min_priority_per_job: raise CLIError('Please specify at least one of --max-dop-per-job and --min-priority-per-job') @@ -219,15 +177,11 @@ def update_adla_compute_policy(client, compute_policy_name, max_dop_per_job, min_priority_per_job) +# endregion -# catalog customizations -def create_adla_catalog_credential(client, - account_name, - database_name, - credential_name, - credential_user_name, - uri, +# region catalog +def create_adla_catalog_credential(client, account_name, database_name, credential_name, credential_user_name, uri, credential_user_password=None): if not credential_user_password: @@ -243,14 +197,8 @@ def create_adla_catalog_credential(client, client.create_credential(account_name, database_name, credential_name, create_params) -def update_adla_catalog_credential(client, - account_name, - database_name, - credential_name, - credential_user_name, - uri, - credential_user_password=None, - new_credential_user_password=None): +def update_adla_catalog_credential(client, account_name, database_name, credential_name, credential_user_name, uri, + credential_user_password=None, new_credential_user_password=None): if not credential_user_password: try: credential_user_password = prompt_pass('Current Password:', confirm=True) @@ -270,44 +218,32 @@ def update_adla_catalog_credential(client, uri, credential_user_name) client.update_credential(account_name, database_name, credential_name, update_params) +# endregion -# customizations for listing catalog items that support multiple ancestor levels of listing. -def list_catalog_tables(client, - account_name, - database_name, - schema_name=None): +# region catalog lists +def list_catalog_tables(client, account_name, database_name, schema_name=None): if not schema_name: return client.list_tables_by_database(account_name, database_name) return client.list_tables(account_name, database_name, schema_name) -def list_catalog_views(client, - account_name, - database_name, - schema_name=None): +def list_catalog_views(client, account_name, database_name, schema_name=None): if not schema_name: return client.list_views_by_database(account_name, database_name) return client.list_views(account_name, database_name, schema_name) -def list_catalog_tvfs(client, - account_name, - database_name, - schema_name=None): +def list_catalog_tvfs(client, account_name, database_name, schema_name=None): if not schema_name: return client.list_table_valued_functions_by_database(account_name, database_name) return client.list_table_valued_functions(account_name, database_name, schema_name) -def list_catalog_table_statistics(client, - account_name, - database_name, - schema_name=None, - table_name=None): +def list_catalog_table_statistics(client, account_name, database_name, schema_name=None, table_name=None): if not schema_name and table_name: logger.warning('--table-name must be specified with --schema-name to be used. Defaulting to list all statistics in the database: %s', database_name) @@ -318,24 +254,13 @@ def list_catalog_table_statistics(client, return client.list_table_statistics_by_database_and_schema(account_name, database_name, schema_name) return client.list_table_statistics(account_name, database_name, schema_name, table_name) +# endregion -# job customizations -def submit_adla_job(client, - account_name, - job_name, - script, - runtime_version=None, - compile_mode=None, - compile_only=False, - degree_of_parallelism=1, - priority=1000, - recurrence_id=None, - recurrence_name=None, - pipeline_id=None, - pipeline_name=None, - pipeline_uri=None, - run_id=None): +# region job +def submit_adla_job(client, account_name, job_name, script, runtime_version=None, compile_mode=None, compile_only=False, + degree_of_parallelism=1, priority=1000, recurrence_id=None, recurrence_name=None, pipeline_id=None, + pipeline_name=None, pipeline_uri=None, run_id=None): if not script or len(script) < 1: # pylint: disable=line-too-long raise CLIError('Could not read script content from the supplied --script param. It is either empty or an invalid file') @@ -372,11 +297,7 @@ def submit_adla_job(client, return client.create(account_name, job_id, create_params) -def wait_adla_job(client, - account_name, - job_id, - wait_interval_sec=5, - max_wait_time_sec=-1): +def wait_adla_job(client, account_name, job_id, wait_interval_sec=5, max_wait_time_sec=-1): if wait_interval_sec < 1: raise CLIError('wait times must be greater than 0 when polling jobs. Value specified: {}' .format(wait_interval_sec)) @@ -392,6 +313,7 @@ def wait_adla_job(client, job = client.get(account_name, job_id) return job +# endregion # helpers @@ -399,8 +321,8 @@ def _get_uuid_str(): return str(uuid.uuid1()) -def _get_resource_group_location(resource_group_name): +def _get_resource_group_location(cli_ctx, resource_group_name): from azure.mgmt.resource import ResourceManagementClient - client = get_mgmt_service_client(ResourceManagementClient) + client = get_mgmt_service_client(cli_ctx, ResourceManagementClient) # pylint: disable=no-member return client.resource_groups.get(resource_group_name).location diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_account_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_account_mgmt.yaml new file mode 100644 index 00000000000..8eb33ac7e00 --- /dev/null +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_account_mgmt.yaml @@ -0,0 +1,311 @@ +interactions: +- request: + body: '{"tags": {"use": "az-test"}, "location": "westus"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] + Connection: [keep-alive] + Content-Length: ['50'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_mgmt000001?api-version=2017-05-10 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001","name":"cli_test_adla_mgmt000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:56:13 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + status: {code: 201, message: Created} +- request: + body: '{"properties": {"encryptionState": "Disabled"}, "location": "eastus2"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Length: ['70'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"15a35f95-21e0-4b18-be92-d1e4e8a80a59"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/15a35f95-21e0-4b18-be92-d1e4e8a80a590?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['447'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:56:17 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/15a35f95-21e0-4b18-be92-d1e4e8a80a590?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:56:27 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/15a35f95-21e0-4b18-be92-d1e4e8a80a590?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:56:59 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"15a35f95-21e0-4b18-be92-d1e4e8a80a59","creationTime":"2017-12-14T17:56:19.9403302Z","lastModifiedTime":"2017-12-14T17:56:19.9403302Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['821'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:00 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: '{"properties": {"encryptionState": "Disabled"}, "location": "eastus2"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Length: ['70'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"9932aab3-e042-4285-a9e9-0c8028b32730"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000003","name":"cliadls000003","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/9932aab3-e042-4285-a9e9-0c8028b327300?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['447'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:02 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000003/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1198'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/9932aab3-e042-4285-a9e9-0c8028b327300?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:12 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/9932aab3-e042-4285-a9e9-0c8028b327300?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:44 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000003.azuredatalakestore.net","accountId":"9932aab3-e042-4285-a9e9-0c8028b32730","creationTime":"2017-12-14T17:57:03.2724899Z","lastModifiedTime":"2017-12-14T17:57:03.2724899Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000003","name":"cliadls000003","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['821'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:44 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: '{"kind": "Storage", "sku": {"name": "Standard_GRS"}, "location": "eastus2", + "properties": {"supportsHttpsTrafficOnly": false}}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [storage account create] + Connection: [keep-alive] + Content-Length: ['126'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 storagemanagementclient/1.4.0 Azure-SDK-For-Python AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_mgmt000001/providers/Microsoft.Storage/storageAccounts/cliwasb000005?api-version=2017-06-01 + response: + body: {string: ''} + headers: + cache-control: [no-cache] + content-length: ['0'] + date: ['Thu, 14 Dec 2017 17:57:46 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Storage/locations/eastus2/asyncoperations/1f60772b-13d4-4ca7-b2a5-e3b0316a7f8a?monitor=true&api-version=2017-06-01'] + pragma: [no-cache] + server: [Microsoft-Azure-Storage-Resource-Provider/1.0, Microsoft-HTTPAPI/2.0] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + status: {code: 202, message: Accepted} +version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_catalog_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_catalog_mgmt.yaml new file mode 100644 index 00000000000..ddf2e0f792e --- /dev/null +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_catalog_mgmt.yaml @@ -0,0 +1,1352 @@ +interactions: +- request: + body: '{"tags": {"use": "az-test"}, "location": "westus"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] + Connection: [keep-alive] + Content-Length: ['50'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_catalog_mgmt000001?api-version=2017-05-10 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001","name":"cli_test_adla_catalog_mgmt000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:01:23 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1198'] + status: {code: 201, message: Created} +- request: + body: '{"properties": {"encryptionState": "Disabled"}, "location": "eastus2"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Length: ['70'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"c218b35f-0413-4100-af82-67508141c8d1"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/c218b35f-0413-4100-af82-67508141c8d10?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['471'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:01:26 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/c218b35f-0413-4100-af82-67508141c8d10?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:01:36 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/c218b35f-0413-4100-af82-67508141c8d10?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:07 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"c218b35f-0413-4100-af82-67508141c8d1","creationTime":"2017-12-13T23:01:27.7685806Z","lastModifiedTime":"2017-12-13T23:01:27.7685806Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:08 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: 'b''{"properties": {"dataLakeStoreAccounts": [{"name": "cliadls000002"}], + "maxDegreeOfParallelism": 30, "defaultDataLakeStoreAccount": "cliadls000002", + "queryStoreRetention": 30, "maxJobCount": 3}, "location": "eastus2"}''' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Length: ['238'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"defaultDataLakeStoreAccount":"cliadls000002","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls000002"}],"maxDegreeOfParallelism":30,"maxJobCount":3,"queryStoreRetention":30,"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"b860efe4-38b0-41f9-826e-b3861009cd12"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003","name":"cliadla000003","type":"Microsoft.DataLakeAnalytics/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/b860efe4-38b0-41f9-826e-b3861009cd120?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['687'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:11 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/b860efe4-38b0-41f9-826e-b3861009cd120?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:21 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/b860efe4-38b0-41f9-826e-b3861009cd120?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls000002","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls000002"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla000003.azuredatalakeanalytics.net","accountId":"b860efe4-38b0-41f9-826e-b3861009cd12","creationTime":"2017-12-13T23:02:14.5647162Z","lastModifiedTime":"2017-12-13T23:02:14.5647162Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_catalog_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003","name":"cliadla000003","type":"Microsoft.DataLakeAnalytics/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1360'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:02:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: '{"degreeOfParallelism": 1, "properties": {"script": "DROP DATABASE IF EXISTS + catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE TABLE catalog_item_1.dbo.catalog_item_2 + (\n UserId int,\n Start DateTime,\n Region string,\n Query string,\n Duration + int,\n Urls string,\n ClickedUrls string,\n INDEX idx1 CLUSTERED (Region + ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER TABLE catalog_item_1.dbo.catalog_item_2 + ADD IF NOT EXISTS PARTITION (1);\nDROP FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE + FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS @result TABLE (\n s_date + DateTime,\n s_time string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username string,\n c_ip + string,\n cs_useragent string,\n cs_cookie string,\n cs_referer string,\n cs_host + string,\n sc_status int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int) AS\n BEGIN\n @result + = EXTRACT\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery + string,\n s_port int,\n cs_username string,\n c_ip + string,\n cs_useragent string,\n cs_cookie string,\n cs_referer + string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes + int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" USING Extractors.Text(delimiter:'' + '');\n RETURN;\n END;\nCREATE VIEW catalog_item_1.dbo.catalog_item_8 + AS SELECT * FROM (VALUES(1,2),(2,4)) AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() + AS BEGIN CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;", "type": "USql"}, "priority": 1000, "name": "python cli catalog + job", "type": "USql"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job submit] + Connection: [keep-alive] + Content-Length: ['2044'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00Z","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:07 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:03:07.4337492+00:00","details":"Compilation:9b7cfd1c-52d3-4786-9ee8-a876910cf82e;Status:Dispatched"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP + DATABASE IF EXISTS catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE + TABLE catalog_item_1.dbo.catalog_item_2 (\n UserId int,\n Start DateTime,\n Region + string,\n Query string,\n Duration int,\n Urls string,\n ClickedUrls string,\n INDEX + idx1 CLUSTERED (Region ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER + TABLE catalog_item_1.dbo.catalog_item_2 ADD IF NOT EXISTS PARTITION (1);\nDROP + FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS + @result TABLE (\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery string,\n s_port + int,\n cs_username string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes int,\n s_timetaken + int) AS\n BEGIN\n @result = EXTRACT\n s_date DateTime,\n s_time + string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username + string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status + int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" + USING Extractors.Text(delimiter:'' '');\n RETURN;\n END;\nCREATE + VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0.7817662S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:08 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:03:07.4337492+00:00","details":"Compilation:9b7cfd1c-52d3-4786-9ee8-a876910cf82e;Status:Dispatched"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP + DATABASE IF EXISTS catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE + TABLE catalog_item_1.dbo.catalog_item_2 (\n UserId int,\n Start DateTime,\n Region + string,\n Query string,\n Duration int,\n Urls string,\n ClickedUrls string,\n INDEX + idx1 CLUSTERED (Region ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER + TABLE catalog_item_1.dbo.catalog_item_2 ADD IF NOT EXISTS PARTITION (1);\nDROP + FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS + @result TABLE (\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery string,\n s_port + int,\n cs_username string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes int,\n s_timetaken + int) AS\n BEGIN\n @result = EXTRACT\n s_date DateTime,\n s_time + string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username + string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status + int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" + USING Extractors.Text(delimiter:'' '');\n RETURN;\n END;\nCREATE + VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT6.5318551S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:13 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:03:07.4337492+00:00","details":"Compilation:9b7cfd1c-52d3-4786-9ee8-a876910cf82e;Status:Dispatched"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP + DATABASE IF EXISTS catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE + TABLE catalog_item_1.dbo.catalog_item_2 (\n UserId int,\n Start DateTime,\n Region + string,\n Query string,\n Duration int,\n Urls string,\n ClickedUrls string,\n INDEX + idx1 CLUSTERED (Region ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER + TABLE catalog_item_1.dbo.catalog_item_2 ADD IF NOT EXISTS PARTITION (1);\nDROP + FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS + @result TABLE (\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery string,\n s_port + int,\n cs_username string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes int,\n s_timetaken + int) AS\n BEGIN\n @result = EXTRACT\n s_date DateTime,\n s_time + string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username + string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status + int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" + USING Extractors.Text(delimiter:'' '');\n RETURN;\n END;\nCREATE + VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT12.2616616S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:19 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","state":"Starting","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:03:07.4337492+00:00","details":"Compilation:9b7cfd1c-52d3-4786-9ee8-a876910cf82e;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-12-13T23:03:21.1371803+00:00"},{"newState":"Scheduling","timeStamp":"2017-12-13T23:03:21.1371803+00:00","details":"Detail:Dispatching + job to cluster.;rootProcessId:30594a3c-8dc0-469c-938c-ebbef012494c"},{"newState":"Starting","timeStamp":"2017-12-13T23:03:21.1528103+00:00","details":"runtimeVersion:adl_vnext_15a50a63"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_15a50a63","rootProcessNodeId":"30594a3c-8dc0-469c-938c-ebbef012494c","script":"DROP + DATABASE IF EXISTS catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE + TABLE catalog_item_1.dbo.catalog_item_2 (\n UserId int,\n Start DateTime,\n Region + string,\n Query string,\n Duration int,\n Urls string,\n ClickedUrls string,\n INDEX + idx1 CLUSTERED (Region ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER + TABLE catalog_item_1.dbo.catalog_item_2 ADD IF NOT EXISTS PARTITION (1);\nDROP + FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS + @result TABLE (\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery string,\n s_port + int,\n cs_username string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes int,\n s_timetaken + int) AS\n BEGIN\n @result = EXTRACT\n s_date DateTime,\n s_time + string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username + string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status + int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" + USING Extractors.Text(delimiter:'' '');\n RETURN;\n END;\nCREATE + VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","yarnApplicationId":149086,"yarnApplicationTimeStamp":1513125710031,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT13.7034311S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:25 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"python + cli catalog job","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:02:54.5272402+00:00","startTime":"2017-12-13T23:03:26.8248154+00:00","endTime":"2017-12-13T23:03:30.2936127+00:00","state":"Ended","result":"Succeeded","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:02:54.5272402+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:03:07.4337492+00:00","details":"Compilation:9b7cfd1c-52d3-4786-9ee8-a876910cf82e;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-12-13T23:03:21.1371803+00:00"},{"newState":"Scheduling","timeStamp":"2017-12-13T23:03:21.1371803+00:00","details":"Detail:Dispatching + job to cluster.;rootProcessId:30594a3c-8dc0-469c-938c-ebbef012494c"},{"newState":"Starting","timeStamp":"2017-12-13T23:03:21.1528103+00:00","details":"runtimeVersion:adl_vnext_15a50a63"},{"newState":"Running","timeStamp":"2017-12-13T23:03:26.8248154+00:00","details":"runAttempt:1"},{"newState":"Ended","timeStamp":"2017-12-13T23:03:30.2936127+00:00","details":"result:Succeeded"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_15a50a63","rootProcessNodeId":"30594a3c-8dc0-469c-938c-ebbef012494c","script":"DROP + DATABASE IF EXISTS catalog_item_1;\nCREATE DATABASE catalog_item_1;\nCREATE + TABLE catalog_item_1.dbo.catalog_item_2 (\n UserId int,\n Start DateTime,\n Region + string,\n Query string,\n Duration int,\n Urls string,\n ClickedUrls string,\n INDEX + idx1 CLUSTERED (Region ASC)\n PARTITIONED BY (UserId) HASH (Region));\nALTER + TABLE catalog_item_1.dbo.catalog_item_2 ADD IF NOT EXISTS PARTITION (1);\nDROP + FUNCTION IF EXISTS catalog_item_1.dbo.catalog_item_3;\nCREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\n RETURNS + @result TABLE (\n s_date DateTime,\n s_time string,\n s_sitename + string,\n cs_method string,\n cs_uristem string,\n cs_uriquery string,\n s_port + int,\n cs_username string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status int,\n sc_substatus + int,\n sc_win32status int,\n sc_bytes int,\n cs_bytes int,\n s_timetaken + int) AS\n BEGIN\n @result = EXTRACT\n s_date DateTime,\n s_time + string,\n s_sitename string,\n cs_method string,\n cs_uristem + string,\n cs_uriquery string,\n s_port int,\n cs_username + string,\n c_ip string,\n cs_useragent string,\n cs_cookie + string,\n cs_referer string,\n cs_host string,\n sc_status + int,\n sc_substatus int,\n sc_win32status int,\n sc_bytes + int,\n cs_bytes int,\n s_timetaken int FROM \"@/Samples/Data/WebLog.log\" + USING Extractors.Text(delimiter:'' '');\n RETURN;\n END;\nCREATE + VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b);\nCREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) + AS T(a, b); END;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/02/c0244c98-e059-11e7-af0c-a0b3ccf7272a/algebra.xml","yarnApplicationId":149086,"yarnApplicationTimeStamp":1513125710031,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT13.7034311S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT3.4687973S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:29 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog database list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#databases\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"version\":\"5353134c-84c0-4479-8a00-25ebdc033fec\"\ + \r\n },{\r\n \"computeAccountName\":\"cliadla000003\",\"databaseName\"\ + :\"master\",\"version\":\"2709fde6-e345-488f-8630-bd12699174fa\"\r\n }\r\ + \n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:31 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog database show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#databases/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"version\":\"5353134c-84c0-4479-8a00-25ebdc033fec\"\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:31 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog schema list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#schemas\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"version\":\"3bde6cfc-eec4-4ace-9941-f9c39088b88d\"\ + \r\n },{\r\n \"computeAccountName\":\"cliadla000003\",\"databaseName\"\ + :\"catalog_item_1\",\"schemaName\":\"INFORMATION_SCHEMA\",\"version\":\"4edabe16-106d-4976-abb7-8bfcf6398efd\"\ + \r\n },{\r\n \"computeAccountName\":\"cliadla000003\",\"databaseName\"\ + :\"catalog_item_1\",\"schemaName\":\"sys\",\"version\":\"7fb62699-56a8-4913-b2d0-3bacdf69fa87\"\ + \r\n },{\r\n \"computeAccountName\":\"cliadla000003\",\"databaseName\"\ + :\"catalog_item_1\",\"schemaName\":\"usql\",\"version\":\"9fa538cd-df6d-472e-9111-302b23fdd2e9\"\ + \r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:33 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog schema show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#schemas/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"version\":\"3bde6cfc-eec4-4ace-9941-f9c39088b88d\"\ + \r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:33 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog table list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tables?basic=false&api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tables\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tableName\":\"\ + catalog_item_2\",\"columnList\":[\r\n {\r\n \"name\":\"UserId\"\ + ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Start\"\ + ,\"type\":\"System.DateTime\"\r\n },{\r\n \"name\":\"Region\"\ + ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Query\"\ + ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Duration\"\ + ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\",\"\ + type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\"\ + ,\"type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n \ + \ {\r\n \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\ + \n \"name\":\"Region\",\"descending\":false\r\n }\r\ + \n ],\"columns\":[\r\n \"Region\",\"UserId\"\r\n \ + \ ],\"distributionInfo\":{\r\n \"type\":2,\"keys\":[\r\n \ + \ {\r\n \"name\":\"Region\",\"descending\":false\r\ + \n }\r\n ],\"count\":0,\"dynamicCount\":0\r\n \ + \ },\"partitionFunction\":\"91a83845-4477-40f8-979d-24b86821b025\",\"\ + partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ + :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ + :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"\ + version\":\"4332e4e1-731e-46fd-8b1c-20c73fa604d5\"\r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:34 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog table list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/tables?basic=false&api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tables\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tableName\":\"\ + catalog_item_2\",\"columnList\":[\r\n {\r\n \"name\":\"UserId\"\ + ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Start\"\ + ,\"type\":\"System.DateTime\"\r\n },{\r\n \"name\":\"Region\"\ + ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Query\"\ + ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Duration\"\ + ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\",\"\ + type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\"\ + ,\"type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n \ + \ {\r\n \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\ + \n \"name\":\"Region\",\"descending\":false\r\n }\r\ + \n ],\"columns\":[\r\n \"Region\",\"UserId\"\r\n \ + \ ],\"distributionInfo\":{\r\n \"type\":2,\"keys\":[\r\n \ + \ {\r\n \"name\":\"Region\",\"descending\":false\r\ + \n }\r\n ],\"count\":0,\"dynamicCount\":0\r\n \ + \ },\"partitionFunction\":\"91a83845-4477-40f8-979d-24b86821b025\",\"\ + partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ + :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ + :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"\ + version\":\"4332e4e1-731e-46fd-8b1c-20c73fa604d5\"\r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:35 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog table show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tables/catalog_item_2?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tables/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"tableName\":\"catalog_item_2\",\"columnList\":[\r\ + \n {\r\n \"name\":\"UserId\",\"type\":\"System.Int32\"\r\n },{\r\ + \n \"name\":\"Start\",\"type\":\"System.DateTime\"\r\n },{\r\n \ + \ \"name\":\"Region\",\"type\":\"System.String\"\r\n },{\r\n \"\ + name\":\"Query\",\"type\":\"System.String\"\r\n },{\r\n \"name\":\"\ + Duration\",\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\"\ + ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\",\"\ + type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n {\r\n \ + \ \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\n \"name\":\"\ + Region\",\"descending\":false\r\n }\r\n ],\"columns\":[\r\n \ + \ \"Region\",\"UserId\"\r\n ],\"distributionInfo\":{\r\n \ + \ \"type\":2,\"keys\":[\r\n {\r\n \"name\":\"Region\"\ + ,\"descending\":false\r\n }\r\n ],\"count\":0,\"dynamicCount\"\ + :0\r\n },\"partitionFunction\":\"91a83845-4477-40f8-979d-24b86821b025\"\ + ,\"partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ + :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ + :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"version\"\ + :\"4332e4e1-731e-46fd-8b1c-20c73fa604d5\"\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:36 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog view list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/views?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#views\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\"\ + ,\"definition\":\"CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT\ + \ * FROM (VALUES(1,2),(2,4)) AS T(a, b);\",\"version\":\"d23c1ce5-aa22-4d84-8595-88135ec479dd\"\ + \r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:37 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog view list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/views?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#views\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\"\ + ,\"definition\":\"CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT\ + \ * FROM (VALUES(1,2),(2,4)) AS T(a, b);\",\"version\":\"d23c1ce5-aa22-4d84-8595-88135ec479dd\"\ + \r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:38 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog view show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/views/catalog_item_8?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#views/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\",\"definition\":\"\ + CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ + \ AS T(a, b);\",\"version\":\"d23c1ce5-aa22-4d84-8595-88135ec479dd\"\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:38 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog procedure list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#procedures\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\"\ + ,\"definition\":\"CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS\ + \ BEGIN CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ + \ AS T(a, b); END;\",\"version\":\"97901057-e939-4239-84e1-ea502a291fa1\"\r\ + \n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:39 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog procedure show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures/catalog_item_4?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#procedures/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\",\"definition\":\"\ + CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN CREATE VIEW\ + \ catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) AS\ + \ T(a, b); END;\",\"version\":\"97901057-e939-4239-84e1-ea502a291fa1\"\r\n\ + }"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:39 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog procedure list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#procedures\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\"\ + ,\"definition\":\"CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS\ + \ BEGIN CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ + \ AS T(a, b); END;\",\"version\":\"97901057-e939-4239-84e1-ea502a291fa1\"\r\ + \n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:40 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog procedure show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures/catalog_item_4?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#procedures/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\",\"definition\":\"\ + CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN CREATE VIEW\ + \ catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) AS\ + \ T(a, b); END;\",\"version\":\"97901057-e939-4239-84e1-ea502a291fa1\"\r\n\ + }"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:41 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog tvf list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tablevaluedfunctions?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\"\ + ,\"definition\":\"CREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\\n \ + \ RETURNS @result TABLE (\\n s_date DateTime,\\n s_time string,\\n \ + \ s_sitename string,\\n cs_method string,\\n cs_uristem string,\\\ + n cs_uriquery string,\\n s_port int,\\n cs_username string,\\n \ + \ c_ip string,\\n cs_useragent string,\\n cs_cookie string,\\n cs_referer\ + \ string,\\n cs_host string,\\n sc_status int,\\n sc_substatus int,\\\ + n sc_win32status int,\\n sc_bytes int,\\n cs_bytes int,\\n s_timetaken\ + \ int) AS\\n BEGIN\\n @result = EXTRACT\\n s_date DateTime,\\\ + n s_time string,\\n s_sitename string,\\n cs_method\ + \ string,\\n cs_uristem string,\\n cs_uriquery string,\\\ + n s_port int,\\n cs_username string,\\n c_ip string,\\\ + n cs_useragent string,\\n cs_cookie string,\\n \ + \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ + n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ + \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ + \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ + version\":\"b969edad-7fe1-4a7d-9764-3c1db12cb629\"\r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:41 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog tvf list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/tablevaluedfunctions?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions\"\ + ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla000003\",\"\ + databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\"\ + ,\"definition\":\"CREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\\n \ + \ RETURNS @result TABLE (\\n s_date DateTime,\\n s_time string,\\n \ + \ s_sitename string,\\n cs_method string,\\n cs_uristem string,\\\ + n cs_uriquery string,\\n s_port int,\\n cs_username string,\\n \ + \ c_ip string,\\n cs_useragent string,\\n cs_cookie string,\\n cs_referer\ + \ string,\\n cs_host string,\\n sc_status int,\\n sc_substatus int,\\\ + n sc_win32status int,\\n sc_bytes int,\\n cs_bytes int,\\n s_timetaken\ + \ int) AS\\n BEGIN\\n @result = EXTRACT\\n s_date DateTime,\\\ + n s_time string,\\n s_sitename string,\\n cs_method\ + \ string,\\n cs_uristem string,\\n cs_uriquery string,\\\ + n s_port int,\\n cs_username string,\\n c_ip string,\\\ + n cs_useragent string,\\n cs_cookie string,\\n \ + \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ + n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ + \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ + \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ + version\":\"b969edad-7fe1-4a7d-9764-3c1db12cb629\"\r\n }\r\n ]\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:42 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog tvf show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tablevaluedfunctions/catalog_item_3?api-version=2016-11-01 + response: + body: {string: "{\r\n \"@odata.context\":\"https://cliadla000003.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions/$entity\"\ + ,\"computeAccountName\":\"cliadla000003\",\"databaseName\":\"catalog_item_1\"\ + ,\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\",\"definition\":\"CREATE\ + \ FUNCTION catalog_item_1.dbo.catalog_item_3()\\n RETURNS @result TABLE (\\\ + n s_date DateTime,\\n s_time string,\\n s_sitename string,\\n \ + \ cs_method string,\\n cs_uristem string,\\n cs_uriquery string,\\n\ + \ s_port int,\\n cs_username string,\\n c_ip string,\\n cs_useragent\ + \ string,\\n cs_cookie string,\\n cs_referer string,\\n cs_host string,\\\ + n sc_status int,\\n sc_substatus int,\\n sc_win32status int,\\n \ + \ sc_bytes int,\\n cs_bytes int,\\n s_timetaken int) AS\\n BEGIN\\\ + n @result = EXTRACT\\n s_date DateTime,\\n s_time\ + \ string,\\n s_sitename string,\\n cs_method string,\\n\ + \ cs_uristem string,\\n cs_uriquery string,\\n \ + \ s_port int,\\n cs_username string,\\n c_ip string,\\n\ + \ cs_useragent string,\\n cs_cookie string,\\n \ + \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ + n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ + \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ + \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ + version\":\"b969edad-7fe1-4a7d-9764-3c1db12cb629\"\r\n}"} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; odata.metadata=minimal] + date: ['Wed, 13 Dec 2017 23:03:43 GMT'] + expires: ['-1'] + odata-version: ['4.0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: '{"uri": "http://adl.contoso.com:443", "userId": "catalog_item_6", "password": + "catalog_item_7"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog credential create] + Connection: [keep-alive] + Content-Length: ['95'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?api-version=2016-11-01 + response: + body: {string: ''} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + date: ['Wed, 13 Dec 2017 23:03:44 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog credential list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials?api-version=2016-11-01 + response: + body: {string: '{"value":[{"credentialName":"catalog_item_5"}]}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:45 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog credential show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?api-version=2016-11-01 + response: + body: {string: '{"credentialName":"catalog_item_5"}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:46 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog credential delete] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: POST + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?cascade=false&api-version=2016-11-01 + response: + body: {string: ''} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + date: ['Wed, 13 Dec 2017 23:03:47 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla catalog credential list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials?api-version=2016-11-01 + response: + body: {string: '{"value":[]}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:03:47 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group delete] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: DELETE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_catalog_mgmt000001?api-version=2017-05-10 + response: + body: {string: ''} + headers: + cache-control: [no-cache] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 23:03:49 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/operationresults/eyJqb2JJZCI6IlJFU09VUkNFR1JPVVBERUxFVElPTkpPQi1DTEk6NUZURVNUOjVGQURMQTo1RkNBVEFMT0c6NUZNR01UVU1DSDVYSEdMRFBCTXwxMkE1MDQ4QTc5NkEyMTYyLVdFU1RVUyIsImpvYkxvY2F0aW9uIjoid2VzdHVzIn0?api-version=2017-05-10'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1198'] + status: {code: 202, message: Accepted} +version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_job_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_job_mgmt.yaml new file mode 100644 index 00000000000..1f7a68a2399 --- /dev/null +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_adla_job_mgmt.yaml @@ -0,0 +1,740 @@ +interactions: +- request: + body: '{"tags": {"use": "az-test"}, "location": "westus"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] + Connection: [keep-alive] + Content-Length: ['50'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_job_mgmt000001?api-version=2017-05-10 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001","name":"cli_test_adla_job_mgmt000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:15:47 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1197'] + status: {code: 201, message: Created} +- request: + body: '{"location": "eastus2", "properties": {"encryptionState": "Disabled"}}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Length: ['70'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"aceef5be-5634-4d31-8cbe-f42936ece789"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/aceef5be-5634-4d31-8cbe-f42936ece7890?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['471'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:15:50 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1198'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/aceef5be-5634-4d31-8cbe-f42936ece7890?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:01 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/aceef5be-5634-4d31-8cbe-f42936ece7890?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:31 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"aceef5be-5634-4d31-8cbe-f42936ece789","creationTime":"2017-12-13T23:15:52.6247094Z","lastModifiedTime":"2017-12-13T23:15:52.6247094Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:32 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"aceef5be-5634-4d31-8cbe-f42936ece789","creationTime":"2017-12-13T23:15:52.6247094Z","lastModifiedTime":"2017-12-13T23:15:52.6247094Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:33 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: 'b''{"location": "eastus2", "properties": {"dataLakeStoreAccounts": [{"name": + "cliadls000002"}], "defaultDataLakeStoreAccount": "cliadls000002", "maxJobCount": + 3, "maxDegreeOfParallelism": 30, "queryStoreRetention": 30}}''' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Length: ['238'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"defaultDataLakeStoreAccount":"cliadls000002","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls000002"}],"maxDegreeOfParallelism":30,"maxJobCount":3,"queryStoreRetention":30,"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"33bf8b27-8956-48c2-9c7a-e5142f0a7883"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003","name":"cliadla000003","type":"Microsoft.DataLakeAnalytics/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/33bf8b27-8956-48c2-9c7a-e5142f0a78830?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['687'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:35 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1197'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/33bf8b27-8956-48c2-9c7a-e5142f0a78830?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:16:46 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/33bf8b27-8956-48c2-9c7a-e5142f0a78830?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:17:16 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls000002","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls000002"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla000003.azuredatalakeanalytics.net","accountId":"33bf8b27-8956-48c2-9c7a-e5142f0a7883","creationTime":"2017-12-13T23:16:39.0097531Z","lastModifiedTime":"2017-12-13T23:16:39.0097531Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003","name":"cliadla000003","type":"Microsoft.DataLakeAnalytics/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1360'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:17:17 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla account show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls000002","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls000002"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla000003.azuredatalakeanalytics.net","accountId":"33bf8b27-8956-48c2-9c7a-e5142f0a7883","creationTime":"2017-12-13T23:16:39.0097531Z","lastModifiedTime":"2017-12-13T23:16:39.0097531Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adla_job_mgmt000001/providers/Microsoft.DataLakeAnalytics/accounts/cliadla000003","name":"cliadla000003","type":"Microsoft.DataLakeAnalytics/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1360'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 23:17:18 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: '{"type": "USql", "priority": 1000, "degreeOfParallelism": 1, "name": "clijobtest", + "properties": {"type": "USql", "script": "DROP DATABASE IF EXISTS FOO; CREATE + DATABASE FOO;"}}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job submit] + Connection: [keep-alive] + Content-Length: ['177'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:20.5941236+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:20.5941236+00:00","details":"userName:;submitMachine:N/A"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/c44c1b18-e05b-11e7-bcf7-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00Z","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:20 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job cancel] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: POST + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000/CancelJob?api-version=2016-11-01 + response: + body: {string: ''} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + date: ['Wed, 13 Dec 2017 23:17:42 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:20.5941236+00:00","endTime":"2017-12-13T23:17:21.7347371+00:00","state":"Ended","result":"Cancelled","errorMessage":[{"errorId":"I_USER_CJS_CANCELEDBYUSER","name":"CANCELED_BY_USER","severity":"Info","source":"User","component":"CJS","message":"Job + was cancelled.","details":"","description":"Job was cancelled by admin2@AzureSDKTeam.onmicrosoft.com.","resolution":"","helpLink":"","innerError":null}],"stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:20.5941236+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:20.8753701+00:00","details":"Compilation:6601d314-5948-4501-baf4-f00ea71952a2;Status:Dispatched"},{"newState":"Ended","timeStamp":"2017-12-13T23:17:21.7347371+00:00","details":"result:CanceledByUser"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/c44c1b18-e05b-11e7-bcf7-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/c44c1b18-e05b-11e7-bcf7-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP + DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/c44c1b18-e05b-11e7-bcf7-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"UserError","totalCompilationTime":"PT0.859367S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:43 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: '{"type": "USql", "priority": 1000, "degreeOfParallelism": 1, "properties": + {"type": "USql", "script": "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;"}, + "related": {"recurrenceName": "py_recurrence_name", "recurrenceId": "58cab1f7-fe29-46ce-89ab-628a1e09c5bf", + "pipelineName": "py_pipeline_name", "pipelineUri": "https://begoldsm.contoso.com/jobs", + "runId": "a3f300fc-4496-40ad-b76d-7696e3723b77", "pipelineId": "3f9a237a-325e-4ec8-9e10-60222a71354d"}, + "name": "clijobtest"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job submit] + Connection: [keep-alive] + Content-Length: ['477'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00Z","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:44 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:44.5477623+00:00","details":"Compilation:80831893-98f7-4884-95a1-c42bd088cbec;Status:Dispatched"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0.7977744S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:44 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:44.5477623+00:00","details":"Compilation:80831893-98f7-4884-95a1-c42bd088cbec;Status:Dispatched"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT6.3648861S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:50 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","state":"Starting","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:44.5477623+00:00","details":"Compilation:80831893-98f7-4884-95a1-c42bd088cbec;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-12-13T23:17:55.3136366+00:00"},{"newState":"Scheduling","timeStamp":"2017-12-13T23:17:55.3136366+00:00","details":"Detail:Dispatching + job to cluster.;rootProcessId:fc818e0f-82b9-495e-a0d4-7d246d516e5b"},{"newState":"Starting","timeStamp":"2017-12-13T23:17:55.3292313+00:00","details":"runtimeVersion:adl_vnext_15a50a63"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"diagnosticsjson","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/diagnosticsjson","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_15a50a63","rootProcessNodeId":"fc818e0f-82b9-495e-a0d4-7d246d516e5b","script":"DROP + DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","yarnApplicationId":150668,"yarnApplicationTimeStamp":1513125710031,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT10.7658743S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:17:56 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","startTime":"2017-12-13T23:17:59.7356001+00:00","state":"Running","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:44.5477623+00:00","details":"Compilation:80831893-98f7-4884-95a1-c42bd088cbec;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-12-13T23:17:55.3136366+00:00"},{"newState":"Scheduling","timeStamp":"2017-12-13T23:17:55.3136366+00:00","details":"Detail:Dispatching + job to cluster.;rootProcessId:fc818e0f-82b9-495e-a0d4-7d246d516e5b"},{"newState":"Starting","timeStamp":"2017-12-13T23:17:55.3292313+00:00","details":"runtimeVersion:adl_vnext_15a50a63"},{"newState":"Running","timeStamp":"2017-12-13T23:17:59.7356001+00:00","details":"runAttempt:1"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"diagnosticsjson","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/diagnosticsjson","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_15a50a63","rootProcessNodeId":"fc818e0f-82b9-495e-a0d4-7d246d516e5b","script":"DROP + DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","yarnApplicationId":150668,"yarnApplicationTimeStamp":1513125710031,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT10.7658743S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT2.4459822S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:01 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job wait] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000?api-version=2016-11-01 + response: + body: {string: '{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","startTime":"2017-12-13T23:17:59.7356001+00:00","endTime":"2017-12-13T23:18:06.5951253+00:00","state":"Ended","result":"Succeeded","stateAuditRecords":[{"newState":"New","timeStamp":"2017-12-13T23:17:44.3915317+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-12-13T23:17:44.5477623+00:00","details":"Compilation:80831893-98f7-4884-95a1-c42bd088cbec;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-12-13T23:17:55.3136366+00:00"},{"newState":"Scheduling","timeStamp":"2017-12-13T23:17:55.3136366+00:00","details":"Detail:Dispatching + job to cluster.;rootProcessId:fc818e0f-82b9-495e-a0d4-7d246d516e5b"},{"newState":"Starting","timeStamp":"2017-12-13T23:17:55.3292313+00:00","details":"runtimeVersion:adl_vnext_15a50a63"},{"newState":"Running","timeStamp":"2017-12-13T23:17:59.7356001+00:00","details":"runAttempt:1"},{"newState":"Ended","timeStamp":"2017-12-13T23:18:06.5951253+00:00","details":"result:Succeeded"}],"properties":{"owner":"admin2@AzureSDKTeam.onmicrosoft.com","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"diagnosticsjson","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/diagnosticsjson","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_15a50a63","rootProcessNodeId":"fc818e0f-82b9-495e-a0d4-7d246d516e5b","algebraFilePath":"adl://cliadls000002.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/12/13/23/17/d2b7e1dc-e05b-11e7-a8a6-a0b3ccf7272a/algebra.xml","yarnApplicationId":150668,"yarnApplicationTimeStamp":1513125710031,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT10.7658743S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT6.8595252S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:07 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/Jobs?$orderby=submitTime%20desc&api-version=2016-11-01 + response: + body: {string: '{"value":[{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:44.3915317+00:00","startTime":"2017-12-13T23:17:59.7356001+00:00","endTime":"2017-12-13T23:18:06.5951253+00:00","state":"Ended","result":"Succeeded","related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}},{"jobId":"00000000-0000-0000-0000-000000000000","name":"clijobtest","type":"USql","submitter":"admin2@AzureSDKTeam.onmicrosoft.com","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-12-13T23:17:20.5941236+00:00","endTime":"2017-12-13T23:17:21.7347371+00:00","state":"Ended","result":"Cancelled","related":{}}]}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:08 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job recurrence list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/recurrences?api-version=2016-11-01 + response: + body: {string: '{"value":[{"recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.0019054236666666666,"lastSubmitTime":"2017-12-13T23:17:44.3915317+00:00"}],"count":1}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:08 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job recurrence show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/recurrences/58cab1f7-fe29-46ce-89ab-628a1e09c5bf?api-version=2016-11-01 + response: + body: {string: '{"recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.0019054236666666666,"lastSubmitTime":"2017-12-13T23:17:44.3915317+00:00"}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:09 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job pipeline list] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/pipelines?api-version=2016-11-01 + response: + body: {string: '{"value":[{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.0019054236666666666,"lastSubmitTime":"2017-12-13T23:17:44.3915317+00:00"}],"count":1}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:09 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dla job pipeline show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://cliadla000003.azuredatalakeanalytics.net/pipelines/3f9a237a-325e-4ec8-9e10-60222a71354d?api-version=2016-11-01 + response: + body: {string: '{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.0019054236666666666,"lastSubmitTime":"2017-12-13T23:17:44.3915317+00:00","runs":[{"item1":"a3f300fc-4496-40ad-b76d-7696e3723b77","item2":"2017-12-13T23:17:44.3915317+00:00"}],"recurrences":["58cab1f7-fe29-46ce-89ab-628a1e09c5bf"]}'} + headers: + cache-control: ['private, no-cache, no-store, max-age=0'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 23:18:10 GMT'] + expires: ['-1'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group delete] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: DELETE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adla_job_mgmt000001?api-version=2017-05-10 + response: + body: {string: ''} + headers: + cache-control: [no-cache] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 23:18:10 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/operationresults/eyJqb2JJZCI6IlJFU09VUkNFR1JPVVBERUxFVElPTkpPQi1DTEk6NUZURVNUOjVGQURMQTo1RkpPQjo1Rk1HTVRPMlpIR1JMV09aSDNSUkwyUHxCQzZGRDVERjUwNkE3Qzg4LVdFU1RVUyIsImpvYkxvY2F0aW9uIjoid2VzdHVzIn0?api-version=2017-05-10'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + status: {code: 202, message: Accepted} +version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_account_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_account_mgmt.yaml deleted file mode 100644 index b0c82c69b05..00000000000 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_account_mgmt.yaml +++ /dev/null @@ -1,913 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 storagemanagementclient/1.4.0 Azure-SDK-For-Python AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [e2c5b3e2-bf65-11e7-909a-705a0f2f3d93] - method: POST - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.Storage/storageAccounts/cliadlwasb123450/listKeys?api-version=2017-06-01 - response: - body: {string: '{"keys":[{"keyName":"key1","permissions":"Full","value":"Ky7qYiOAxHUVoljo0X3kgTcS7wyO8sO3JDaNzQhvk4fLoy0xXCDSkuOvvM8VyY9SSmA2wdIF6kd4D1pHhP06uw=="},{"keyName":"key2","permissions":"Full","value":"WZcCk4P/D5a+tRGfUM/FM1rQm78W1MfxDWAuohwI9cV/W5j48OnC/lcIHNzqVnlvtFyZjICK4s1WpgjYGZ7hDw=="}]} - - '} - headers: - Cache-Control: [no-cache] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:36:38 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-Azure-Storage-Resource-Provider/1.0, Microsoft-HTTPAPI/2.0] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Transfer-Encoding: [chunked] - Vary: [Accept-Encoding] - content-length: ['289'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: '{"location": "eastus2", "properties": {"defaultDataLakeStoreAccount": "cliadls123450", - "maxDegreeOfParallelism": 30, "queryStoreRetention": 30, "maxJobCount": 3, "dataLakeStoreAccounts": - [{"name": "cliadls123450"}]}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['216'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [e3eec9ee-bf65-11e7-8561-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"defaultDataLakeStoreAccount":"cliadls123450","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls123450"}],"maxDegreeOfParallelism":30,"maxJobCount":3,"queryStoreRetention":30,"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"293b9366-7be6-4122-864e-6d943bbc284a"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Azure-AsyncOperation: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/293b9366-7be6-4122-864e-6d943bbc284a0?api-version=2016-11-01&expanded=true'] - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['592'] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:36:49 GMT'] - Expires: ['-1'] - Location: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/resourcegroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/operationresults/0?api-version=2016-11-01'] - Pragma: [no-cache] - Retry-After: ['10'] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 201, message: Created} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [e3eec9ee-bf65-11e7-8561-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/293b9366-7be6-4122-864e-6d943bbc284a0?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"InProgress"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['23'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [e3eec9ee-bf65-11e7-8561-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/293b9366-7be6-4122-864e-6d943bbc284a0?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"Succeeded"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:33 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['22'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [e3eec9ee-bf65-11e7-8561-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls123450","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls123450"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:36:52.5862431Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:36 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1254'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [0630f3b6-bf66-11e7-ae14-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls123450","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls123450"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:36:52.5862431Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:38 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1254'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [079e36c8-bf66-11e7-bd2b-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:36:52.5862431Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:41 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['528'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [09613f24-bf66-11e7-a790-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/accounts?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"begoldsmdla01.azuredatalakeanalytics.net","accountId":"26aa3b77-01a7-486a-af33-fedb4ced8b8b","creationTime":"2017-04-13T18:27:51.865156Z","lastModifiedTime":"2017-04-13T18:27:51.865156Z"},"location":"eastus2","tags":{},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/begoldsmadlsrg01/providers/Microsoft.DataLakeAnalytics/accounts/begoldsmdla01","name":"begoldsmdla01","type":"Microsoft.DataLakeAnalytics/accounts"},{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:36:52.5862431Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:44 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1045'] - status: {code: 200, message: OK} -- request: - body: '{"properties": {"maxDegreeOfParallelism": 15, "queryStoreRetention": 15, - "maxJobCount": 2, "firewallState": "Enabled", "firewallAllowAzureIps": "Enabled"}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['155'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [0abf7a52-bf66-11e7-80d1-705a0f2f3d93] - method: PATCH - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Enabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls123450","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls123450"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:37:49.5564254Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:47 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1009'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [0c938ac6-bf66-11e7-bdfd-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Enabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls123450","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls123450"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":15,"maxJobCount":2,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":15,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":15,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla123450.azuredatalakeanalytics.net","accountId":"293b9366-7be6-4122-864e-6d943bbc284a","creationTime":"2017-11-02T00:36:52.5862431Z","lastModifiedTime":"2017-11-02T00:37:49.5564254Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450","name":"cliadla123450","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:49 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1252'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [0de50e0a-bf66-11e7-8e4f-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/DataLakeStoreAccounts/cliadls123451?api-version=2016-11-01 - response: - body: {string: '{"properties":{"suffix":"azuredatalakestore.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/dataLakeStoreAccounts/cliadls123451","name":"cliadls123451","type":"Microsoft.DataLakeAnalytics/accounts/dataLakeStoreAccounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:51 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['337'] - x-ms-ratelimit-remaining-subscription-writes: ['1198'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [0f858612-bf66-11e7-8795-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/DataLakeStoreAccounts/cliadls123451?api-version=2016-11-01 - response: - body: {string: '{"properties":{"suffix":"azuredatalakestore.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/dataLakeStoreAccounts/cliadls123451","name":"cliadls123451","type":"Microsoft.DataLakeAnalytics/accounts/dataLakeStoreAccounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:54 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['337'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [10fef302-bf66-11e7-8087-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/DataLakeStoreAccounts/?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"suffix":"azuredatalakestore.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/dataLakeStoreAccounts/cliadls123450","name":"cliadls123450","type":"Microsoft.DataLakeAnalytics/accounts/dataLakeStoreAccounts"},{"properties":{"suffix":"azuredatalakestore.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/dataLakeStoreAccounts/cliadls123451","name":"cliadls123451","type":"Microsoft.DataLakeAnalytics/accounts/dataLakeStoreAccounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:37:57 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['687'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [12d0c81a-bf66-11e7-8fd3-705a0f2f3d93] - method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/DataLakeStoreAccounts/cliadls123451?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 00:38:00 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [14671830-bf66-11e7-a015-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/DataLakeStoreAccounts/?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"suffix":"azuredatalakestore.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/dataLakeStoreAccounts/cliadls123450","name":"cliadls123450","type":"Microsoft.DataLakeAnalytics/accounts/dataLakeStoreAccounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:02 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['349'] - status: {code: 200, message: OK} -- request: - body: '{"properties": {"accessKey": "Ky7qYiOAxHUVoljo0X3kgTcS7wyO8sO3JDaNzQhvk4fLoy0xXCDSkuOvvM8VyY9SSmA2wdIF6kd4D1pHhP06uw=="}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['121'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [15be2512-bf66-11e7-9f42-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/StorageAccounts/cliadlwasb123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"suffix":"core.windows.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/storageAccounts/cliadlwasb123450","name":"cliadlwasb123450","type":"Microsoft.DataLakeAnalytics/accounts/storageAccounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['325'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [17df7728-bf66-11e7-a885-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/StorageAccounts/cliadlwasb123450?api-version=2016-11-01 - response: - body: {string: '{"properties":{"suffix":"core.windows.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/storageAccounts/cliadlwasb123450","name":"cliadlwasb123450","type":"Microsoft.DataLakeAnalytics/accounts/storageAccounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:08 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['325'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [194e74ae-bf66-11e7-8b11-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/StorageAccounts/?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"suffix":"core.windows.net"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/storageAccounts/cliadlwasb123450","name":"cliadlwasb123450","type":"Microsoft.DataLakeAnalytics/accounts/storageAccounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:10 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['337'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [1b066f6c-bf66-11e7-abfb-705a0f2f3d93] - method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/StorageAccounts/cliadlwasb123450?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 00:38:13 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [1c92cb24-bf66-11e7-8755-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/StorageAccounts/?api-version=2016-11-01 - response: - body: {string: '{"value":[]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:17 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['12'] - status: {code: 200, message: OK} -- request: - body: '{"properties": {"objectId": "8ce05900-7a9e-4895-b3f0-0fbcee507803", "objectType": - "User", "maxDegreeOfParallelismPerJob": 2}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['125'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [1ea12046-bf66-11e7-aed1-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy?api-version=2016-11-01 - response: - body: {string: '{"properties":{"objectId":"8ce05900-7a9e-4895-b3f0-0fbcee507803","objectType":"User","maxDegreeOfParallelismPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy","name":"pycliuserpolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:23 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['398'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [22113e9a-bf66-11e7-9c1c-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy?api-version=2016-11-01 - response: - body: {string: '{"properties":{"objectId":"8ce05900-7a9e-4895-b3f0-0fbcee507803","objectType":"User","maxDegreeOfParallelismPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy","name":"pycliuserpolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:25 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['398'] - status: {code: 200, message: OK} -- request: - body: '{"properties": {"objectId": "0583cfd7-60f5-43f0-9597-68b85591fc69", "objectType": - "Group", "maxDegreeOfParallelismPerJob": 2}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['126'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [23889812-bf66-11e7-92d5-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycligrouppolicy?api-version=2016-11-01 - response: - body: {string: '{"properties":{"objectId":"0583cfd7-60f5-43f0-9597-68b85591fc69","objectType":"Group","maxDegreeOfParallelismPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycligrouppolicy","name":"pycligrouppolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:29 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['401'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: '{"properties": {"minPriorityPerJob": 2}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['40'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [25c3af10-bf66-11e7-94f5-705a0f2f3d93] - method: PATCH - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy?api-version=2016-11-01 - response: - body: {string: '{"properties":{"objectId":"8ce05900-7a9e-4895-b3f0-0fbcee507803","objectType":"User","maxDegreeOfParallelismPerJob":2,"minPriorityPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy","name":"pycliuserpolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:32 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['420'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [27b77f5a-bf66-11e7-b58a-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"objectId":"0583cfd7-60f5-43f0-9597-68b85591fc69","objectType":"Group","maxDegreeOfParallelismPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycligrouppolicy","name":"pycligrouppolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"},{"properties":{"objectId":"8ce05900-7a9e-4895-b3f0-0fbcee507803","objectType":"User","maxDegreeOfParallelismPerJob":2,"minPriorityPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy","name":"pycliuserpolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:34 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['834'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [2929c74a-bf66-11e7-8892-705a0f2f3d93] - method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycliuserpolicy?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 00:38:37 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [2aa791a2-bf66-11e7-b1d3-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies?api-version=2016-11-01 - response: - body: {string: '{"value":[{"properties":{"objectId":"0583cfd7-60f5-43f0-9597-68b85591fc69","objectType":"Group","maxDegreeOfParallelismPerJob":2},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450/computePolicies/pycligrouppolicy","name":"pycligrouppolicy","type":"Microsoft.DataLakeAnalytics/accounts/computePolicies"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:38:40 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['413'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [2c077a7a-bf66-11e7-bf5e-705a0f2f3d93] - method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla123450?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 00:38:44 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [2f46ddbe-bf66-11e7-af30-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adla-mgmt/providers/Microsoft.DataLakeAnalytics/accounts?api-version=2016-11-01 - response: - body: {string: '{"value":[]}'} - headers: - Cache-Control: [no-cache] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:38:47 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - content-length: ['12'] - status: {code: 200, message: OK} -version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_catalog_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_catalog_mgmt.yaml deleted file mode 100644 index 5531654aa09..00000000000 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_catalog_mgmt.yaml +++ /dev/null @@ -1,745 +0,0 @@ -interactions: -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [20da8a06-55e5-11e7-b506-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#databases\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"version\":\"27d201fa-e059-42fe-8d11-bf30564c9f23\"\ - \r\n },{\r\n \"computeAccountName\":\"cliadla123442\",\"databaseName\"\ - :\"master\",\"version\":\"c2989402-963b-462c-bbb3-77577bc8519e\"\r\n }\r\ - \n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:24 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [212405b4-55e5-11e7-971b-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#databases/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"version\":\"27d201fa-e059-42fe-8d11-bf30564c9f23\"\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:24 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [217163ae-55e5-11e7-9390-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#schemas\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"version\":\"edd7c612-edee-4044-9ede-a7c27c5c53f5\"\ - \r\n },{\r\n \"computeAccountName\":\"cliadla123442\",\"databaseName\"\ - :\"catalog_item_1\",\"schemaName\":\"INFORMATION_SCHEMA\",\"version\":\"a74ce693-14b0-43be-83e8-df383921b28e\"\ - \r\n },{\r\n \"computeAccountName\":\"cliadla123442\",\"databaseName\"\ - :\"catalog_item_1\",\"schemaName\":\"sys\",\"version\":\"1ffd2659-293a-4dd8-8f7b-aaf59e7fcfac\"\ - \r\n },{\r\n \"computeAccountName\":\"cliadla123442\",\"databaseName\"\ - :\"catalog_item_1\",\"schemaName\":\"usql\",\"version\":\"1a596188-2cd0-4704-b56e-1ff92ba8a9b4\"\ - \r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:25 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [21baf268-55e5-11e7-94db-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#schemas/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"version\":\"edd7c612-edee-4044-9ede-a7c27c5c53f5\"\ - \r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:25 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [2205a668-55e5-11e7-9442-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tables?basic=false&api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tables\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tableName\":\"\ - catalog_item_2\",\"columnList\":[\r\n {\r\n \"name\":\"UserId\"\ - ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Start\"\ - ,\"type\":\"System.DateTime\"\r\n },{\r\n \"name\":\"Region\"\ - ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Query\"\ - ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Duration\"\ - ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\",\"\ - type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\"\ - ,\"type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n \ - \ {\r\n \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\ - \n \"name\":\"Region\",\"descending\":false\r\n }\r\ - \n ],\"columns\":[\r\n \"Region\",\"UserId\"\r\n \ - \ ],\"distributionInfo\":{\r\n \"type\":2,\"keys\":[\r\n \ - \ {\r\n \"name\":\"Region\",\"descending\":false\r\ - \n }\r\n ],\"count\":0,\"dynamicCount\":0\r\n \ - \ },\"partitionFunction\":\"c93a1507-c009-4b99-a8e1-135242ec7a31\",\"\ - partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ - :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ - :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"\ - version\":\"67fd7958-c474-4a08-a58d-8d1ed3316eaa\"\r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:26 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [2252200a-55e5-11e7-9fce-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/tables?basic=false&api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tables\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tableName\":\"\ - catalog_item_2\",\"columnList\":[\r\n {\r\n \"name\":\"UserId\"\ - ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Start\"\ - ,\"type\":\"System.DateTime\"\r\n },{\r\n \"name\":\"Region\"\ - ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Query\"\ - ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"Duration\"\ - ,\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\",\"\ - type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\"\ - ,\"type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n \ - \ {\r\n \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\ - \n \"name\":\"Region\",\"descending\":false\r\n }\r\ - \n ],\"columns\":[\r\n \"Region\",\"UserId\"\r\n \ - \ ],\"distributionInfo\":{\r\n \"type\":2,\"keys\":[\r\n \ - \ {\r\n \"name\":\"Region\",\"descending\":false\r\ - \n }\r\n ],\"count\":0,\"dynamicCount\":0\r\n \ - \ },\"partitionFunction\":\"c93a1507-c009-4b99-a8e1-135242ec7a31\",\"\ - partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ - :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ - :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"\ - version\":\"67fd7958-c474-4a08-a58d-8d1ed3316eaa\"\r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:26 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [22a6e018-55e5-11e7-bd80-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tables/catalog_item_2?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tables/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"tableName\":\"catalog_item_2\",\"columnList\":[\r\ - \n {\r\n \"name\":\"UserId\",\"type\":\"System.Int32\"\r\n },{\r\ - \n \"name\":\"Start\",\"type\":\"System.DateTime\"\r\n },{\r\n \ - \ \"name\":\"Region\",\"type\":\"System.String\"\r\n },{\r\n \"\ - name\":\"Query\",\"type\":\"System.String\"\r\n },{\r\n \"name\":\"\ - Duration\",\"type\":\"System.Int32\"\r\n },{\r\n \"name\":\"Urls\"\ - ,\"type\":\"System.String\"\r\n },{\r\n \"name\":\"ClickedUrls\",\"\ - type\":\"System.String\"\r\n }\r\n ],\"indexList\":[\r\n {\r\n \ - \ \"name\":\"idx1\",\"indexKeys\":[\r\n {\r\n \"name\":\"\ - Region\",\"descending\":false\r\n }\r\n ],\"columns\":[\r\n \ - \ \"Region\",\"UserId\"\r\n ],\"distributionInfo\":{\r\n \ - \ \"type\":2,\"keys\":[\r\n {\r\n \"name\":\"Region\"\ - ,\"descending\":false\r\n }\r\n ],\"count\":0,\"dynamicCount\"\ - :0\r\n },\"partitionFunction\":\"c93a1507-c009-4b99-a8e1-135242ec7a31\"\ - ,\"partitionKeyList\":[\r\n \"UserId\"\r\n ],\"isColumnstore\"\ - :false,\"indexId\":1,\"isUnique\":false\r\n }\r\n ],\"partitionKeyList\"\ - :[\r\n \r\n ],\"externalTable\":null,\"distributionInfo\":null,\"version\"\ - :\"67fd7958-c474-4a08-a58d-8d1ed3316eaa\"\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:27 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [22f5f26e-55e5-11e7-9096-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/views?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#views\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\"\ - ,\"definition\":\"CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT\ - \ * FROM (VALUES(1,2),(2,4)) AS T(a, b);\",\"version\":\"636fca7d-5c83-46fe-9f09-3f297585dcf9\"\ - \r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:28 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [2341d3ae-55e5-11e7-9878-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/views?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#views\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\"\ - ,\"definition\":\"CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT\ - \ * FROM (VALUES(1,2),(2,4)) AS T(a, b);\",\"version\":\"636fca7d-5c83-46fe-9f09-3f297585dcf9\"\ - \r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:28 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [238ded1c-55e5-11e7-9a88-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/views/catalog_item_8?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#views/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"viewName\":\"catalog_item_8\",\"definition\":\"\ - CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ - \ AS T(a, b);\",\"version\":\"636fca7d-5c83-46fe-9f09-3f297585dcf9\"\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:29 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [23db0a94-55e5-11e7-bd63-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#procedures\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\"\ - ,\"definition\":\"CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS\ - \ BEGIN CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ - \ AS T(a, b); END;\",\"version\":\"61122348-4f6f-4fd4-9671-3fad6919d2d3\"\r\ - \n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:28 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [242681ca-55e5-11e7-9081-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures/catalog_item_4?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#procedures/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\",\"definition\":\"\ - CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN CREATE VIEW\ - \ catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) AS\ - \ T(a, b); END;\",\"version\":\"61122348-4f6f-4fd4-9671-3fad6919d2d3\"\r\n\ - }"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:30 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [2473e5fe-55e5-11e7-8fee-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#procedures\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\"\ - ,\"definition\":\"CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS\ - \ BEGIN CREATE VIEW catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4))\ - \ AS T(a, b); END;\",\"version\":\"61122348-4f6f-4fd4-9671-3fad6919d2d3\"\r\ - \n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:30 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [24c09c34-55e5-11e7-bb40-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/procedures/catalog_item_4?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#procedures/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"procName\":\"catalog_item_4\",\"definition\":\"\ - CREATE PROCEDURE catalog_item_1.dbo.catalog_item_4() AS BEGIN CREATE VIEW\ - \ catalog_item_1.dbo.catalog_item_8 AS SELECT * FROM (VALUES(1,2),(2,4)) AS\ - \ T(a, b); END;\",\"version\":\"61122348-4f6f-4fd4-9671-3fad6919d2d3\"\r\n\ - }"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:31 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [25115fb0-55e5-11e7-ad45-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tablevaluedfunctions?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\"\ - ,\"definition\":\"CREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\\n \ - \ RETURNS @result TABLE (\\n s_date DateTime,\\n s_time string,\\n \ - \ s_sitename string,\\n cs_method string,\\n cs_uristem string,\\\ - n cs_uriquery string,\\n s_port int,\\n cs_username string,\\n \ - \ c_ip string,\\n cs_useragent string,\\n cs_cookie string,\\n cs_referer\ - \ string,\\n cs_host string,\\n sc_status int,\\n sc_substatus int,\\\ - n sc_win32status int,\\n sc_bytes int,\\n cs_bytes int,\\n s_timetaken\ - \ int) AS\\n BEGIN\\n @result = EXTRACT\\n s_date DateTime,\\\ - n s_time string,\\n s_sitename string,\\n cs_method\ - \ string,\\n cs_uristem string,\\n cs_uriquery string,\\\ - n s_port int,\\n cs_username string,\\n c_ip string,\\\ - n cs_useragent string,\\n cs_cookie string,\\n \ - \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ - n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ - \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ - \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ - version\":\"86da5acf-d33d-4b17-9028-0cf0a0a3d732\"\r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:31 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [255a24ac-55e5-11e7-bc57-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/tablevaluedfunctions?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions\"\ - ,\"value\":[\r\n {\r\n \"computeAccountName\":\"cliadla123442\",\"\ - databaseName\":\"catalog_item_1\",\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\"\ - ,\"definition\":\"CREATE FUNCTION catalog_item_1.dbo.catalog_item_3()\\n \ - \ RETURNS @result TABLE (\\n s_date DateTime,\\n s_time string,\\n \ - \ s_sitename string,\\n cs_method string,\\n cs_uristem string,\\\ - n cs_uriquery string,\\n s_port int,\\n cs_username string,\\n \ - \ c_ip string,\\n cs_useragent string,\\n cs_cookie string,\\n cs_referer\ - \ string,\\n cs_host string,\\n sc_status int,\\n sc_substatus int,\\\ - n sc_win32status int,\\n sc_bytes int,\\n cs_bytes int,\\n s_timetaken\ - \ int) AS\\n BEGIN\\n @result = EXTRACT\\n s_date DateTime,\\\ - n s_time string,\\n s_sitename string,\\n cs_method\ - \ string,\\n cs_uristem string,\\n cs_uriquery string,\\\ - n s_port int,\\n cs_username string,\\n c_ip string,\\\ - n cs_useragent string,\\n cs_cookie string,\\n \ - \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ - n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ - \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ - \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ - version\":\"86da5acf-d33d-4b17-9028-0cf0a0a3d732\"\r\n }\r\n ]\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:32 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [25ada6fa-55e5-11e7-b0a6-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/schemas/dbo/tablevaluedfunctions/catalog_item_3?api-version=2016-11-01 - response: - body: {string: "{\r\n \"@odata.context\":\"https://cliadla123442.azuredatalakeanalytics.net/sqlip/$metadata#tablevaluedfunctions/$entity\"\ - ,\"computeAccountName\":\"cliadla123442\",\"databaseName\":\"catalog_item_1\"\ - ,\"schemaName\":\"dbo\",\"tvfName\":\"catalog_item_3\",\"definition\":\"CREATE\ - \ FUNCTION catalog_item_1.dbo.catalog_item_3()\\n RETURNS @result TABLE (\\\ - n s_date DateTime,\\n s_time string,\\n s_sitename string,\\n \ - \ cs_method string,\\n cs_uristem string,\\n cs_uriquery string,\\n\ - \ s_port int,\\n cs_username string,\\n c_ip string,\\n cs_useragent\ - \ string,\\n cs_cookie string,\\n cs_referer string,\\n cs_host string,\\\ - n sc_status int,\\n sc_substatus int,\\n sc_win32status int,\\n \ - \ sc_bytes int,\\n cs_bytes int,\\n s_timetaken int) AS\\n BEGIN\\\ - n @result = EXTRACT\\n s_date DateTime,\\n s_time\ - \ string,\\n s_sitename string,\\n cs_method string,\\n\ - \ cs_uristem string,\\n cs_uriquery string,\\n \ - \ s_port int,\\n cs_username string,\\n c_ip string,\\n\ - \ cs_useragent string,\\n cs_cookie string,\\n \ - \ cs_referer string,\\n cs_host string,\\n sc_status int,\\\ - n sc_substatus int,\\n sc_win32status int,\\n sc_bytes\ - \ int,\\n cs_bytes int,\\n s_timetaken int FROM \\\"@/Samples/Data/WebLog.log\\\ - \" USING Extractors.Text(delimiter:' ');\\n RETURN;\\n END;\",\"\ - version\":\"86da5acf-d33d-4b17-9028-0cf0a0a3d732\"\r\n}"} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; odata.metadata=minimal] - Date: ['Tue, 20 Jun 2017 18:20:32 GMT'] - Expires: ['-1'] - OData-Version: ['4.0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: '{"password": "catalog_item_7", "uri": "http://adl.contoso.com:443", "userId": - "catalog_item_6"}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['95'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [25f7ec42-55e5-11e7-8e07-645106422854] - method: PUT - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Date: ['Tue, 20 Jun 2017 18:20:34 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [26f3b84c-55e5-11e7-8c88-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials?api-version=2016-11-01 - response: - body: {string: '{"value":[{"credentialName":"catalog_item_5"}]}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:20:34 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [274b49d8-55e5-11e7-976d-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?api-version=2016-11-01 - response: - body: {string: '{"credentialName":"catalog_item_5"}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:20:35 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [27a0bc70-55e5-11e7-a41f-645106422854] - method: POST - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials/catalog_item_5?cascade=false&api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Date: ['Tue, 20 Jun 2017 18:20:36 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) requests/2.9.1 msrest/0.4.10 - msrest_azure/0.4.9 datalakeanalyticscatalogmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.9+dev] - accept-language: [en-US] - x-ms-client-request-id: [2813e818-55e5-11e7-b99f-645106422854] - method: GET - uri: https://cliadla123442.azuredatalakeanalytics.net/catalog/usql/databases/catalog_item_1/credentials?api-version=2016-11-01 - response: - body: {string: '{"value":[]}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:20:36 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_job_mgmt.yaml b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_job_mgmt.yaml deleted file mode 100644 index 2e1c19b1754..00000000000 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/recordings/latest/test_dla_job_mgmt.yaml +++ /dev/null @@ -1,663 +0,0 @@ -interactions: -- request: - body: '{"location": "eastus2", "properties": {"encryptionState": "Disabled"}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['70'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [3dc27636-bf64-11e7-a2a6-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"7c7ed8cc-1eee-4b5f-add8-2729bbb22f12"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533","name":"cliadls1234533","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Azure-AsyncOperation: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/7c7ed8cc-1eee-4b5f-add8-2729bbb22f120?api-version=2016-11-01&expanded=true'] - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['400'] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:24:54 GMT'] - Expires: ['-1'] - Location: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/resourcegroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533/operationresults/0?api-version=2016-11-01'] - Pragma: [no-cache] - Retry-After: ['10'] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 201, message: Created} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [3dc27636-bf64-11e7-a2a6-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/7c7ed8cc-1eee-4b5f-add8-2729bbb22f120?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"InProgress"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:25:07 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['23'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [3dc27636-bf64-11e7-a2a6-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/7c7ed8cc-1eee-4b5f-add8-2729bbb22f120?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"Succeeded"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:25:40 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['22'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [3dc27636-bf64-11e7-a2a6-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234533.azuredatalakestore.net","accountId":"7c7ed8cc-1eee-4b5f-add8-2729bbb22f12","creationTime":"2017-11-02T00:24:56.6316918Z","lastModifiedTime":"2017-11-02T00:24:56.6316918Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533","name":"cliadls1234533","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:25:41 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['776'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [5c955b80-bf64-11e7-b907-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234533.azuredatalakestore.net","accountId":"7c7ed8cc-1eee-4b5f-add8-2729bbb22f12","creationTime":"2017-11-02T00:24:56.6316918Z","lastModifiedTime":"2017-11-02T00:24:56.6316918Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234533","name":"cliadls1234533","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:25:44 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['776'] - status: {code: 200, message: OK} -- request: - body: '{"location": "eastus2", "properties": {"defaultDataLakeStoreAccount": "cliadls1234533", - "maxDegreeOfParallelism": 30, "queryStoreRetention": 30, "maxJobCount": 3, "dataLakeStoreAccounts": - [{"name": "cliadls1234533"}]}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['218'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [5d9e5f7a-bf64-11e7-8942-705a0f2f3d93] - method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"defaultDataLakeStoreAccount":"cliadls1234533","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls1234533"}],"maxDegreeOfParallelism":30,"maxJobCount":3,"queryStoreRetention":30,"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"166e1cc6-1df9-4e70-8314-3524cd324711"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533","name":"cliadla1234533","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Azure-AsyncOperation: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/166e1cc6-1df9-4e70-8314-3524cd3247110?api-version=2016-11-01&expanded=true'] - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['596'] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:25:48 GMT'] - Expires: ['-1'] - Location: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/resourcegroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533/operationresults/0?api-version=2016-11-01'] - Pragma: [no-cache] - Retry-After: ['10'] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] - status: {code: 201, message: Created} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [5d9e5f7a-bf64-11e7-8942-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/166e1cc6-1df9-4e70-8314-3524cd3247110?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"InProgress"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:26:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['23'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [5d9e5f7a-bf64-11e7-8942-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeAnalytics/locations/eastus2/operationResults/166e1cc6-1df9-4e70-8314-3524cd3247110?api-version=2016-11-01&expanded=true - response: - body: {string: '{"status":"Succeeded"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:26:32 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['22'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [5d9e5f7a-bf64-11e7-8942-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls1234533","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls1234533"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla1234533.azuredatalakeanalytics.net","accountId":"166e1cc6-1df9-4e70-8314-3524cd324711","creationTime":"2017-11-02T00:25:53.7139872Z","lastModifiedTime":"2017-11-02T00:25:53.7139872Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533","name":"cliadla1234533","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:26:33 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1259'] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsaccountmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [7b8d5d7e-bf64-11e7-bf32-705a0f2f3d93] - method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533?api-version=2016-11-01 - response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","debugDataAccessLevel":"All","firewallRules":[],"defaultDataLakeStoreAccount":"cliadls1234533","dataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"cliadls1234533"}],"publicDataLakeStoreAccounts":[{"properties":{"suffix":"azuredatalakestore.net"},"name":"adltrainingsampledata"},{"properties":{"suffix":"azuredatalakestore.net"},"name":"ghinsights"}],"storageAccounts":[],"maxDegreeOfParallelism":30,"maxJobCount":3,"systemMaxDegreeOfParallelism":100,"systemMaxJobCount":20,"maxDegreeOfParallelismPerJob":30,"minPriorityPerJob":1,"computePolicies":[],"queryStoreRetention":30,"hiveMetastores":[],"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadla1234533.azuredatalakeanalytics.net","accountId":"166e1cc6-1df9-4e70-8314-3524cd324711","creationTime":"2017-11-02T00:25:53.7139872Z","lastModifiedTime":"2017-11-02T00:25:53.7139872Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/test-adla-job-mgmt/providers/Microsoft.DataLakeAnalytics/accounts/cliadla1234533","name":"cliadla1234533","type":"Microsoft.DataLakeAnalytics/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 00:26:36 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1259'] - status: {code: 200, message: OK} -- request: - body: '{"type": "USql", "properties": {"script": "DROP DATABASE IF EXISTS FOO; - CREATE DATABASE FOO;", "type": "USql"}, "name": "clijobtest", "degreeOfParallelism": - 1, "priority": 1000}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['177'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [7c97331d-bf64-11e7-abcc-705a0f2f3d93] - method: PUT - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"7c97331c-bf64-11e7-bd99-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:38.8713126+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:38.8713126+00:00","details":"userName:;submitMachine:N/A"}],"properties":{"owner":"AdlSdkTestApp01@SPI","runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/7c97331c-bf64-11e7-bd99-705a0f2f3d93/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00Z","type":"USql"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:38 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [7e3744f4-bf64-11e7-a4df-705a0f2f3d93] - method: POST - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000/CancelJob?api-version=2016-11-01 - response: - body: {string: ''} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Date: ['Thu, 02 Nov 2017 00:26:41 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [7f8acc74-bf64-11e7-bc17-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"7c97331c-bf64-11e7-bd99-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:38.8713126+00:00","endTime":"2017-11-02T00:26:41.1213601+00:00","state":"Ended","result":"Cancelled","errorMessage":[{"errorId":"I_USER_CJS_CANCELEDBYUSER","name":"CANCELED_BY_USER","severity":"Info","source":"User","component":"CJS","message":"Job - was cancelled.","details":"","description":"Job was cancelled by AdlSdkTestApp01@SPI.","resolution":"","helpLink":"","innerError":null}],"stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:38.8713126+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-11-02T00:26:39.261947+00:00","details":"CcsAttempts:1;Status:Dispatched"},{"newState":"Ended","timeStamp":"2017-11-02T00:26:41.1213601+00:00","details":"result:CanceledByUser"}],"properties":{"owner":"AdlSdkTestApp01@SPI","resources":[{"name":"Profile","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/7c97331c-bf64-11e7-bd99-705a0f2f3d93/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/7c97331c-bf64-11e7-bd99-705a0f2f3d93/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/7c97331c-bf64-11e7-bd99-705a0f2f3d93/algebra.xml","compileMode":"Semantic","errorSource":"UserError","totalCompilationTime":"PT1.8594131S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:43 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: '{"type": "USql", "properties": {"script": "DROP DATABASE IF EXISTS FOO; - CREATE DATABASE FOO;", "type": "USql"}, "name": "clijobtest", "degreeOfParallelism": - 1, "priority": 1000, "related": {"pipelineId": "3f9a237a-325e-4ec8-9e10-60222a71354d", - "pipelineName": "py_pipeline_name", "pipelineUri": "https://begoldsm.contoso.com/jobs", - "runId": "a3f300fc-4496-40ad-b76d-7696e3723b77", "recurrenceId": "58cab1f7-fe29-46ce-89ab-628a1e09c5bf", - "recurrenceName": "py_recurrence_name"}}' - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['477'] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [80b8f2f0-bf64-11e7-a566-705a0f2f3d93] - method: PUT - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:45.1839581+00:00","details":"userName:;submitMachine:N/A"}],"properties":{"owner":"AdlSdkTestApp01@SPI","runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT0S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00Z","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:44 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [81dcd3dc-bf64-11e7-b672-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:45.1839581+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-11-02T00:26:45.3558431+00:00","details":"CcsAttempts:1;Status:Dispatched"}],"properties":{"owner":"AdlSdkTestApp01@SPI","resources":[{"name":"Profile","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP - DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT1.5817323S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:46 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [85d62e5c-bf64-11e7-8b45-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","state":"Compiling","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:45.1839581+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-11-02T00:26:45.3558431+00:00","details":"CcsAttempts:1;Status:Dispatched"}],"properties":{"owner":"AdlSdkTestApp01@SPI","resources":[{"name":"Profile","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"default","rootProcessNodeId":"00000000-0000-0000-0000-000000000000","script":"DROP - DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/algebra.xml","compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT8.3943433S","totalPausedTime":"PT0S","totalQueuedTime":"PT0S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:53 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [89db97b0-bf64-11e7-8626-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","state":"Starting","result":"None","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:45.1839581+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-11-02T00:26:45.3558431+00:00","details":"CcsAttempts:1;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-11-02T00:26:55.9498412+00:00"},{"newState":"Scheduling","timeStamp":"2017-11-02T00:26:55.9654413+00:00","details":"Detail:Dispatching - job to cluster.;rootProcessId:eba5c133-e680-4a64-b3e3-3d141ef782aa"},{"newState":"Starting","timeStamp":"2017-11-02T00:26:55.9654413+00:00","details":"runtimeVersion:adl_vnext_c11cf298"}],"properties":{"owner":"AdlSdkTestApp01@SPI","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"__AST.json","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__AST.json","type":"StatisticsResource"},{"name":"diagnosticsjson","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/diagnosticsjson","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_c11cf298","rootProcessNodeId":"eba5c133-e680-4a64-b3e3-3d141ef782aa","script":"DROP - DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/algebra.xml","yarnApplicationId":1010543,"yarnApplicationTimeStamp":1509030107786,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT10.5939981S","totalPausedTime":"PT0S","totalQueuedTime":"PT0.0156001S","totalRunningTime":"PT0S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:26:59 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [8e1f72e4-bf64-11e7-bbd2-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs/00000000-0000-0000-0000-000000000000 - response: - body: {string: '{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","startTime":"2017-11-02T00:27:01.9656008+00:00","endTime":"2017-11-02T00:27:05.4500359+00:00","state":"Ended","result":"Succeeded","stateAuditRecords":[{"newState":"New","timeStamp":"2017-11-02T00:26:45.1839581+00:00","details":"userName:;submitMachine:N/A"},{"newState":"Compiling","timeStamp":"2017-11-02T00:26:45.3558431+00:00","details":"CcsAttempts:1;Status:Dispatched"},{"newState":"Queued","timeStamp":"2017-11-02T00:26:55.9498412+00:00"},{"newState":"Scheduling","timeStamp":"2017-11-02T00:26:55.9654413+00:00","details":"Detail:Dispatching - job to cluster.;rootProcessId:eba5c133-e680-4a64-b3e3-3d141ef782aa"},{"newState":"Starting","timeStamp":"2017-11-02T00:26:55.9654413+00:00","details":"runtimeVersion:adl_vnext_c11cf298"},{"newState":"Running","timeStamp":"2017-11-02T00:27:01.9656008+00:00","details":"runAttempt:1"},{"newState":"Ended","timeStamp":"2017-11-02T00:27:05.4500359+00:00","details":"result:Succeeded"}],"properties":{"owner":"AdlSdkTestApp01@SPI","resources":[{"name":"__ScopeCodeGen__.dll","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.dll","type":"VertexResource"},{"name":"__ScopeCodeGen__.pdb","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.pdb","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.dll","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.dll","type":"VertexResource"},{"name":"__ScopeCodeGenEngine__.pdb","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.pdb","type":"VertexResource"},{"name":"PartitionLastRows.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/PartitionLastRows.xml","type":"VertexResource"},{"name":"ScopeVertexDef.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/ScopeVertexDef.xml","type":"VertexResource"},{"name":"__ScopeCodeGen__.dll.cs","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGen__.dll.cs","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.dll.cpp","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.dll.cpp","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOutput__.txt","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenCompileOutput__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenCompileOptions__.txt","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenCompileOptions__.txt","type":"StatisticsResource"},{"name":"__ScopeCodeGenEngine__.cppresources","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeCodeGenEngine__.cppresources","type":"StatisticsResource"},{"name":"query.abr","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/query.abr","type":"StatisticsResource"},{"name":"__ScopeDiagnosisInfo__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeDiagnosisInfo__.xml","type":"StatisticsResource"},{"name":"__SystemInternalInfo__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__SystemInternalInfo__.xml","type":"StatisticsResource"},{"name":"__AST.json","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__AST.json","type":"StatisticsResource"},{"name":"diagnosticsjson","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/diagnosticsjson","type":"StatisticsResource"},{"name":"Profile","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/profile","type":"StatisticsResource"},{"name":"__ScopeRuntimeStatistics__.xml","resourcePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/__ScopeRuntimeStatistics__.xml","type":"StatisticsResource"}],"runtimeVersion":"adl_vnext_c11cf298","rootProcessNodeId":"eba5c133-e680-4a64-b3e3-3d141ef782aa","script":"DROP - DATABASE IF EXISTS FOO; CREATE DATABASE FOO;","algebraFilePath":"adl://cliadls1234533.azuredatalakestore.net/system/jobservice/jobs/Usql/2017/11/02/00/26/80b8df74-bf64-11e7-a879-705a0f2f3d93/algebra.xml","yarnApplicationId":1010543,"yarnApplicationTimeStamp":1509030107786,"compileMode":"Semantic","errorSource":"Unknown","totalCompilationTime":"PT10.5939981S","totalPausedTime":"PT0S","totalQueuedTime":"PT0.0156001S","totalRunningTime":"PT3.4844351S","expirationTimeUtc":"0001-01-01T00:00:00","type":"USql"},"related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:07 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [8f790ad2-bf64-11e7-984c-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/Jobs?$orderby=submitTime%20desc&api-version=2016-11-01 - response: - body: {string: '{"value":[{"jobId":"80b8df74-bf64-11e7-a879-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:45.1839581+00:00","startTime":"2017-11-02T00:27:01.9656008+00:00","endTime":"2017-11-02T00:27:05.4500359+00:00","state":"Ended","result":"Succeeded","related":{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","runId":"a3f300fc-4496-40ad-b76d-7696e3723b77","recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name"}},{"jobId":"7c97331c-bf64-11e7-bd99-705a0f2f3d93","name":"clijobtest","type":"USql","submitter":"AdlSdkTestApp01@SPI","degreeOfParallelism":1,"priority":1000,"submitTime":"2017-11-02T00:26:38.8713126+00:00","endTime":"2017-11-02T00:26:41.1213601+00:00","state":"Ended","result":"Cancelled","related":{}}]}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:09 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [90979606-bf64-11e7-be64-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/recurrences?api-version=2016-11-01 - response: - body: {string: '{"value":[{"recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.00096789863888888886,"lastSubmitTime":"2017-11-02T00:26:45.1839581+00:00"}],"count":1}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:11 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [919db912-bf64-11e7-aaa9-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/recurrences/58cab1f7-fe29-46ce-89ab-628a1e09c5bf?api-version=2016-11-01 - response: - body: {string: '{"recurrenceId":"58cab1f7-fe29-46ce-89ab-628a1e09c5bf","recurrenceName":"py_recurrence_name","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.00096789863888888886,"lastSubmitTime":"2017-11-02T00:26:45.1839581+00:00"}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:13 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [92a2879c-bf64-11e7-a9e4-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/pipelines?api-version=2016-11-01 - response: - body: {string: '{"value":[{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.00096789863888888886,"lastSubmitTime":"2017-11-02T00:26:45.1839581+00:00"}],"count":1}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:15 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: [application/json] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakeanalyticsjobmanagementclient/0.1.6 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] - accept-language: [en-US] - x-ms-client-request-id: [93afb798-bf64-11e7-9b31-705a0f2f3d93] - method: GET - uri: https://cliadla1234533.azuredatalakeanalytics.net/pipelines/3f9a237a-325e-4ec8-9e10-60222a71354d?api-version=2016-11-01 - response: - body: {string: '{"pipelineId":"3f9a237a-325e-4ec8-9e10-60222a71354d","pipelineName":"py_pipeline_name","pipelineUri":"https://begoldsm.contoso.com/jobs","numJobsFailed":0,"numJobsCanceled":0,"numJobsSucceeded":1,"auHoursFailed":0.0,"auHoursCanceled":0.0,"auHoursSucceeded":0.00096789863888888886,"lastSubmitTime":"2017-11-02T00:26:45.1839581+00:00","runs":[{"item1":"a3f300fc-4496-40ad-b76d-7696e3723b77","item2":"2017-11-02T00:26:45.1839581+00:00"}],"recurrences":["58cab1f7-fe29-46ce-89ab-628a1e09c5bf"]}'} - headers: - Cache-Control: ['private, no-cache, no-store, max-age=0'] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 00:27:16 GMT'] - Expires: ['-1'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] - status: {code: 200, message: OK} -version: 1 diff --git a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/test_dla_commands.py b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/test_dla_commands.py index 323a91051a1..4056c043a42 100644 --- a/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/test_dla_commands.py +++ b/src/command_modules/azure-cli-dla/azure/cli/command_modules/dla/tests/test_dla_commands.py @@ -11,41 +11,74 @@ except ImportError: import mock -from azure.cli.testsdk.vcr_test_base import (ResourceGroupVCRTestBase, JMESPathCheck) +from azure.cli.testsdk import ScenarioTest, ResourceGroupPreparer + +from azure_devtools.scenario_tests import RecordingProcessor, mock_in_unit_test + from knack.util import CLIError -def _mock_get_uuid_str(): - return '00000000-0000-0000-0000-000000000000' +MOCK_JOB_ID = '00000000-0000-0000-0000-000000000000' + + +class JobIdReplacer(RecordingProcessor): + + """Replace the random job id with a fixed mock name.""" + def process_request(self, request): + import re + request.uri = re.sub('/Jobs/([^/?]+)', '/Jobs/{}'.format(MOCK_JOB_ID), request.uri) + return request + + def process_response(self, response): + if response['body']['string']: + response['body']['string'] = self._replace_job_id(response['body']['string']) + return response + + def _replace_job_id(self, val): + import re + if 'jobId' in val: + return re.sub(r'"jobId":"([^"]+)"', r'"jobId":"{}"'.format(MOCK_JOB_ID), val, flags=re.IGNORECASE) + return val + + +def patch_uuid_str(unit_test): + + def _mock_get_uuid_str(*args, **kwargs): # pylint: disable=unused-argument + return MOCK_JOB_ID + + mock_in_unit_test(unit_test, 'azure.cli.command_modules.dla.custom._get_uuid_str', _mock_get_uuid_str) # pylint: disable=too-many-instance-attributes -class DataLakeAnalyticsCatalogScenarioTest(ResourceGroupVCRTestBase): - - def __init__(self, test_method): - super(DataLakeAnalyticsCatalogScenarioTest, self).__init__(__file__, test_method, resource_group='test-adla-catalog-mgmt') - self.adls_name = 'cliadls123442' - self.adla_name = 'cliadla123442' - self.location = 'eastus2' - - # define catalog item names - self.db_name = 'catalog_item_1' - self.table_name = 'catalog_item_2' - self.tvf_name = 'catalog_item_3' - self.proc_name = 'catalog_item_4' - self.cred_name = 'catalog_item_5' - self.cred_user_name = 'catalog_item_6' - self.cred_user_pwd = 'catalog_item_7' - self.view_name = 'catalog_item_8' - - def test_dla_catalog_mgmt(self): - self.execute() - - def set_up(self): - super(DataLakeAnalyticsCatalogScenarioTest, self).set_up() +class DataLakeAnalyticsScenarioTest(ScenarioTest): + + def __init__(self, method_name): + return super(DataLakeAnalyticsScenarioTest, self).__init__(method_name, + recording_processors=JobIdReplacer(), + replay_patches=patch_uuid_str) + + @ResourceGroupPreparer(name_prefix='cli_test_adla_catalog_mgmt') + def test_adla_catalog_mgmt(self, resource_group): + + self.kwargs.update({ + 'dls': self.create_random_name('cliadls', 24), + 'dla': self.create_random_name('cliadla', 24), + 'loc': 'eastus2', + + # define catalog item names + 'db': 'catalog_item_1', + 'table': 'catalog_item_2', + 'tvf': 'catalog_item_3', + 'proc': 'catalog_item_4', + 'cred': 'catalog_item_5', + 'cred_username': 'catalog_item_6', + 'cred_pwd': 'catalog_item_7', + 'view': 'catalog_item_8' + }) + # create ADLS accounts - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_name, self.location)) - self.cmd('dla account create -g {} -n {} -l {} --default-data-lake-store {}'.format(self.resource_group, self.adla_name, self.location, self.adls_name)) + self.cmd('dls account create -g {rg} -n {dls} -l {loc} --disable-encryption') + self.cmd('dla account create -g {rg} -n {dla} -l {loc} --default-data-lake-store {dls}') # run job to construct catalog catalog_script = '''DROP DATABASE IF EXISTS {0}; CREATE DATABASE {0}; @@ -107,420 +140,381 @@ def set_up(self): END; CREATE VIEW {0}.dbo.{3} AS SELECT * FROM (VALUES(1,2),(2,4)) AS T(a, b); CREATE PROCEDURE {0}.dbo.{4}() AS BEGIN CREATE VIEW {0}.dbo.{3} AS SELECT * FROM (VALUES(1,2),(2,4)) AS T(a, b); END;''' - catalog_script = catalog_script.format(self.db_name, self.table_name, self.tvf_name, self.view_name, self.proc_name) - result = self.cmd('dla job submit -n {} --job-name "{}" --script "{}"'.format(self.adla_name, 'python cli catalog job', catalog_script)) - result = self.cmd('dla job wait -n {} --job-id {}'.format(self.adla_name, result['jobId'])) + catalog_script = catalog_script.format(self.kwargs['db'], self.kwargs['table'], self.kwargs['tvf'], self.kwargs['view'], self.kwargs['proc']) + self.kwargs['job_id'] = self.cmd('dla job submit -n {{dla}} --job-name "python cli catalog job" --script "{}"'.format(catalog_script)).get_output_in_json()['jobId'] + result = self.cmd('dla job wait -n {dla} --job-id {job_id}').get_output_in_json() assert result['result'] == 'Succeeded' - def body(self): - adla = self.adla_name # get all the catalog items # list all DBs - self.cmd('dla catalog database list -n {}'.format(adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 2), # because there is always the master DB + self.cmd('dla catalog database list -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 2), # because there is always the master DB ]) # get a specific DB - self.cmd('dla catalog database show -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('name', self.db_name), + self.cmd('dla catalog database show -n {dla} --database-name {db}', checks=[ + self.check('name', '{db}'), ]) # list all schemas - self.cmd('dla catalog schema list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), + self.cmd('dla catalog schema list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), ]) # get a specific schema - self.cmd('dla catalog schema show -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('name', 'dbo'), - JMESPathCheck('databaseName', self.db_name), + self.cmd('dla catalog schema show -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('name', 'dbo'), + self.check('databaseName', '{db}'), ]) # list all tables - self.cmd('dla catalog table list -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog table list -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # list all tables without specifying schema - self.cmd('dla catalog table list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog table list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get a specific table - self.cmd('dla catalog table show -n {} --database-name {} --schema-name dbo --table-name {}'.format(adla, self.db_name, self.table_name), checks=[ - JMESPathCheck('name', self.table_name), - JMESPathCheck('databaseName', self.db_name), - JMESPathCheck('schemaName', 'dbo'), + self.cmd('dla catalog table show -n {dla} --database-name {db} --schema-name dbo --table-name {table}', checks=[ + self.check('name', '{table}'), + self.check('databaseName', '{db}'), + self.check('schemaName', 'dbo'), ]) # list all views - self.cmd('dla catalog view list -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog view list -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # list all views without specifying schema - self.cmd('dla catalog view list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog view list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get a specific view - self.cmd('dla catalog view show -n {} --database-name {} --schema-name dbo --view-name {}'.format(adla, self.db_name, self.view_name), checks=[ - JMESPathCheck('name', self.view_name), - JMESPathCheck('databaseName', self.db_name), - JMESPathCheck('schemaName', 'dbo'), + self.cmd('dla catalog view show -n {dla} --database-name {db} --schema-name dbo --view-name {view}', checks=[ + self.check('name', '{view}'), + self.check('databaseName', '{db}'), + self.check('schemaName', 'dbo'), ]) # list all procs - self.cmd('dla catalog procedure list -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog procedure list -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get a specific proc - self.cmd('dla catalog procedure show -n {} --database-name {} --schema-name dbo --procedure-name {}'.format(adla, self.db_name, self.proc_name), checks=[ - JMESPathCheck('name', self.proc_name), - JMESPathCheck('databaseName', self.db_name), - JMESPathCheck('schemaName', 'dbo'), + self.cmd('dla catalog procedure show -n {dla} --database-name {db} --schema-name dbo --procedure-name {proc}', checks=[ + self.check('name', '{proc}'), + self.check('databaseName', '{db}'), + self.check('schemaName', 'dbo'), ]) # list all procs - self.cmd('dla catalog procedure list -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog procedure list -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get a specific proc - self.cmd('dla catalog procedure show -n {} --database-name {} --schema-name dbo --procedure-name {}'.format(adla, self.db_name, self.proc_name), checks=[ - JMESPathCheck('name', self.proc_name), - JMESPathCheck('databaseName', self.db_name), - JMESPathCheck('schemaName', 'dbo'), + self.cmd('dla catalog procedure show -n {dla} --database-name {db} --schema-name dbo --procedure-name {proc}', checks=[ + self.check('name', '{proc}'), + self.check('databaseName', '{db}'), + self.check('schemaName', 'dbo'), ]) # list all tvfs - self.cmd('dla catalog tvf list -n {} --database-name {} --schema-name dbo'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog tvf list -n {dla} --database-name {db} --schema-name dbo', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # list all tvfs without specifying schema - self.cmd('dla catalog tvf list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog tvf list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get a specific proc - self.cmd('dla catalog tvf show -n {} --database-name {} --schema-name dbo --table-valued-function-name {}'.format(adla, self.db_name, self.tvf_name), checks=[ - JMESPathCheck('name', self.tvf_name), - JMESPathCheck('databaseName', self.db_name), - JMESPathCheck('schemaName', 'dbo'), + self.cmd('dla catalog tvf show -n {dla} --database-name {db} --schema-name dbo --table-valued-function-name {tvf}', checks=[ + self.check('name', '{tvf}'), + self.check('databaseName', '{db}'), + self.check('schemaName', 'dbo'), ]) # credential crud # create a credential - self.cmd('dla catalog credential create -n {} --database-name {} --credential-name {} --user-name {} --password {} --uri "http://adl.contoso.com:443"'.format(adla, self.db_name, self.cred_name, self.cred_user_name, self.cred_user_pwd)) + self.cmd('dla catalog credential create -n {dla} --database-name {db} --credential-name {cred} --user-name {cred_username} --password {cred_pwd} --uri "http://adl.contoso.com:443"') # list credentials - self.cmd('dla catalog credential list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla catalog credential list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # get the specific credential - self.cmd('dla catalog credential show -n {} --database-name {} --credential-name {}'.format(adla, self.db_name, self.cred_name), checks=[ - JMESPathCheck('name', self.cred_name), + self.cmd('dla catalog credential show -n {dla} --database-name {db} --credential-name {cred}', checks=[ + self.check('name', '{cred}'), ]) # delete the specific credential - self.cmd('dla catalog credential delete -n {} --database-name {} --credential-name {}'.format(adla, self.db_name, self.cred_name)) + self.cmd('dla catalog credential delete -n {dla} --database-name {db} --credential-name {cred}') # list credentials and validate they are gone. - self.cmd('dla catalog credential list -n {} --database-name {}'.format(adla, self.db_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), - ]) - - -class DataLakeAnalyticsJobScenarioTest(ResourceGroupVCRTestBase): - def __init__(self, test_method): - super(DataLakeAnalyticsJobScenarioTest, self).__init__(__file__, test_method, resource_group='test-adla-job-mgmt') - self.adls_name = 'cliadls1234533' - self.adla_name = 'cliadla1234533' - self.location = 'eastus2' - - def test_dla_job_mgmt(self): - self.execute() - - def set_up(self): - super(DataLakeAnalyticsJobScenarioTest, self).set_up() - - @mock.patch('azure.cli.command_modules.dla.custom._get_uuid_str', - _mock_get_uuid_str) - def _execute_playback(self): - return super(DataLakeAnalyticsJobScenarioTest, self)._execute_playback() - - def body(self): - rg = self.resource_group - adla = self.adla_name - loc = self.location - # job relation ship variables - pipeline_id = '3f9a237a-325e-4ec8-9e10-60222a71354d' - pipeline_name = 'py_pipeline_name' - pipeline_uri = 'https://begoldsm.contoso.com/jobs' - recurrence_id = '58cab1f7-fe29-46ce-89ab-628a1e09c5bf' - recurrence_name = 'py_recurrence_name' - run_id = 'a3f300fc-4496-40ad-b76d-7696e3723b77' + self.cmd('dla catalog credential list -n {dla} --database-name {db}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), + ]) + + @ResourceGroupPreparer(name_prefix='cli_test_adla_job_mgmt') + def test_adla_job_mgmt(self, resource_group): + + self.kwargs.update({ + 'dls': self.create_random_name('cliadls', 24), + 'dla': self.create_random_name('cliadla', 24), + 'loc': 'eastus2', + # job relation ship variables + 'pipeline_id': '3f9a237a-325e-4ec8-9e10-60222a71354d', + 'pipeline_name': 'py_pipeline_name', + 'pipeline_uri': 'https://begoldsm.contoso.com/jobs', + 'recurrence_id': '58cab1f7-fe29-46ce-89ab-628a1e09c5bf', + 'recurrence_name': 'py_recurrence_name', + 'run_id': 'a3f300fc-4496-40ad-b76d-7696e3723b77' + }) # create ADLS accounts - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_name, loc)) - self.cmd('dls account show -g {} -n {}'.format(self.resource_group, self.adls_name), checks=[ - JMESPathCheck('name', self.adls_name), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg) + self.cmd('dls account create -g {rg} -n {dls} -l {loc} --disable-encryption') + self.cmd('dls account show -g {rg} -n {dls}', checks=[ + self.check('name', '{dls}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}') ]) - self.cmd('dla account create -g {} -n {} -l {} --default-data-lake-store {}'.format(self.resource_group, adla, loc, self.adls_name)) - self.cmd('dla account show -g {} -n {}'.format(self.resource_group, self.adla_name), checks=[ - JMESPathCheck('name', adla), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg) + self.cmd('dla account create -g {rg} -n {dla} -l {loc} --default-data-lake-store {dls}') + self.cmd('dla account show -g {rg} -n {dla}', checks=[ + self.check('name', '{dla}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}') ]) # submit job - should work with no relationship params - result = self.cmd('dla job submit -n {} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;"'.format(adla), checks=[ - JMESPathCheck('name', 'clijobtest'), - ]) + result = self.cmd('dla job submit -n {dla} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;"', checks=[ + self.check('name', 'clijobtest'), + ]).get_output_in_json() # cancel job - job_id = result['jobId'] - self.cmd('dla job cancel -n {} --job-id {}'.format(adla, job_id)) + self.kwargs['job_id'] = result['jobId'] + self.cmd('dla job cancel -n {dla} --job-id {job_id}') # get the job and confirm that it was cancelled - self.cmd('dla job show -n {} --job-id {}'.format(adla, job_id), checks=[ - JMESPathCheck('name', 'clijobtest'), - JMESPathCheck('result', 'Cancelled'), + self.cmd('dla job show -n {dla} --job-id {job_id}', checks=[ + self.check('name', 'clijobtest'), + self.check('result', 'Cancelled'), ]) # job relationship. Attempt to submit a job with invalid job relationship param combos - with self.assertRaises(CLIError): - self.cmd('dla job submit -n {} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {}'.format(adla, recurrence_name)) + with self.assertRaises(AssertionError): + self.cmd('dla job submit -n {dla} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {recurrence_name}') - with self.assertRaises(CLIError): - self.cmd('dla job submit -n {} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {} --recurrence-id {} --pipeline-name {}'.format(adla, - recurrence_name, - recurrence_id, - pipeline_name)) + with self.assertRaises(AssertionError): + self.cmd('dla job submit -n {dla} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {recurrence_name} --recurrence-id {recurrence_id} --pipeline-name {pipeline_name}') # re-submit job with a fully populated relationship - result = self.cmd( - 'dla job submit -n {} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {} --recurrence-id {} --pipeline-name {} --pipeline-id {} --pipeline-uri {} --run-id {}'.format(adla, - recurrence_name, - recurrence_id, - pipeline_name, - pipeline_id, - pipeline_uri, - run_id), - checks=[JMESPathCheck('name', 'clijobtest')]) + result = self.cmd('dla job submit -n {dla} --job-name clijobtest --script "DROP DATABASE IF EXISTS FOO; CREATE DATABASE FOO;" --recurrence-name {recurrence_name} --recurrence-id {recurrence_id} --pipeline-name {pipeline_name} --pipeline-id {pipeline_id} --pipeline-uri {pipeline_uri} --run-id {run_id}', + checks=self.check('name', 'clijobtest')).get_output_in_json() # wait for the job to finish - job_id = result['jobId'] - result = self.cmd('dla job wait -n {} --job-id {}'.format(adla, job_id), checks=[ - JMESPathCheck('name', 'clijobtest'), - JMESPathCheck('result', 'Succeeded'), - JMESPathCheck('related.recurrenceId', recurrence_id), - JMESPathCheck('related.recurrenceName', recurrence_name), - JMESPathCheck('related.pipelineId', pipeline_id), - JMESPathCheck('related.pipelineName', pipeline_name), - JMESPathCheck('related.pipelineUri', pipeline_uri), - JMESPathCheck('related.runId', run_id), + self.kwargs['job_id'] = result['jobId'] + self.cmd('dla job wait -n {dla} --job-id {job_id}', checks=[ + self.check('name', 'clijobtest'), + self.check('result', 'Succeeded'), + self.check('related.recurrenceId', '{recurrence_id}'), + self.check('related.recurrenceName', '{recurrence_name}'), + self.check('related.pipelineId', '{pipeline_id}'), + self.check('related.pipelineName', '{pipeline_name}'), + self.check('related.pipelineUri', '{pipeline_uri}'), + self.check('related.runId', '{run_id}'), ]) # list all jobs - self.cmd('dla job list -n {}'.format(adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 2) + self.cmd('dla job list -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 2) ]) # get and list job relationships (recurrence and pipeline) - result = self.cmd('dla job recurrence list -n {}'.format(adla)) + result = self.cmd('dla job recurrence list -n {dla}').get_output_in_json() assert isinstance(result, list) assert len(result) >= 1 - result = self.cmd('dla job recurrence show -n {} --recurrence-id {}'.format(adla, recurrence_id), checks=[ - JMESPathCheck('recurrenceId', recurrence_id), - JMESPathCheck('recurrenceName', recurrence_name), + self.cmd('dla job recurrence show -n {dla} --recurrence-id {recurrence_id}', checks=[ + self.check('recurrenceId', '{recurrence_id}'), + self.check('recurrenceName', '{recurrence_name}'), ]) - result = self.cmd('dla job pipeline list -n {}'.format(adla)) + result = self.cmd('dla job pipeline list -n {dla}').get_output_in_json() assert isinstance(result, list) assert len(result) >= 1 - result = self.cmd('dla job pipeline show -n {} --pipeline-id {}'.format(adla, pipeline_id), checks=[ - JMESPathCheck('pipelineId', pipeline_id), - JMESPathCheck('pipelineName', pipeline_name), - JMESPathCheck('pipelineUri', pipeline_uri), - ]) + result = self.cmd('dla job pipeline show -n {dla} --pipeline-id {pipeline_id}', checks=[ + self.check('pipelineId', '{pipeline_id}'), + self.check('pipelineName', '{pipeline_name}'), + self.check('pipelineUri', '{pipeline_uri}'), + ]).get_output_in_json() assert isinstance(result['runs'], list) assert len(result['runs']) >= 1 + @ResourceGroupPreparer(name_prefix='cli_test_adla_mgmt') + def test_adla_account_mgmt(self, resource_group): + + self.kwargs.update({ + 'dls1': self.create_random_name('cliadls', 12), + 'dls2': self.create_random_name('cliadls', 12), + 'dla': self.create_random_name('cliadla', 12), + 'wasb': self.create_random_name('cliwasb', 12), + 'loc': 'eastus2', + # compute policy variables + 'user_policy': 'pycliuserpolicy', + 'user_oid': '8ce05900-7a9e-4895-b3f0-0fbcee507803', + 'group_policy': 'pycligrouppolicy', + 'group_oid': '0583cfd7-60f5-43f0-9597-68b85591fc69' + }) -class DataLakeAnalyticsAccountScenarioTest(ResourceGroupVCRTestBase): - - def __init__(self, test_method): - super(DataLakeAnalyticsAccountScenarioTest, self).__init__(__file__, test_method, resource_group='cli-test-adla-mgmt') - self.adls_names = ['cliadls123450', 'cliadls123451'] - self.adla_name = 'cliadla123450' - self.wasb_name = 'cliadlwasb123450' - self.location = 'eastus2' - - def test_dla_account_mgmt(self): - self.execute() - - def set_up(self): - super(DataLakeAnalyticsAccountScenarioTest, self).set_up() # create ADLS accounts - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_names[0], self.location)) - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_names[1], self.location)) - self.cmd('storage account create -g {} -n {} -l {} --sku Standard_GRS'.format(self.resource_group, self.wasb_name, self.location)) - - def body(self): - rg = self.resource_group - adls1 = self.adls_names[0] - adls2 = self.adls_names[1] - adla = self.adla_name - loc = self.location - - # compute policy variables - user_policy_name = 'pycliuserpolicy' - user_object_id = '8ce05900-7a9e-4895-b3f0-0fbcee507803' - group_policy_name = 'pycligrouppolicy' - group_object_id = '0583cfd7-60f5-43f0-9597-68b85591fc69' - - result = self.cmd('storage account keys list -g {} -n {}'.format(self.resource_group, self.wasb_name)) - wasb_key = result[0]['value'] + self.cmd('dls account create -g {rg} -n {dls1} -l {loc} --disable-encryption') + self.cmd('dls account create -g {rg} -n {dls2} -l {loc} --disable-encryption') + self.cmd('storage account create -g {rg} -n {wasb} -l {loc} --sku Standard_GRS') + + result = self.cmd('storage account keys list -g {rg} -n {wasb}').get_output_in_json() + self.kwargs['wasb_key'] = result[0]['value'] # test create keyvault with default access policy set - self.cmd('dla account create -g {} -n {} -l {} --default-data-lake-store {}'.format(rg, adla, loc, adls1), checks=[ - JMESPathCheck('name', adla), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('defaultDataLakeStoreAccount', adls1), - JMESPathCheck('type(dataLakeStoreAccounts)', 'array'), - JMESPathCheck('length(dataLakeStoreAccounts)', 1), - JMESPathCheck('maxDegreeOfParallelism', 30), - JMESPathCheck('maxJobCount', 3), - JMESPathCheck('queryStoreRetention', 30), - ]) - self.cmd('dla account show -n {} -g {}'.format(adla, rg), checks=[ - JMESPathCheck('name', adla), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('defaultDataLakeStoreAccount', adls1), - JMESPathCheck('type(dataLakeStoreAccounts)', 'array'), - JMESPathCheck('length(dataLakeStoreAccounts)', 1), - JMESPathCheck('maxDegreeOfParallelism', 30), - JMESPathCheck('maxJobCount', 3), - JMESPathCheck('queryStoreRetention', 30), - ]) - self.cmd('dla account list -g {}'.format(rg), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), - JMESPathCheck('[0].name', adla), - JMESPathCheck('[0].location', loc), - JMESPathCheck('[0].resourceGroup', rg), - ]) - result = self.cmd('dla account list') + self.cmd('dla account create -g {rg} -n {dla} -l {loc} --default-data-lake-store {dls1}', checks=[ + self.check('name', '{dla}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('defaultDataLakeStoreAccount', '{dls1}'), + self.check('type(dataLakeStoreAccounts)', 'array'), + self.check('length(dataLakeStoreAccounts)', 1), + self.check('maxDegreeOfParallelism', 30), + self.check('maxJobCount', 3), + self.check('queryStoreRetention', 30), + ]) + self.cmd('dla account show -n {dla} -g {rg}', checks=[ + self.check('name', '{dla}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('defaultDataLakeStoreAccount', '{dls1}'), + self.check('type(dataLakeStoreAccounts)', 'array'), + self.check('length(dataLakeStoreAccounts)', 1), + self.check('maxDegreeOfParallelism', 30), + self.check('maxJobCount', 3), + self.check('queryStoreRetention', 30), + ]) + self.cmd('dla account list -g {rg}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), + self.check('[0].name', '{dla}'), + self.check('[0].location', '{loc}'), + self.check('[0].resourceGroup', '{rg}'), + ]) + result = self.cmd('dla account list').get_output_in_json() assert isinstance(result, list) assert len(result) >= 1 # test update acct - self.cmd('dla account update -g {} -n {} --firewall-state Enabled --max-degree-of-parallelism 15 --max-job-count 2 --query-store-retention 15 --allow-azure-ips Enabled'.format(rg, adla)) - self.cmd('dla account show -n {} -g {}'.format(adla, rg), checks=[ - JMESPathCheck('name', adla), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('defaultDataLakeStoreAccount', adls1), - JMESPathCheck('type(dataLakeStoreAccounts)', 'array'), - JMESPathCheck('length(dataLakeStoreAccounts)', 1), - JMESPathCheck('maxDegreeOfParallelism', 15), - JMESPathCheck('maxJobCount', 2), - JMESPathCheck('queryStoreRetention', 15) + self.cmd('dla account update -g {rg} -n {dla} --firewall-state Enabled --max-degree-of-parallelism 15 --max-job-count 2 --query-store-retention 15 --allow-azure-ips Enabled') + self.cmd('dla account show -n {dla} -g {rg}', checks=[ + self.check('name', '{dla}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('defaultDataLakeStoreAccount', '{dls1}'), + self.check('type(dataLakeStoreAccounts)', 'array'), + self.check('length(dataLakeStoreAccounts)', 1), + self.check('maxDegreeOfParallelism', 15), + self.check('maxJobCount', 2), + self.check('queryStoreRetention', 15) # TODO: add validation for firewall rules once they are # live in production. ]) # test adls acct add get, delete - self.cmd('dla account data-lake-store add -g {} -n {} --data-lake-store-account-name {}'.format(rg, adla, adls2)) - self.cmd('dla account data-lake-store show -g {} -n {} --data-lake-store-account-name {}'.format(rg, adla, adls2), checks=[ - JMESPathCheck('name', adls2) + self.cmd('dla account data-lake-store add -g {rg} -n {dla} --data-lake-store-account-name {dls2}') + self.cmd('dla account data-lake-store show -g {rg} -n {dla} --data-lake-store-account-name {dls2}', checks=[ + self.check('name', '{dls2}') ]) - self.cmd('dla account data-lake-store list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 2), + self.cmd('dla account data-lake-store list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 2), ]) - self.cmd('dla account data-lake-store delete -g {} -n {} --data-lake-store-account-name {}'.format(rg, adla, adls2)) - self.cmd('dla account data-lake-store list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla account data-lake-store delete -g {rg} -n {dla} --data-lake-store-account-name {dls2}') + self.cmd('dla account data-lake-store list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # test wasb add, get delete - self.cmd('dla account blob-storage add -g {} -n {} --storage-account-name {} --access-key {}'.format(rg, adla, self.wasb_name, wasb_key)) - self.cmd('dla account blob-storage show -g {} -n {} --storage-account-name {}'.format(rg, adla, self.wasb_name), checks=[ - JMESPathCheck('name', self.wasb_name) + self.cmd('dla account blob-storage add -g {rg} -n {dla} --storage-account-name {wasb} --access-key {wasb_key}') + self.cmd('dla account blob-storage show -g {rg} -n {wasb} --storage-account-name {wasb}', checks=[ + self.check('name', '{wasb}') ]) - self.cmd('dla account blob-storage list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla account blob-storage list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) - self.cmd('dla account blob-storage delete -g {} -n {} --storage-account-name {}'.format(rg, adla, self.wasb_name)) - self.cmd('dla account blob-storage list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dla account blob-storage delete -g {rg} -n {dla} --storage-account-name {wasb}') + self.cmd('dla account blob-storage list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) # test compute policy # assert that it throws if I don't specify either of the policy types - with self.assertRaises(CLIError): - self.cmd('dla account compute-policy create -g {} -n {} --compute-policy-name {} --object-id {} --object-type User'.format(rg, adla, user_policy_name, user_object_id)) + with self.assertRaises(AssertionError): + self.cmd('dla account compute-policy create -g {rg} -n {dla} --compute-policy-name {user_policy} --object-id {user_oid} --object-type User') - self.cmd('dla account compute-policy create -g {} -n {} --compute-policy-name {} --object-id {} --object-type User --max-dop-per-job 2'.format(rg, adla, user_policy_name, user_object_id), checks=[ - JMESPathCheck('name', user_policy_name), - JMESPathCheck('objectId', user_object_id), - JMESPathCheck('objectType', 'User'), - JMESPathCheck('maxDegreeOfParallelismPerJob', 2), + self.cmd('dla account compute-policy create -g {rg} -n {dla} --compute-policy-name {user_policy} --object-id {user_oid} --object-type User --max-dop-per-job 2', checks=[ + self.check('name', '{user_policy}'), + self.check('objectId', '{user_oid}'), + self.check('objectType', 'User'), + self.check('maxDegreeOfParallelismPerJob', 2), ]) # get the policy - self.cmd('dla account compute-policy show -g {} -n {} --compute-policy-name {}'.format(rg, adla, user_policy_name), checks=[ - JMESPathCheck('name', user_policy_name), - JMESPathCheck('objectId', user_object_id), - JMESPathCheck('objectType', 'User'), - JMESPathCheck('maxDegreeOfParallelismPerJob', 2), - JMESPathCheck('minPriorityPerJob', None), + self.cmd('dla account compute-policy show -g {rg} -n {dla} --compute-policy-name {user_policy}', checks=[ + self.check('name', '{user_policy}'), + self.check('objectId', '{user_oid}'), + self.check('objectType', 'User'), + self.check('maxDegreeOfParallelismPerJob', 2), + self.check('minPriorityPerJob', None), ]) # add the group policy - self.cmd('dla account compute-policy create -g {} -n {} --compute-policy-name {} --object-id {} --object-type Group --max-dop-per-job 2'.format(rg, adla, group_policy_name, group_object_id), checks=[ - JMESPathCheck('name', group_policy_name), - JMESPathCheck('objectId', group_object_id), - JMESPathCheck('objectType', 'Group'), - JMESPathCheck('maxDegreeOfParallelismPerJob', 2), + self.cmd('dla account compute-policy create -g {rg} -n {dla} --compute-policy-name {group_policy} --object-id {group_oid} --object-type Group --max-dop-per-job 2', checks=[ + self.check('name', '{group_policy}'), + self.check('objectId', '{group_oid}'), + self.check('objectType', 'Group'), + self.check('maxDegreeOfParallelismPerJob', 2), ]) # update the user policy - self.cmd('dla account compute-policy update -g {} -n {} --compute-policy-name {} --min-priority-per-job 2'.format(rg, adla, user_policy_name), checks=[ - JMESPathCheck('name', user_policy_name), - JMESPathCheck('objectId', user_object_id), - JMESPathCheck('objectType', 'User'), - JMESPathCheck('maxDegreeOfParallelismPerJob', 2), - JMESPathCheck('minPriorityPerJob', 2), + self.cmd('dla account compute-policy update -g {rg} -n {dla} --compute-policy-name {user_policy} --min-priority-per-job 2', checks=[ + self.check('name', '{user_policy}'), + self.check('objectId', '{user_oid}'), + self.check('objectType', 'User'), + self.check('maxDegreeOfParallelismPerJob', 2), + self.check('minPriorityPerJob', 2), ]) # list the policies - self.cmd('dla account compute-policy list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 2), + self.cmd('dla account compute-policy list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 2), ]) # delete the user policy - self.cmd('dla account compute-policy delete -g {} -n {} --compute-policy-name {}'.format(rg, adla, user_policy_name)) + self.cmd('dla account compute-policy delete -g {rg} -n {dla} --compute-policy-name {user_policy}') # list again and verify there is one less policy - self.cmd('dla account compute-policy list -g {} -n {}'.format(rg, adla), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dla account compute-policy list -g {rg} -n {dla}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) # test account deletion - self.cmd('dla account delete -g {} -n {}'.format(rg, adla)) - self.cmd('dla account list -g {}'.format(rg), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dla account delete -g {rg} -n {dla}') + self.cmd('dla account list -g {rg}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/__init__.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/__init__.py index 798e448ef8c..d9f55d8e75f 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/__init__.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/__init__.py @@ -3,12 +3,29 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- # pylint: disable=unused-import -import azure.cli.command_modules.dls._help +from azure.cli.core import AzCommandsLoader -def load_params(_): - import azure.cli.command_modules.dls._params # pylint: disable=redefined-outer-name, unused-variable +from azure.cli.command_modules.dls._help import helps # pylint: disable=unused-import -def load_commands(): - import azure.cli.command_modules.dls.commands # pylint: disable=redefined-outer-name, unused-variable +class DataLakeStoreCommandsLoader(AzCommandsLoader): + + def __init__(self, cli_ctx=None): + from azure.cli.core.commands import CliCommandType + dls_custom = CliCommandType(operations_tmpl='azure.cli.command_modules.dls.custom#{}') + super(DataLakeStoreCommandsLoader, self).__init__(cli_ctx=cli_ctx, + min_profile='2017-03-10-profile', + custom_command_type=dls_custom) + + def load_command_table(self, args): + from azure.cli.command_modules.dls.commands import load_command_table + load_command_table(self, args) + return self.command_table + + def load_arguments(self, command): + from azure.cli.command_modules.dls._params import load_arguments + load_arguments(self, command) + + +COMMAND_LOADER_CLS = DataLakeStoreCommandsLoader diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_client_factory.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_client_factory.py index fc4bc667da9..cd59677c419 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_client_factory.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_client_factory.py @@ -2,35 +2,36 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core._profile import CLOUD, Profile -def cf_dls_account(_): +def cf_dls_account(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.store import DataLakeStoreAccountManagementClient - return get_mgmt_service_client(DataLakeStoreAccountManagementClient).account + return get_mgmt_service_client(cli_ctx, DataLakeStoreAccountManagementClient).account -def cf_dls_account_firewall(_): +def cf_dls_account_firewall(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.store import DataLakeStoreAccountManagementClient - return get_mgmt_service_client(DataLakeStoreAccountManagementClient).firewall_rules + return get_mgmt_service_client(cli_ctx, DataLakeStoreAccountManagementClient).firewall_rules -def cf_dls_account_trusted_provider(_): +def cf_dls_account_trusted_provider(cli_ctx, _): from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.store import DataLakeStoreAccountManagementClient - return get_mgmt_service_client(DataLakeStoreAccountManagementClient).trusted_id_providers + return get_mgmt_service_client(cli_ctx, DataLakeStoreAccountManagementClient).trusted_id_providers def cf_dls_filesystem(cli_ctx, account_name): from azure.datalake.store import core + from azure.cli.core._profile import Profile + profile = Profile(cli_ctx) subscription_id = None cred, subscription_id, _ = profile.get_login_credentials( subscription_id=subscription_id, - resource=CLOUD.endpoints.active_directory_data_lake_resource_id) + resource=cli_ctx.cloud.endpoints.active_directory_data_lake_resource_id) return core.AzureDLFileSystem( token=cred, store_name=account_name, - url_suffix=CLOUD.suffixes.azure_datalake_store_file_system_endpoint) + url_suffix=cli_ctx.cloud.suffixes.azure_datalake_store_file_system_endpoint) diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_params.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_params.py index a7ba8bde149..8acbccae1da 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_params.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_params.py @@ -2,69 +2,104 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core.commands import register_cli_argument -from azure.cli.core.commands.parameters import tags_type, get_resource_name_completion_list, resource_group_name_type +from knack.arguments import CLIArgumentType + +from azure.cli.core.commands.parameters import ( + tags_type, get_resource_name_completion_list, resource_group_name_type, get_enum_type) from azure.cli.command_modules.dls._validators import validate_resource_group_name -from azure.mgmt.datalake.store.models.data_lake_store_account_management_client_enums \ - import (FirewallState, - TrustedIdProviderState, - TierType, - FirewallAllowAzureIpsState) - -from azure.mgmt.datalake.store.models import (EncryptionConfigType) - -from knack.arguments import CLIArgumentType, enum_choice_list - -# ARGUMENT DEFINITIONS -# pylint: disable=line-too-long -datalake_store_name_type = CLIArgumentType(help='Name of the Data Lake Store account.', options_list=('--account_name',), completer=get_resource_name_completion_list('Microsoft.DataLakeStore/accounts'), id_part='name') - -# PARAMETER REGISTRATIONS -# global params -register_cli_argument('dls', 'account_name', datalake_store_name_type, options_list=('--account', '-n')) -register_cli_argument('dls', 'top', help='Maximum number of items to return.', type=int) -register_cli_argument('dls', 'skip', help='The number of items to skip over before returning elements.', type=int) -register_cli_argument('dls', 'count', help='The Boolean value of true or false to request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.', type=bool) -# global account params -register_cli_argument('dls account', 'tags', tags_type) -register_cli_argument('dls account', 'resource_group_name', resource_group_name_type, id_part=None, required=False, help='If not specified, will attempt to discover the resource group for the specified Data Lake Store account.', validator=validate_resource_group_name) -# account params -register_cli_argument('dls account show', 'name', datalake_store_name_type, options_list=('--account', '-n')) -register_cli_argument('dls account delete', 'name', datalake_store_name_type, options_list=('--account', '-n')) -register_cli_argument('dls account', 'tier', help='The desired commitment tier for this account to use.', **enum_choice_list(TierType)) -register_cli_argument('dls account create', 'resource_group_name', resource_group_name_type, validator=None) -register_cli_argument('dls account create', 'account_name', datalake_store_name_type, options_list=('--account', '-n'), completer=None) -register_cli_argument('dls account create', 'encryption_type', help='Indicates what type of encryption to provision the account with. By default, encryption is ServiceManaged. If no encryption is desired, it must be explicitly set with the --disable-encryption flag.', **enum_choice_list(EncryptionConfigType)) -register_cli_argument('dls account create', 'disable_encryption', help='Indicates that the account will not have any form of encryption applied to it.', action='store_true') -register_cli_argument('dls account update', 'trusted_id_provider_state', help='Enable/disable the existing trusted ID providers.', **enum_choice_list(TrustedIdProviderState)) -register_cli_argument('dls account update', 'firewall_state', help='Enable/disable existing firewall rules.', **enum_choice_list(FirewallState)) -register_cli_argument('dls account update', 'allow_azure_ips', help='Allow/block Azure originating IPs through the firewall', **enum_choice_list(FirewallAllowAzureIpsState)) -register_cli_argument('dls account list', 'resource_group_name', resource_group_name_type, validator=None) - -# filesystem params -register_cli_argument('dls fs', 'path', help='The path in the specified Data Lake Store account where the action should take place. In the format \'/folder/file.txt\', where the first \'/\' after the DNS indicates the root of the file system.') -register_cli_argument('dls fs create', 'force', help='Indicates that, if the file or folder exists, it should be overwritten', action='store_true') -register_cli_argument('dls fs create', 'folder', help='Indicates that this new item is a folder and not a file.', action='store_true') -register_cli_argument('dls fs delete', 'recurse', help='Indicates this should be a recursive delete of the folder.', action='store_true') -register_cli_argument('dls fs upload', 'overwrite', help='Indicates that, if the destination file or folder exists, it should be overwritten', action='store_true') -register_cli_argument('dls fs upload', 'thread_count', help='Specify the parallelism of the upload. Default is the number of cores in the local machine.', type=int) -register_cli_argument('dls fs upload', 'chunk_size', help='Number of bytes for a chunk. Large files are split into chunks. Files smaller than this number will always be transferred in a single thread.', type=int, default=268435456, required=False) -register_cli_argument('dls fs upload', 'buffer_size', help='Number of bytes for internal buffer. This block cannot be bigger than a chunk and cannot be smaller than a block.', type=int, default=4194304, required=False) -register_cli_argument('dls fs upload', 'block_size', help='Number of bytes for a block. Within each chunk, we write a smaller block for each API call. This block cannot be bigger than a chunk. ', type=int, default=4194304, required=False) -register_cli_argument('dls fs download', 'overwrite', help='Indicates that, if the destination file or folder exists, it should be overwritten', action='store_true') -register_cli_argument('dls fs download', 'thread_count', help='Specify the parallelism of the download. Default is the number of cores in the local machine.', type=int) -register_cli_argument('dls fs download', 'chunk_size', help='Number of bytes for a chunk. Large files are split into chunks. Files smaller than this number will always be transferred in a single thread.', type=int, default=268435456, required=False) -register_cli_argument('dls fs download', 'buffer_size', help='Number of bytes for internal buffer. This block cannot be bigger than a chunk and cannot be smaller than a block.', type=int, default=4194304, required=False) -register_cli_argument('dls fs download', 'block_size', help='Number of bytes for a block. Within each chunk, we write a smaller block for each API call. This block cannot be bigger than a chunk.', type=int, default=4194304, required=False) -register_cli_argument('dls fs preview', 'force', help='Indicates that, if the preview is larger than 1MB, still retrieve it. This can potentially be very slow, depending on how large the file is.', action='store_true') -register_cli_argument('dls fs join', 'force', help='Indicates that, if the destination file already exists, it should be overwritten', action='store_true') -register_cli_argument('dls fs join', 'source_paths', help='The list of files in the specified Data Lake Store account to join.', nargs='+') -register_cli_argument('dls fs move', 'force', help='Indicates that, if the destination file or folder already exists, it should be overwritten and replaced with the file or folder being moved.', action='store_true') -register_cli_argument('dls fs set-expiry', 'expiration_time', help='The absolute value of the expiration time expressed as milliseconds since the epoch.') - -# filesystem access params -register_cli_argument('dls fs access', 'acl_spec', help=" The ACL specification to set on the path in the format '[default:]user|group|other:[entity id or UPN]:r|-w|-x|-,[default:]user|group|other:[entity id or UPN]:r|-w|-x|-,...'.") -register_cli_argument('dls fs access set-permission', 'permission', help='The octal representation of the permissions for user, group and mask (for example: 777 is full rwx for all entities)', type=int) -register_cli_argument('dls fs access remove-all', 'default_acl', help='A switch that, if specified, indicates that the remove ACL operation should remove the default ACL of the folder. Otherwise the regular ACL is removed.', action='store_true') +from azure.mgmt.datalake.store.models.data_lake_store_account_management_client_enums import ( + FirewallState, + TrustedIdProviderState, + TierType, + FirewallAllowAzureIpsState) + +from azure.mgmt.datalake.store.models import EncryptionConfigType + + +# pylint: disable=line-too-long, too-many-statements +def load_arguments(self, _): + # ARGUMENT DEFINITIONS + datalake_store_name_type = CLIArgumentType(help='Name of the Data Lake Store account.', options_list=['--account_name'], completer=get_resource_name_completion_list('Microsoft.DataLakeStore/accounts'), id_part='name') + + # PARAMETER REGISTRATIONS + # global + with self.argument_context('dls') as c: + c.argument('account_name', datalake_store_name_type, options_list=['--account', '-n']) + c.argument('top', help='Maximum number of items to return.', type=int) + c.argument('skip', help='The number of items to skip over before returning elements.', type=int) + c.argument('count', help='The Boolean value of true or false to request a count of the matching resources included with the resources in the response, e.g. Categories?$count=true.', type=bool) + + # global account + with self.argument_context('dls account') as c: + c.argument('tags', tags_type) + c.argument('resource_group_name', resource_group_name_type, id_part=None, required=False, help='If not specified, will attempt to discover the resource group for the specified Data Lake Store account.', validator=validate_resource_group_name) + c.argument('tier', arg_type=get_enum_type(TierType), help='The desired commitment tier for this account to use.') + + # account + for scope in ['dls account show', 'dls account delete']: + with self.argument_context(scope) as c: + c.argument('name', datalake_store_name_type, options_list=['--account', '-n']) + + with self.argument_context('dls account create') as c: + c.argument('resource_group_name', resource_group_name_type, validator=None) + c.argument('account_name', datalake_store_name_type, options_list=['--account', '-n'], completer=None) + c.argument('encryption_type', arg_type=get_enum_type(EncryptionConfigType), help='Indicates what type of encryption to provision the account with. By default, encryption is ServiceManaged. If no encryption is desired, it must be explicitly set with the --disable-encryption flag.') + c.argument('disable_encryption', help='Indicates that the account will not have any form of encryption applied to it.', action='store_true') + + with self.argument_context('dls account update') as c: + c.argument('trusted_id_provider_state', arg_type=get_enum_type(TrustedIdProviderState), help='Enable/disable the existing trusted ID providers.') + c.argument('firewall_state', arg_type=get_enum_type(FirewallState), help='Enable/disable existing firewall rules.') + c.argument('allow_azure_ips', arg_type=get_enum_type(FirewallAllowAzureIpsState), help='Allow/block Azure originating IPs through the firewall') + + with self.argument_context('dls account list') as c: + c.argument('resource_group_name', resource_group_name_type, validator=None) + + # filesystem + with self.argument_context('dls fs') as c: + c.argument('path', help='The path in the specified Data Lake Store account where the action should take place. In the format \'/folder/file.txt\', where the first \'/\' after the DNS indicates the root of the file system.') + + with self.argument_context('dls fs create') as c: + c.argument('force', help='Indicates that, if the file or folder exists, it should be overwritten', action='store_true') + c.argument('folder', help='Indicates that this new item is a folder and not a file.', action='store_true') + + with self.argument_context('dls fs delete') as c: + c.argument('recurse', help='Indicates this should be a recursive delete of the folder.', action='store_true') + + with self.argument_context('dls fs upload') as c: + c.argument('overwrite', help='Indicates that, if the destination file or folder exists, it should be overwritten', action='store_true') + c.argument('thread_count', help='Specify the parallelism of the upload. Default is the number of cores in the local machine.', type=int) + c.argument('chunk_size', help='Number of bytes for a chunk. Large files are split into chunks. Files smaller than this number will always be transferred in a single thread.', type=int, default=268435456, required=False) + c.argument('buffer_size', help='Number of bytes for internal buffer. This block cannot be bigger than a chunk and cannot be smaller than a block.', type=int, default=4194304, required=False) + c.argument('block_size', help='Number of bytes for a block. Within each chunk, we write a smaller block for each API call. This block cannot be bigger than a chunk. ', type=int, default=4194304, required=False) + + with self.argument_context('dls fs download') as c: + c.argument('overwrite', help='Indicates that, if the destination file or folder exists, it should be overwritten', action='store_true') + c.argument('thread_count', help='Specify the parallelism of the download. Default is the number of cores in the local machine.', type=int) + c.argument('chunk_size', help='Number of bytes for a chunk. Large files are split into chunks. Files smaller than this number will always be transferred in a single thread.', type=int, default=268435456, required=False) + c.argument('buffer_size', help='Number of bytes for internal buffer. This block cannot be bigger than a chunk and cannot be smaller than a block.', type=int, default=4194304, required=False) + c.argument('block_size', help='Number of bytes for a block. Within each chunk, we write a smaller block for each API call. This block cannot be bigger than a chunk.', type=int, default=4194304, required=False) + + with self.argument_context('dls fs preview') as c: + c.argument('force', help='Indicates that, if the preview is larger than 1MB, still retrieve it. This can potentially be very slow, depending on how large the file is.', action='store_true') + + with self.argument_context('dls fs join') as c: + c.argument('force', help='Indicates that, if the destination file already exists, it should be overwritten', action='store_true') + c.argument('source_paths', help='The list of files in the specified Data Lake Store account to join.', nargs='+') + + with self.argument_context('dls fs move') as c: + c.argument('force', help='Indicates that, if the destination file or folder already exists, it should be overwritten and replaced with the file or folder being moved.', action='store_true') + + with self.argument_context('dls fs set-expiry') as c: + c.argument('expiration_time', help='The absolute value of the expiration time expressed as milliseconds since the epoch.') + + # filesystem access params + with self.argument_context('dls fs access') as c: + c.argument('acl_spec', help=" The ACL specification to set on the path in the format '[default:]user|group|other:[entity id or UPN]:r|-w|-x|-,[default:]user|group|other:[entity id or UPN]:r|-w|-x|-,...'.") + + with self.argument_context('dls fs access set-permission') as c: + c.argument('permission', help='The octal representation of the permissions for user, group and mask (for example: 777 is full rwx for all entities)', type=int) + + with self.argument_context('dls fs access remove-all') as c: + c.argument('default_acl', help='A switch that, if specified, indicates that the remove ACL operation should remove the default ACL of the folder. Otherwise the regular ACL is removed.', action='store_true') diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_validators.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_validators.py index b349d9412f9..decb6991ee8 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_validators.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/_validators.py @@ -2,10 +2,13 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- + +from msrestazure.tools import parse_resource_id + +from knack.util import CLIError + from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.mgmt.datalake.store import DataLakeStoreAccountManagementClient -from azure.cli.core.commands.arm import parse_resource_id -from knack.util import CLIError # Helpers @@ -26,12 +29,12 @@ def _get_resource_group_from_account_name(client, account_name): # COMMAND NAMESPACE VALIDATORS -def validate_resource_group_name(ns): +def validate_resource_group_name(cmd, ns): if not ns.resource_group_name: try: account_name = ns.name except AttributeError: account_name = ns.account_name - client = get_mgmt_service_client(DataLakeStoreAccountManagementClient).account + client = get_mgmt_service_client(cmd.cli_ctx, DataLakeStoreAccountManagementClient).account group_name = _get_resource_group_from_account_name(client, account_name) ns.resource_group_name = group_name diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/commands.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/commands.py index 23125908386..6687daa7062 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/commands.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/commands.py @@ -4,59 +4,82 @@ # -------------------------------------------------------------------------------------------- # pylint: disable=line-too-long -from azure.cli.core.commands import cli_command -from azure.cli.core.profiles import supported_api_version, PROFILE_TYPE -from azure.cli.command_modules.dls._client_factory import (cf_dls_account, - cf_dls_account_firewall, - cf_dls_account_trusted_provider) +from azure.cli.core.commands import CliCommandType +from azure.cli.command_modules.dls._client_factory import ( + cf_dls_account, + cf_dls_account_firewall, + cf_dls_account_trusted_provider) -if not supported_api_version(PROFILE_TYPE, max_api='2017-03-09-profile'): - adls_format_path = 'azure.mgmt.datalake.store.operations.{}#{}.{}' - adls_custom_format_path = 'azure.cli.command_modules.dls.custom#{}' + +def load_command_table(self, _): + + adls_format_path = 'azure.mgmt.datalake.store.operations.{}#{}.{{}}' + + dls_custom = CliCommandType(operations_tmpl='azure.cli.command_modules.dls.custom#{}') + + dls_account_sdk = CliCommandType( + operations_tmpl=adls_format_path.format('account_operations', 'AccountOperations'), + client_factory=cf_dls_account + ) + + dls_firewall_sdk = CliCommandType( + operations_tmpl=adls_format_path.format('firewall_rules_operations', 'FirewallRulesOperations'), + client_factory=cf_dls_account + ) + + dls_provider_sdk = CliCommandType( + operations_tmpl=adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations'), + client_factory=cf_dls_account_trusted_provider + ) # account operations - cli_command(__name__, 'dls account create', adls_custom_format_path.format('create_adls_account'), cf_dls_account) - cli_command(__name__, 'dls account update', adls_custom_format_path.format('update_adls_account'), cf_dls_account) - cli_command(__name__, 'dls account list', adls_custom_format_path.format('list_adls_account'), cf_dls_account) - cli_command(__name__, 'dls account delete', adls_format_path.format('account_operations', 'AccountOperations', 'delete'), cf_dls_account) - cli_command(__name__, 'dls account show', adls_format_path.format('account_operations', 'AccountOperations', 'get'), cf_dls_account) - cli_command(__name__, 'dls account enable-key-vault', adls_format_path.format('account_operations', 'AccountOperations', 'enable_key_vault'), cf_dls_account) + with self.command_group('dls account', dls_account_sdk, client_factory=cf_dls_account) as g: + g.custom_command('create', 'create_adls_account') + g.custom_command('update', 'update_adls_account') + g.custom_command('list', 'list_adls_account') + g.command('delete', 'delete') + g.command('show', 'get') + g.command('enable-key-vault', 'enable_key_vault') # account firewall operations - cli_command(__name__, 'dls account firewall create', adls_custom_format_path.format('add_adls_firewall_rule'), cf_dls_account_firewall) - cli_command(__name__, 'dls account firewall update', adls_format_path.format('firewall_rules_operations', 'FirewallRulesOperations', 'update'), cf_dls_account_firewall) - cli_command(__name__, 'dls account firewall list', adls_format_path.format('firewall_rules_operations', 'FirewallRulesOperations', 'list_by_account'), cf_dls_account_firewall) - cli_command(__name__, 'dls account firewall show', adls_format_path.format('firewall_rules_operations', 'FirewallRulesOperations', 'get'), cf_dls_account_firewall) - cli_command(__name__, 'dls account firewall delete', adls_format_path.format('firewall_rules_operations', 'FirewallRulesOperations', 'delete'), cf_dls_account_firewall) + with self.command_group('dls account firewall', dls_firewall_sdk, client_factory=cf_dls_account_firewall) as g: + g.custom_command('create', 'add_adls_firewall_rule') + g.command('update', 'update') + g.command('list', 'list_by_account') + g.command('show', 'get') + g.command('delete', 'delete') # account trusted id provider operations - cli_command(__name__, 'dls account trusted-provider create', adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations', 'create_or_update'), cf_dls_account_trusted_provider) - cli_command(__name__, 'dls account trusted-provider update', adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations', 'update'), cf_dls_account_trusted_provider) - cli_command(__name__, 'dls account trusted-provider list', adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations', 'list_by_account'), cf_dls_account_trusted_provider) - cli_command(__name__, 'dls account trusted-provider show', adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations', 'get'), cf_dls_account_trusted_provider) - cli_command(__name__, 'dls account trusted-provider delete', adls_format_path.format('trusted_id_providers_operations', 'TrustedIdProvidersOperations', 'delete'), cf_dls_account_trusted_provider) + with self.command_group('dls account trusted-provider', dls_provider_sdk) as g: + g.command('create', 'create_or_update') + g.command('update', 'update') + g.command('list', 'list_by_account') + g.command('show', 'get') + g.command('delete', 'delete') # filesystem operations - cli_command(__name__, 'dls fs show', adls_custom_format_path.format('get_adls_item')) - cli_command(__name__, 'dls fs list', adls_custom_format_path.format('list_adls_items')) - cli_command(__name__, 'dls fs create', adls_custom_format_path.format('create_adls_item')) - cli_command(__name__, 'dls fs append', adls_custom_format_path.format('append_adls_item')) - cli_command(__name__, 'dls fs delete', adls_custom_format_path.format('remove_adls_item')) - cli_command(__name__, 'dls fs upload', adls_custom_format_path.format('upload_to_adls')) - cli_command(__name__, 'dls fs download', adls_custom_format_path.format('download_from_adls')) - cli_command(__name__, 'dls fs download', adls_custom_format_path.format('download_from_adls')) - cli_command(__name__, 'dls fs test', adls_custom_format_path.format('test_adls_item')) - cli_command(__name__, 'dls fs preview', adls_custom_format_path.format('preview_adls_item')) - cli_command(__name__, 'dls fs join', adls_custom_format_path.format('join_adls_items')) - cli_command(__name__, 'dls fs move', adls_custom_format_path.format('move_adls_item')) - cli_command(__name__, 'dls fs set-expiry', adls_custom_format_path.format('set_adls_item_expiry')) - cli_command(__name__, 'dls fs remove-expiry', adls_custom_format_path.format('remove_adls_item_expiry')) + with self.command_group('dls fs', dls_custom) as g: + g.command('show', 'get_adls_item') + g.command('list', 'list_adls_items') + g.command('create', 'create_adls_item') + g.command('append', 'append_adls_item') + g.command('delete', 'remove_adls_item') + g.command('upload', 'upload_to_adls') + g.command('download', 'download_from_adls') + g.command('download', 'download_from_adls') + g.command('test', 'test_adls_item') + g.command('preview', 'preview_adls_item') + g.command('join', 'join_adls_items') + g.command('move', 'move_adls_item') + g.command('set-expiry', 'set_adls_item_expiry') + g.command('remove-expiry', 'remove_adls_item_expiry') # filesystem permission operations - cli_command(__name__, 'dls fs access set-permission', adls_custom_format_path.format('set_adls_item_permissions')) - cli_command(__name__, 'dls fs access set-owner', adls_custom_format_path.format('set_adls_item_owner')) - cli_command(__name__, 'dls fs access show', adls_custom_format_path.format('get_adls_item_acl')) - cli_command(__name__, 'dls fs access set-entry', adls_custom_format_path.format('set_adls_item_acl_entry')) - cli_command(__name__, 'dls fs access set', adls_custom_format_path.format('set_adls_item_acl')) - cli_command(__name__, 'dls fs access remove-entry', adls_custom_format_path.format('remove_adls_item_acl_entry')) - cli_command(__name__, 'dls fs access remove-all', adls_custom_format_path.format('remove_adls_item_acl')) + with self.command_group('dls fs access', dls_custom) as g: + g.command('set-permission', 'set_adls_item_permissions') + g.command('set-owner', 'set_adls_item_owner') + g.command('show', 'get_adls_item_acl') + g.command('set-entry', 'set_adls_item_acl_entry') + g.command('set', 'set_adls_item_acl') + g.command('remove-entry', 'remove_adls_item_acl_entry') + g.command('remove-all', 'remove_adls_item_acl') diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/custom.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/custom.py index bc4826d9a62..28c237c38a3 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/custom.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/custom.py @@ -2,56 +2,52 @@ # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.mgmt.datalake.store.models import (DataLakeStoreAccountUpdateParameters, - FirewallRule, - DataLakeStoreAccount, - EncryptionConfigType, - EncryptionIdentity, - EncryptionConfig, - EncryptionState, - KeyVaultMetaInfo, - UpdateEncryptionConfig, - UpdateKeyVaultMetaInfo) + +from knack.log import get_logger +from knack.util import CLIError + +from azure.mgmt.datalake.store.models import ( + DataLakeStoreAccountUpdateParameters, + FirewallRule, + DataLakeStoreAccount, + EncryptionConfigType, + EncryptionIdentity, + EncryptionConfig, + EncryptionState, + KeyVaultMetaInfo, + UpdateEncryptionConfig, + UpdateKeyVaultMetaInfo) from azure.datalake.store.enums import ExpiryOptionType from azure.datalake.store.multithread import (ADLUploader, ADLDownloader) from azure.cli.command_modules.dls._client_factory import (cf_dls_filesystem) from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.cli.core.profiles import ResourceType -from azure.cli.core.application import APPLICATION -from knack.util import CLIError + +logger = get_logger(__name__) -def _update_progress(current, total): - hook = APPLICATION.get_progress_controller(det=True) +def _update_progress(cli_ctx, current, total): + hook = cli_ctx.get_progress_controller(det=True) if total: hook.add(message='Alive', value=current, total_val=total) if total == current: hook.end() -# account customiaztions +# region account def list_adls_account(client, resource_group_name=None): account_list = client.list_by_resource_group(resource_group_name=resource_group_name) \ if resource_group_name else client.list() return list(account_list) -def create_adls_account(client, - resource_group_name, - account_name, - location=None, - default_group=None, - tags=None, - encryption_type=EncryptionConfigType.service_managed.value, - key_vault_id=None, - key_name=None, - key_version=None, - disable_encryption=False, - tier=None): - - location = location or _get_resource_group_location(resource_group_name) +def create_adls_account(cmd, client, resource_group_name, account_name, location=None, default_group=None, tags=None, + encryption_type=EncryptionConfigType.service_managed.value, key_vault_id=None, key_name=None, + key_version=None, disable_encryption=False, tier=None): + + location = location or _get_resource_group_location(cmd.cli_ctx, resource_group_name) create_params = DataLakeStoreAccount(location, tags=tags, default_group=default_group, @@ -80,16 +76,8 @@ def create_adls_account(client, return client.create(resource_group_name, account_name, create_params).result() -def update_adls_account(client, - account_name, - resource_group_name, - tags=None, - default_group=None, - firewall_state=None, - allow_azure_ips=None, - trusted_id_provider_state=None, - tier=None, - key_version=None): +def update_adls_account(client, account_name, resource_group_name, tags=None, default_group=None, firewall_state=None, + allow_azure_ips=None, trusted_id_provider_state=None, tier=None, key_version=None): update_params = DataLakeStoreAccountUpdateParameters( tags=tags, default_group=default_group, @@ -104,9 +92,10 @@ def update_adls_account(client, UpdateKeyVaultMetaInfo(key_version)) return client.update(resource_group_name, account_name, update_params).result() +# endregion -# firewall customizations +# region firewall def add_adls_firewall_rule(client, account_name, firewall_rule_name, @@ -118,25 +107,20 @@ def add_adls_firewall_rule(client, account_name, firewall_rule_name, create_params) +# endregion -# filesystem customizations -def get_adls_item(account_name, - path): - return cf_dls_filesystem(account_name).info(path) +# region filesystem +def get_adls_item(cmd, account_name, path): + return cf_dls_filesystem(cmd.cli_ctx, account_name).info(path) -def list_adls_items(account_name, - path): - return cf_dls_filesystem(account_name).ls(path, detail=True) +def list_adls_items(cmd, account_name, path): + return cf_dls_filesystem(cmd.cli_ctx, account_name).ls(path, detail=True) -def create_adls_item(account_name, - path, - content=None, - folder=False, - force=False): - client = cf_dls_filesystem(account_name) +def create_adls_item(cmd, account_name, path, content=None, folder=False, force=False): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if client.exists(path): if force: # only recurse if the user wants this to be a folder @@ -160,10 +144,8 @@ def create_adls_item(account_name, return client.touch(path) -def append_adls_item(account_name, - path, - content): - client = cf_dls_filesystem(account_name) +def append_adls_item(cmd, account_name, path, content): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if not client.exists(path): # pylint: disable=line-too-long raise CLIError('File at path: \'{}\' does not exist. Create the file before attempting to append to it.'.format(path)) @@ -174,16 +156,9 @@ def append_adls_item(account_name, f.write(content) -def upload_to_adls(account_name, - source_path, - destination_path, - chunk_size, - buffer_size, - block_size, - thread_count=None, - overwrite=False, - progress_callback=_update_progress): - client = cf_dls_filesystem(account_name) +def upload_to_adls(cmd, account_name, source_path, destination_path, chunk_size, buffer_size, block_size, + thread_count=None, overwrite=False, progress_callback=_update_progress): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) ADLUploader( client, destination_path, @@ -196,22 +171,13 @@ def upload_to_adls(account_name, progress_callback=progress_callback) -def remove_adls_item(account_name, - path, - recurse=False): - cf_dls_filesystem(account_name).rm(path, recurse) +def remove_adls_item(cmd, account_name, path, recurse=False): + cf_dls_filesystem(cmd.cli_ctx, account_name).rm(path, recurse) -def download_from_adls(account_name, - source_path, - destination_path, - chunk_size, - buffer_size, - block_size, - thread_count=None, - overwrite=False, - progress_callback=_update_progress): - client = cf_dls_filesystem(account_name) +def download_from_adls(cmd, account_name, source_path, destination_path, chunk_size, buffer_size, block_size, + thread_count=None, overwrite=False, progress_callback=_update_progress): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) ADLDownloader( client, source_path, @@ -224,17 +190,12 @@ def download_from_adls(account_name, progress_callback=progress_callback) -def test_adls_item(account_name, - path): - return cf_dls_filesystem(account_name).exists(path) +def test_adls_item(cmd, account_name, path): + return cf_dls_filesystem(cmd.cli_ctx, account_name).exists(path) -def preview_adls_item(account_name, - path, - length=None, - offset=0, - force=False): - client = cf_dls_filesystem(account_name) +def preview_adls_item(cmd, account_name, path, length=None, offset=0, force=False): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if length: try: length = long(length) @@ -256,31 +217,23 @@ def preview_adls_item(account_name, return client.read_block(path, offset, length) -def join_adls_items(account_name, - source_paths, - destination_path, - force=False): - client = cf_dls_filesystem(account_name) +def join_adls_items(cmd, account_name, source_paths, destination_path, force=False): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if force and client.exists(destination_path): client.rm(destination_path) client.concat(destination_path, source_paths) -def move_adls_item(account_name, - source_path, - destination_path, - force=False): - client = cf_dls_filesystem(account_name) +def move_adls_item(cmd, account_name, source_path, destination_path, force=False): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if force and client.exists(destination_path): client.rm(destination_path) client.mv(source_path, destination_path) -def set_adls_item_expiry(account_name, - path, - expiration_time): - client = cf_dls_filesystem(account_name) +def set_adls_item_expiry(cmd, account_name, path, expiration_time): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if client.info(path)['type'] != 'FILE': # pylint: disable=line-too-long raise CLIError('The specified path does not exist or is not a file. Please ensure the path points to a file and it exists. Path supplied: {}'.format(path)) @@ -293,69 +246,56 @@ def set_adls_item_expiry(account_name, client.set_expiry(path, ExpiryOptionType.absolute.value, expiration_time) -def remove_adls_item_expiry(account_name, - path): - client = cf_dls_filesystem(account_name) +def remove_adls_item_expiry(cmd, account_name, path): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if client.info(path)['type'] != 'FILE': # pylint: disable=line-too-long raise CLIError('The specified path does not exist or is not a file. Please ensure the path points to a file and it exists. Path supplied: {}'.format(path)) client.set_expiry(path, ExpiryOptionType.never_expire.value) +# endregion -# filesystem permissions customizations -def get_adls_item_acl(account_name, - path): - client = cf_dls_filesystem(account_name) +# region filesystem permissions +def get_adls_item_acl(cmd, account_name, path): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) return client.get_acl_status(path) -def remove_adls_item_acl(account_name, - path, - default_acl=False): - client = cf_dls_filesystem(account_name) +def remove_adls_item_acl(cmd, account_name, path, default_acl=False): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) if default_acl: client.remove_default_acl(path) else: client.remove_acl(path) -def remove_adls_item_acl_entry(account_name, - path, - acl_spec): - client = cf_dls_filesystem(account_name) +def remove_adls_item_acl_entry(cmd, account_name, path, acl_spec): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) client.remove_acl_entries(path, acl_spec) -def set_adls_item_acl(account_name, - path, - acl_spec): - client = cf_dls_filesystem(account_name) +def set_adls_item_acl(cmd, account_name, path, acl_spec): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) client.set_acl(path, acl_spec) -def set_adls_item_acl_entry(account_name, - path, - acl_spec): - client = cf_dls_filesystem(account_name) +def set_adls_item_acl_entry(cmd, account_name, path, acl_spec): + client = cf_dls_filesystem(cmd.cli_ctx, account_name) client.modify_acl_entries(path, acl_spec) -def set_adls_item_owner(account_name, - path, - owner=None, - group=None): - cf_dls_filesystem(account_name).chown(path, owner, group) +def set_adls_item_owner(cmd, account_name, path, owner=None, group=None): + cf_dls_filesystem(cmd.cli_ctx, account_name).chown(path, owner, group) -def set_adls_item_permissions(account_name, - path, - permission): - cf_dls_filesystem(account_name).chmod(path, permission) +def set_adls_item_permissions(cmd, account_name, path, permission): + cf_dls_filesystem(cmd.cli_ctx, account_name).chmod(path, permission) +# endregion # helpers -def _get_resource_group_location(resource_group_name): - client = get_mgmt_service_client(ResourceType.MGMT_RESOURCE_RESOURCES) +def _get_resource_group_location(cli_ctx, resource_group_name): + client = get_mgmt_service_client(cli_ctx, ResourceType.MGMT_RESOURCE_RESOURCES) # pylint: disable=no-member return client.resource_groups.get(resource_group_name).location diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_account_mgmt.yaml b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_account_mgmt.yaml index 44858153754..aad66f4f0df 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_account_mgmt.yaml +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_account_mgmt.yaml @@ -1,818 +1,870 @@ interactions: - request: - body: '{"location": "eastus2", "identity": {"type": "SystemAssigned"}, "properties": - {"encryptionConfig": {"type": "ServiceManaged"}}}' + body: '{"location": "westus", "tags": {"use": "az-test"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] + Connection: [keep-alive] + Content-Length: ['50'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_mgmt000001?api-version=2017-05-10 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001","name":"cli_test_adls_mgmt000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:56:06 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1186'] + status: {code: 201, message: Created} +- request: + body: '{"properties": {"encryptionConfig": {"type": "ServiceManaged"}}, "identity": + {"type": "SystemAssigned"}, "location": "eastus2"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] Content-Length: ['127'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [7ab42446-bf72-11e7-8c84-705a0f2f3d93] method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"properties":{"encryptionConfig":{"type":"ServiceManaged"},"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"00000000-0000-0000-0000-000000000000","tenantId":"00000000-0000-0000-0000-000000000000"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Azure-AsyncOperation: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/8937bc26-64d8-43fa-bdf9-e0ed5147ac400?api-version=2016-11-01&expanded=true'] - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['556'] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:06:51 GMT'] - Expires: ['-1'] - Location: ['https://management.azure.com/subscriptions/04319d6d-4a66-4701-bb2f-e7dbbd9ae4db/resourcegroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/operationresults/0?api-version=2016-11-01'] - Pragma: [no-cache] - Retry-After: ['10'] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + body: {string: '{"properties":{"encryptionConfig":{"type":"ServiceManaged"},"provisioningState":"Creating","state":null,"endpoint":null,"accountId":"94709172-6b53-4a4b-8925-05c83d135431"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"00000000-0000-0000-0000-000000000000","tenantId":"00000000-0000-0000-0000-000000000000"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/94709172-6b53-4a4b-8925-05c83d1354310?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['627'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:11 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1186'] + x-powered-by: [ASP.NET] status: {code: 201, message: Created} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [7ab42446-bf72-11e7-8c84-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/8937bc26-64d8-43fa-bdf9-e0ed5147ac400?api-version=2016-11-01&expanded=true + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/94709172-6b53-4a4b-8925-05c83d1354310?api-version=2016-11-01&expanded=true response: body: {string: '{"status":"InProgress"}'} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:03 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] + cache-control: [no-cache] + connection: [close] content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:22 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [7ab42446-bf72-11e7-8c84-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/8937bc26-64d8-43fa-bdf9-e0ed5147ac400?api-version=2016-11-01&expanded=true + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/94709172-6b53-4a4b-8925-05c83d1354310?api-version=2016-11-01&expanded=true response: body: {string: '{"status":"Succeeded"}'} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:35 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] + cache-control: [no-cache] + connection: [close] content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:53 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [7ab42446-bf72-11e7-8c84-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:06:55.9232471Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"54b824fa-e58c-4634-890f-e4f117585367","tenantId":"72f988bf-86f1-41af-91ab-2d7cd011db47"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:37 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['938'] + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:14.8395384Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"bebd8284-9611-41b3-84f4-6d5690d1939f","tenantId":"54826b22-38d6-4fb2-bad9-b7b93a3e9c5a"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1019'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:53 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [99cd62b8-bf72-11e7-aa45-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:06:55.9232471Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"54b824fa-e58c-4634-890f-e4f117585367","tenantId":"72f988bf-86f1-41af-91ab-2d7cd011db47"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:39 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['938'] + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:14.8395384Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"bebd8284-9611-41b3-84f4-6d5690d1939f","tenantId":"54826b22-38d6-4fb2-bad9-b7b93a3e9c5a"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1019'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account enable-key-vault] Connection: [keep-alive] Content-Length: ['0'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [9ac766e6-bf72-11e7-a7d9-705a0f2f3d93] method: POST - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/enableKeyVault?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/enableKeyVault?api-version=2016-11-01 response: body: {string: '{"error":{"code":"InvalidOperation","message":"Operation EnableKeyVault is invalid under current encryption state or config of account."}}'} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['138'] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:41 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + cache-control: [no-cache] + connection: [close] + content-length: ['138'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:56 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1179'] + x-powered-by: [ASP.NET] status: {code: 400, message: Bad Request} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [9be86946-bf72-11e7-ab90-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts?api-version=2016-11-01 response: - body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:06:55.9232471Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:43 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['519'] + body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:14.8395384Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}]}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['600'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:56 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [9d8df782-bf72-11e7-ad7a-705a0f2f3d93] method: GET uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/accounts?api-version=2016-11-01 response: - body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"begoldsmadls01.azuredatalakestore.net","accountId":"94f4bf5d-78a9-4c31-8aa7-b34d07bad898","creationTime":"2017-03-29T21:49:35.189795Z","lastModifiedTime":"2017-03-29T21:49:35.189795Z"},"location":"eastus2","tags":{},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/begoldsmadlsrg01/providers/Microsoft.DataLakeStore/accounts/begoldsmadls01","name":"begoldsmadls01","type":"Microsoft.DataLakeStore/accounts"},{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:06:55.9232471Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"},{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"testadlfs13789.azuredatalakestore.net","accountId":"d201031c-a8f5-4f9f-ae3f-dfca8e8a98c1","creationTime":"2017-11-01T01:46:40.2101066Z","lastModifiedTime":"2017-11-01T01:46:40.2101066Z"},"location":"East - US 2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/datalakerg19721/providers/Microsoft.DataLakeStore/accounts/testadlfs13789","name":"testadlfs13789","type":"Microsoft.DataLakeStore/accounts"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:46 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['1528'] + body: {string: '{"value":[{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:14.8395384Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"},{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"cliadlsvk3ufoduu37wqxr54.azuredatalakestore.net","accountId":"7a8176da-b84c-4479-a06b-8f7153d0cdaf","creationTime":"2017-12-13T21:37:32.696605Z","lastModifiedTime":"2017-12-13T21:37:32.696605Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_fileqem6kslkkanvmy2ct7qn4jx2abejfhlcuhvckuqd5px3jg3vkv3tbknvd/providers/Microsoft.DataLakeStore/accounts/cliadlsvk3ufoduu37wqxr54","name":"cliadlsvk3ufoduu37wqxr54","type":"Microsoft.DataLakeStore/accounts"},{"properties":{"provisioningState":"Succeeded","state":"Active","endpoint":"dls1.azuredatalakestore.net","accountId":"b6a7242c-d0c0-4516-a264-96b62f03a919","creationTime":"2017-12-13T21:03:12.9488024Z","lastModifiedTime":"2017-12-13T21:03:12.9488024Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/tjp-dls/providers/Microsoft.DataLakeStore/accounts/dls1","name":"dls1","type":"Microsoft.DataLakeStore/accounts"}]}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1648'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: '{"properties": {"firewallState": "Enabled", "trustedIdProviderState": "Enabled"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account update] Connection: [keep-alive] Content-Length: ['81'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [9ea8ab7a-bf72-11e7-be63-705a0f2f3d93] method: PATCH - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Enabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:07:48.0745896Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"54b824fa-e58c-4634-890f-e4f117585367","tenantId":"72f988bf-86f1-41af-91ab-2d7cd011db47"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:48 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['936'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Enabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:59.3076703Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"bebd8284-9611-41b3-84f4-6d5690d1939f","tenantId":"54826b22-38d6-4fb2-bad9-b7b93a3e9c5a"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1017'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:58 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1182'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [9fbce04a-bf72-11e7-a5f7-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Enabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls1234510.azuredatalakestore.net","accountId":"8937bc26-64d8-43fa-bdf9-e0ed5147ac40","creationTime":"2017-11-02T02:06:55.9232471Z","lastModifiedTime":"2017-11-02T02:07:48.0745896Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"54b824fa-e58c-4634-890f-e4f117585367","tenantId":"72f988bf-86f1-41af-91ab-2d7cd011db47"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510","name":"cliadls1234510","type":"Microsoft.DataLakeStore/accounts"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:49 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['936'] + body: {string: '{"properties":{"firewallState":"Enabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Enabled","trustedIdProviders":[],"encryptionState":"Enabled","encryptionConfig":{"type":"ServiceManaged"},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"94709172-6b53-4a4b-8925-05c83d135431","creationTime":"2017-12-13T21:56:14.8395384Z","lastModifiedTime":"2017-12-13T21:56:59.3076703Z"},"location":"eastus2","identity":{"type":"SystemAssigned","principalId":"bebd8284-9611-41b3-84f4-6d5690d1939f","tenantId":"54826b22-38d6-4fb2-bad9-b7b93a3e9c5a"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['1017'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:56:59 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: '{"properties": {"startIpAddress": "127.0.0.1", "endIpAddress": "127.0.0.2"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall create] Connection: [keep-alive] Content-Length: ['76'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a0c17b64-bf72-11e7-8d8f-705a0f2f3d93] method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01?api-version=2016-11-01 response: - body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.2"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:51 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['346'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.2"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['407'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:01 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1187'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a1e4c494-bf72-11e7-8420-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01?api-version=2016-11-01 response: - body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.2"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:53 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['346'] + body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.2"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['407'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:02 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: '{"properties": {"endIpAddress": "127.0.0.3"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall update] Connection: [keep-alive] Content-Length: ['45'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a2f7e91e-bf72-11e7-9947-705a0f2f3d93] method: PATCH - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01?api-version=2016-11-01 response: - body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:55 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['346'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['407'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:04 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1184'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a3fc7f2e-bf72-11e7-aed3-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01?api-version=2016-11-01 response: - body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:56 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['346'] + body: {string: '{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['407'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:05 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a4f83d0c-bf72-11e7-9c24-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules?api-version=2016-11-01 response: - body: {string: '{"value":[{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:07:59 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['358'] + body: {string: '{"value":[{"properties":{"startIpAddress":"127.0.0.1","endIpAddress":"127.0.0.3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01","name":"testfirewallrule01","type":"Microsoft.DataLakeStore/accounts/firewallRules"}]}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['419'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:06 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall delete] Connection: [keep-alive] Content-Length: ['0'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a60f0ca4-bf72-11e7-b5b6-705a0f2f3d93] method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules/testfirewallrule01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules/testfirewallrule01?api-version=2016-11-01 response: body: {string: ''} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 02:08:00 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + cache-control: [no-cache] + connection: [close] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:57:07 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-ms-ratelimit-remaining-subscription-writes: ['1187'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account firewall list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a7144774-bf72-11e7-9a4a-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/firewallRules?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/firewallRules?api-version=2016-11-01 response: body: {string: '{"value":[]}'} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] + cache-control: [no-cache] + connection: [close] content-length: ['12'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:08 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: '{"properties": {"idProvider": "https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider create] Connection: [keep-alive] Content-Length: ['94'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a8123b38-bf72-11e7-ac95-705a0f2f3d93] method: PUT - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01?api-version=2016-11-01 response: - body: {string: '{"properties":{"idProvider":"https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:04 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['368'] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + body: {string: '{"properties":{"idProvider":"https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['429'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:10 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1181'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [a990ab86-bf72-11e7-a927-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01?api-version=2016-11-01 response: - body: {string: '{"properties":{"idProvider":"https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:06 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['368'] + body: {string: '{"properties":{"idProvider":"https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['429'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:10 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: '{"properties": {"idProvider": "https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"}}' headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider update] Connection: [keep-alive] Content-Length: ['94'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [aa90ebc2-bf72-11e7-836c-705a0f2f3d93] method: PATCH - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01?api-version=2016-11-01 response: - body: {string: '{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:07 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['368'] - x-ms-ratelimit-remaining-subscription-writes: ['1198'] + body: {string: '{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['429'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:12 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1178'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider show] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [aba08d7e-bf72-11e7-9d5a-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01?api-version=2016-11-01 response: - body: {string: '{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:09 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['368'] + body: {string: '{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['429'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:13 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [aca75ac2-bf72-11e7-bd2b-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders?api-version=2016-11-01 response: - body: {string: '{"value":[{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}]}'} - headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:12 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] - content-length: ['380'] + body: {string: '{"value":[{"properties":{"idProvider":"https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3"},"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01","name":"testprovider01","type":"Microsoft.DataLakeStore/accounts/trustedIdProviders"}]}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['441'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:13 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider delete] Connection: [keep-alive] Content-Length: ['0'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [ae070a90-bf72-11e7-b001-705a0f2f3d93] method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders/testprovider01?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders/testprovider01?api-version=2016-11-01 response: body: {string: ''} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 02:08:13 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + cache-control: [no-cache] + connection: [close] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:57:15 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-ms-ratelimit-remaining-subscription-writes: ['1186'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account trusted-provider list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [af82686c-bf72-11e7-b1fa-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510/trustedIdProviders?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/trustedIdProviders?api-version=2016-11-01 response: body: {string: '{"value":[]}'} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Type: [application/json] - Date: ['Thu, 02 Nov 2017 02:08:16 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] - X-AspNet-Version: [4.0.30319] - X-Content-Type-Options: [nosniff] - X-Powered-By: [ASP.NET] + cache-control: [no-cache] + connection: [close] content-length: ['12'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:57:16 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account delete] Connection: [keep-alive] Content-Length: ['0'] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [b08bdc64-bf72-11e7-8de1-705a0f2f3d93] method: DELETE - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts/cliadls1234510?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: body: {string: ''} headers: - Cache-Control: [no-cache] - Connection: [close] - Content-Length: ['0'] - Date: ['Thu, 02 Nov 2017 02:08:19 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Server: [Microsoft-IIS/8.5] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - X-AspNet-Version: [4.0.30319] - X-Powered-By: [ASP.NET] - x-ms-ratelimit-remaining-subscription-writes: ['1199'] + cache-control: [no-cache] + connection: [close] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:57:20 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-ms-ratelimit-remaining-subscription-writes: ['1186'] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account list] Connection: [keep-alive] Content-Type: [application/json; charset=utf-8] - User-Agent: [python/3.6.2rc1 (Windows-10-10.0.15063-SP0) requests/2.18.4 msrest/0.4.18 - msrest_azure/0.4.15 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python - AZURECLI/TEST/2.0.20] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] accept-language: [en-US] - x-ms-client-request-id: [b2c17ab6-bf72-11e7-acb0-705a0f2f3d93] method: GET - uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli-test-adls-mgmt/providers/Microsoft.DataLakeStore/accounts?api-version=2016-11-01 + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_mgmt000001/providers/Microsoft.DataLakeStore/accounts?api-version=2016-11-01 response: body: {string: '{"value":[]}'} headers: - Cache-Control: [no-cache] - Content-Type: [application/json; charset=utf-8] - Date: ['Thu, 02 Nov 2017 02:08:21 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Strict-Transport-Security: [max-age=31536000; includeSubDomains] - Vary: [Accept-Encoding] + cache-control: [no-cache] content-length: ['12'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:57:20 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group delete] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: DELETE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_mgmt000001?api-version=2017-05-10 + response: + body: {string: ''} + headers: + cache-control: [no-cache] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:57:21 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/operationresults/eyJqb2JJZCI6IlJFU09VUkNFR1JPVVBERUxFVElPTkpPQi1DTEk6NUZURVNUOjVGQURMUzo1Rk1HTVRGNkpVRk1aRjNFQkFVRjZWNkVIVlBHRHxBM0ZEODFFRUVBNThDM0NGLVdFU1RVUyIsImpvYkxvY2F0aW9uIjoid2VzdHVzIn0?api-version=2017-05-10'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1185'] + status: {code: 202, message: Accepted} version: 1 diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_access_mgmt.yaml b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_access_mgmt.yaml index d87d8f2d844..bf75849d9dd 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_access_mgmt.yaml +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_access_mgmt.yaml @@ -1,28 +1,212 @@ interactions: +- request: + body: '{"tags": {"use": "az-test"}, "location": "westus"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] + Connection: [keep-alive] + Content-Length: ['50'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_access000001?api-version=2017-05-10 + response: + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001","name":"cli_test_adls_access000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:31:12 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1188'] + status: {code: 201, message: Created} +- request: + body: '{"properties": {"encryptionState": "Disabled"}, "location": "eastus2"}' + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Length: ['70'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: PUT + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"935589e5-32cc-400d-b248-10ffc631abe8"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/935589e5-32cc-400d-b248-10ffc631abe80?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['471'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:31:15 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1187'] + x-powered-by: [ASP.NET] + status: {code: 201, message: Created} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/935589e5-32cc-400d-b248-10ffc631abe80?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:31:25 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/935589e5-32cc-400d-b248-10ffc631abe80?api-version=2016-11-01&expanded=true + response: + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:31:56 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"935589e5-32cc-400d-b248-10ffc631abe8","creationTime":"2017-12-13T21:31:16.8484867Z","lastModifiedTime":"2017-12-13T21:31:16.8484867Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:31:56 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account show] + Connection: [keep-alive] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 + response: + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"935589e5-32cc-400d-b248-10ffc631abe8","creationTime":"2017-12-13T21:31:16.8484867Z","lastModifiedTime":"2017-12-13T21:31:16.8484867Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cli_test_adls_access000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Wed, 13 Dec 2017 21:31:58 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] + status: {code: 200, message: OK} - request: body: null headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [c935718c-55e4-11e7-9767-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=GETFILESTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01 [5ebf126f-ca20-48ae-a6bb-c5aef5bfc78a][2017-06-20T11:17:59.3145035-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['236'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:17:58 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + does not exist: /adltestfolder01 [1e7a0e1f-bb35-4c79-9314-139704fd745e][2017-12-13T13:31:59.4072779-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['236'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:31:58 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 404, message: Not Found} - request: @@ -32,23 +216,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [ca531d5c-55e4-11e7-b268-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MKDIRS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MKDIRS response: body: {string: '{"boolean":true}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:17:58 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['16'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:31:58 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -57,23 +240,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [ca676e64-55e4-11e7-abb3-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=GETFILESTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1497982679418,"modificationTime":1497982679418,"replication":0,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:17:59 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1513200719527,"modificationTime":1513200719527,"replication":0,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['280'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:31:59 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -83,22 +265,21 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [caa37986-55e4-11e7-85f0-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?owner=6361e05d-c381-4275-a932-5535806bb323&OP=SETOWNER&group=80a3ed5f-959e-4696-ba3c-d3c8b2db6766&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?owner=6361e05d-c381-4275-a932-5535806bb323&api-version=2016-11-01&OP=SETOWNER&group=80a3ed5f-959e-4696-ba3c-d3c8b2db6766 response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 18:17:59 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:32:00 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -107,23 +288,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cae0fdda-55e4-11e7-96b4-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=GETFILESTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1497982679418,"modificationTime":1497982679418,"replication":0,"permission":"770","owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:17:59 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1513200719527,"modificationTime":1513200719527,"replication":0,"permission":"770","owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['280'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:00 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -133,22 +313,21 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cb1b78da-55e4-11e7-a93b-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=SETPERMISSION&permission=777&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&permission=777&OP=SETPERMISSION response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:00 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:32:01 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -157,23 +336,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cb5844c6-55e4-11e7-aa53-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=GETFILESTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1497982679418,"modificationTime":1497982679418,"replication":0,"permission":"777","owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1513200719527,"modificationTime":1513200719527,"replication":0,"permission":"777","owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['280'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:01 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -182,23 +360,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cc5c519a-55e4-11e7-b220-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","group::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['196'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:03 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['196'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:02 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -208,23 +385,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [ccc6d3a2-55e4-11e7-b06b-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=SETACL&aclSpec=user%3A%3Arwx%2Cgroup%3A%3Arwx%2Cother%3A%3Arwx%2Cuser%3A470c0ccf-c91a-4597-98cd-48507d2f1486%3Arwx&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&aclSpec=user%3A%3Arwx%2Cgroup%3A%3Arwx%2Cother%3A%3Arwx%2Cuser%3A470c0ccf-c91a-4597-98cd-48507d2f1486%3Arwx&OP=SETACL response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:03 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Wed, 13 Dec 2017 21:32:02 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -233,23 +409,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cd26db52-55e4-11e7-9610-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","user:470c0ccf-c91a-4597-98cd-48507d2f1486:rwx","group::rwx","mask::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['256'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:04 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['256'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:03 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -259,23 +434,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cd828b98-55e4-11e7-80c9-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MODIFYACLENTRIES&aclSpec=user%3A470c0ccf-c91a-4597-98cd-48507d2f1486%3A-w-&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&aclSpec=user%3A470c0ccf-c91a-4597-98cd-48507d2f1486%3A-w-&OP=MODIFYACLENTRIES response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Wed, 13 Dec 2017 21:32:04 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -284,23 +458,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cdecd4a6-55e4-11e7-b602-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","user:470c0ccf-c91a-4597-98cd-48507d2f1486:-w-","group::rwx","mask::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['256'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['256'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:04 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -310,23 +483,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [ce4e90f4-55e4-11e7-ac36-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=REMOVEACLENTRIES&aclSpec=user%3A470c0ccf-c91a-4597-98cd-48507d2f1486&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&aclSpec=user%3A470c0ccf-c91a-4597-98cd-48507d2f1486&OP=REMOVEACLENTRIES response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:06 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Wed, 13 Dec 2017 21:32:05 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -335,23 +507,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cead6658-55e4-11e7-9442-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","group::rwx","mask::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['208'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:06 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['208'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:06 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -361,23 +532,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cf0d87c8-55e4-11e7-a963-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=REMOVEDEFAULTACL&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=REMOVEDEFAULTACL response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:07 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Wed, 13 Dec 2017 21:32:06 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -386,23 +556,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cf8ba588-55e4-11e7-9bf7-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","group::rwx","mask::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['208'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:08 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['208'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:06 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -412,23 +581,22 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [cfc6d912-55e4-11e7-b189-645106422854] method: PUT - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=REMOVEACL&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=REMOVEACL response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 18:18:09 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Wed, 13 Dec 2017 21:32:07 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -437,23 +605,49 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.11 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [d03eb412-55e4-11e7-a0be-645106422854] method: GET - uri: https://cliadls123426.azuredatalakestore.net/webhdfs/v1/adltestfolder01?OP=MSGETACLSTATUS&api-version=2016-11-01 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MSGETACLSTATUS response: body: {string: '{"AclStatus":{"entries":["user::rwx","group::rwx","other::rwx"],"owner":"6361e05d-c381-4275-a932-5535806bb323","group":"80a3ed5f-959e-4696-ba3c-d3c8b2db6766","permission":"777","stickyBit":false}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['196'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 18:18:09 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['196'] + content-type: [application/json; charset=utf-8] + date: ['Wed, 13 Dec 2017 21:32:07 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} +- request: + body: null + headers: + Accept: [application/json] + Accept-Encoding: ['gzip, deflate'] + CommandName: [group delete] + Connection: [keep-alive] + Content-Length: ['0'] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: DELETE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cli_test_adls_access000001?api-version=2017-05-10 + response: + body: {string: ''} + headers: + cache-control: [no-cache] + content-length: ['0'] + date: ['Wed, 13 Dec 2017 21:32:08 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/operationresults/eyJqb2JJZCI6IlJFU09VUkNFR1JPVVBERUxFVElPTkpPQi1DTEk6NUZURVNUOjVGQURMUzo1RkFDQ0VTUzRKNVA3SFpXSkRBVFZXQTVVTVEyWXw4REJEQjc2QjNEQUY2QzhGLVdFU1RVUyIsImpvYkxvY2F0aW9uIjoid2VzdHVzIn0?api-version=2017-05-10'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1189'] + status: {code: 202, message: Accepted} version: 1 diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_mgmt.yaml b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_mgmt.yaml index 5f1752fe3d7..d07ae0bb6aa 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_mgmt.yaml +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/recordings/latest/test_dls_file_mgmt.yaml @@ -1,257 +1,188 @@ interactions: - request: - body: null + body: '{"tags": {"use": "az-test"}, "location": "westus"}' headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [group create] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [018157e2-560e-11e7-b3a1-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01 [c54f96a2-96c5-4fb6-97e8-b505e9da5973][2017-06-20T16:13:02.2441383-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['236'] + Content-Length: ['50'] Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [021a3cc0-560e-11e7-bf45-645106422854] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 resourcemanagementclient/1.2.1 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MKDIRS + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cls_test_adls_file000001?api-version=2017-05-10 response: - body: {string: '{"boolean":true}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:01 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [022d63dc-560e-11e7-9d33-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1498000382360,"modificationTime":1498000382360,"replication":0,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:02 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [02b4d480-560e-11e7-98d7-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01/adltestfile01 [405e15fb-12b8-4ad5-8ef3-151baed1c9d9][2017-06-20T16:13:04.1234375-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['250'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:04 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} + body: {string: '{"id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001","name":"cls_test_adls_file000001","location":"westus","tags":{"use":"az-test"},"properties":{"provisioningState":"Succeeded"}}'} + headers: + cache-control: [no-cache] + content-length: ['328'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:57:48 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + status: {code: 201, message: Created} - request: - body: null + body: '{"properties": {"encryptionState": "Disabled"}, "location": "eastus2"}' headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0338c324-560e-11e7-bd4f-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01/adltestfile01 [4c2ed0de-b090-47c9-9461-c5e49758cb1a][2017-06-20T16:13:04.2484413-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['250'] + Content-Length: ['70'] Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:04 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} -- request: - body: '123456' - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['6'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [034aff3a-560e-11e7-9076-645106422854] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: ''} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:04 GMT'] - Expires: ['-1'] - Location: ['https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + body: {string: '{"properties":{"encryptionState":"Disabled","provisioningState":"Creating","state":null,"endpoint":null,"accountId":"5c86c7c8-1237-41fe-baa0-d1701aac7351"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + azure-asyncoperation: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/5c86c7c8-1237-41fe-baa0-d1701aac73510?api-version=2016-11-01&expanded=true'] + cache-control: [no-cache] + connection: [close] + content-length: ['471'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:57:52 GMT'] + expires: ['-1'] + location: ['https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002/operationresults/0?api-version=2016-11-01'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-ms-ratelimit-remaining-subscription-writes: ['1199'] + x-powered-by: [ASP.NET] status: {code: 201, message: Created} - request: body: null headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [03723612-560e-11e7-ab5f-645106422854] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/5c86c7c8-1237-41fe-baa0-d1701aac73510?api-version=2016-11-01&expanded=true response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:04 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + body: {string: '{"status":"InProgress"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['23'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:58:02 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [03adb86e-560e-11e7-a1c6-645106422854] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DataLakeStore/locations/eastus2/operationResults/5c86c7c8-1237-41fe-baa0-d1701aac73510?api-version=2016-11-01&expanded=true response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + body: {string: '{"status":"Succeeded"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['22'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:58:33 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account create] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [041f5878-560e-11e7-bd74-645106422854] - method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfsext/adltestfolder01/adltestfile01?api-version=2016-11-01&expireTime=1896091200000&expiryOption=Absolute&OP=SETEXPIRY + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] + method: GET + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: ''} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"5c86c7c8-1237-41fe-baa0-d1701aac7351","creationTime":"2017-12-14T17:57:53.2885965Z","lastModifiedTime":"2017-12-14T17:57:53.2885965Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:58:34 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null headers: - Accept: ['*/*'] + Accept: [application/json] Accept-Encoding: ['gzip, deflate'] + CommandName: [dls account show] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0440888c-560e-11e7-a11b-645106422854] + Content-Type: [application/json; charset=utf-8] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) requests/2.18.4 msrest/0.4.19 + msrest_azure/0.4.17 datalakestoreaccountmanagementclient/0.2.0 Azure-SDK-For-Python + AZURECLI/2.0.22] + accept-language: [en-US] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002?api-version=2016-11-01 response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":1896091200015,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['316'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:05 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + body: {string: '{"properties":{"firewallState":"Disabled","firewallAllowAzureIps":"Disabled","firewallRules":[],"virtualNetworkRules":[],"trustedIdProviderState":"Disabled","trustedIdProviders":[],"encryptionState":"Disabled","encryptionConfig":{},"currentTier":"Consumption","newTier":"Consumption","provisioningState":"Succeeded","state":"Active","endpoint":"cliadls000002.azuredatalakestore.net","accountId":"5c86c7c8-1237-41fe-baa0-d1701aac7351","creationTime":"2017-12-14T17:57:53.2885965Z","lastModifiedTime":"2017-12-14T17:57:53.2885965Z"},"location":"eastus2","id":"/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/cls_test_adls_file000001/providers/Microsoft.DataLakeStore/accounts/cliadls000002","name":"cliadls000002","type":"Microsoft.DataLakeStore/accounts"}'} + headers: + cache-control: [no-cache] + connection: [close] + content-length: ['857'] + content-type: [application/json] + date: ['Thu, 14 Dec 2017 17:58:34 GMT'] + expires: ['-1'] + pragma: [no-cache] + server: [Microsoft-IIS/8.5] + strict-transport-security: [max-age=31536000; includeSubDomains] + vary: [Accept-Encoding] + x-aspnet-version: [4.0.30319] + x-content-type-options: [nosniff] + x-powered-by: [ASP.NET] status: {code: 200, message: OK} - request: body: null @@ -259,25 +190,25 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [04805210-560e-11e7-bb0f-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":1896091200015,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['316'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:06 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder + does not exist: /adltestfolder01 [cce7f86c-4008-4ac4-997b-c3291fc52742][2017-12-14T09:58:36.9739612-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['236'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:36 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} + status: {code: 404, message: Not Found} - request: body: null headers: @@ -285,21 +216,23 @@ interactions: Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0500d574-560e-11e7-93eb-645106422854] method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfsext/adltestfolder01/adltestfile01?api-version=2016-11-01&expiryOption=NeverExpire&OP=SETEXPIRY + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=MKDIRS response: - body: {string: ''} + body: {string: '{"boolean":true}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:06 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['16'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:36 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] + x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: body: null @@ -307,23 +240,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [051e7400-560e-11e7-9625-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:07 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1513274317147,"modificationTime":1513274317147,"replication":0,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['280'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:38 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -332,24 +264,23 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [05b7c53a-560e-11e7-8a48-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder02 [c4cccff2-bafc-4797-9a00-f13157f498af][2017-06-20T16:13:09.7824758-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['236'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:09 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + does not exist: /adltestfolder01/adltestfile01 [4953ff24-3b50-41c4-88ad-b07b7b611c81][2017-12-14T09:58:39.5582761-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['250'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:38 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 404, message: Not Found} - request: @@ -358,75 +289,73 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0697fde6-560e-11e7-a3d5-645106422854] - method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=MKDIRS + method: GET + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"boolean":true}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:10 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder + does not exist: /adltestfolder01/adltestfile01 [6f96939c-9ccc-49c6-86c9-7c263a94e3ef][2017-12-14T09:58:39.6676514-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['250'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:38 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} + status: {code: 404, message: Not Found} - request: - body: null + body: '123456' headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['6'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [079e17c2-560e-11e7-8e0d-645106422854] method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&destination=adltestfolder02%2Fadltestfile01&OP=RENAME + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?write=true&overwrite=true&api-version=2016-11-01&OP=CREATE&leaseid=03c6e285-f876-402c-b1ec-50e2c7c34d57&filesessionid=03c6e285-f876-402c-b1ec-50e2c7c34d57&syncFlag=CLOSE response: - body: {string: '{"boolean":true}'} + body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:10 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Thu, 14 Dec 2017 17:58:39 GMT'] + expires: ['-1'] + location: ['https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?write=true&overwrite=true&api-version=2016-11-01&OP=CREATE&leaseid=03c6e285-f876-402c-b1ec-50e2c7c34d57&filesessionid=03c6e285-f876-402c-b1ec-50e2c7c34d57&syncFlag=CLOSE'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} + status: {code: 201, message: Created} - request: body: null headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [07df67a2-560e-11e7-9242-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:11 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:40 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -435,23 +364,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [081be88c-560e-11e7-82cb-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:12 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:42 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -460,24 +388,21 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['0'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0854f92e-560e-11e7-92cd-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + method: PUT + uri: https://cliadls000002.azuredatalakestore.net/webhdfsext/adltestfolder01/adltestfile01?expiryOption=Absolute&api-version=2016-11-01&OP=SETEXPIRY&expireTime=1896091200000 response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} + body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:12 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + date: ['Thu, 14 Dec 2017 17:58:42 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] status: {code: 200, message: OK} - request: body: null @@ -485,23 +410,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0865ae8a-560e-11e7-a945-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:12 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":1896091200000,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['316'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:43 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -510,23 +434,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [08763dc6-560e-11e7-8f71-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:12 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":1896091200000,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['316'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:44 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -535,24 +458,21 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['0'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0886b79c-560e-11e7-98de-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + method: PUT + uri: https://cliadls000002.azuredatalakestore.net/webhdfsext/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=SETEXPIRY&expiryOption=NeverExpire response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} + body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:13 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + date: ['Thu, 14 Dec 2017 17:58:44 GMT'] + expires: ['-1'] + pragma: [no-cache] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] status: {code: 200, message: OK} - request: body: null @@ -560,23 +480,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [08f42040-560e-11e7-9674-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?offset=0&api-version=2016-11-01&read=true&OP=OPEN&length=6 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '123456'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Type: [application/octet-stream] - Date: ['Tue, 20 Jun 2017 23:13:13 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:46 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -585,48 +504,48 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [090c3c0c-560e-11e7-a865-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:14 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder + does not exist: /adltestfolder02 [7f5b77a6-0c0d-472b-96a2-8e835945cdc1][2017-12-14T09:58:47.7204829-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['236'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:47 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} + status: {code: 404, message: Not Found} - request: body: null headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['0'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [09936c92-560e-11e7-af01-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + method: PUT + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=MKDIRS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} + body: {string: '{"boolean":true}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:16 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['16'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:47 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -635,23 +554,23 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['0'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0ac276d4-560e-11e7-b0d7-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + method: PUT + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile01?destination=adltestfolder02%2Fadltestfile01&api-version=2016-11-01&OP=RENAME response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} + body: {string: '{"boolean":true}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:16 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['16'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:49 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -660,23 +579,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0ad2f25e-560e-11e7-942e-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:16 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:50 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -685,23 +603,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0ae39352-560e-11e7-967b-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?offset=3&api-version=2016-11-01&read=true&OP=OPEN&length=3 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '456'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Type: [application/octet-stream] - Date: ['Tue, 20 Jun 2017 23:13:17 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -710,23 +627,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0b6f8090-560e-11e7-b8e6-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=LISTSTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatuses":{"FileStatus":[{"length":6,"pathSuffix":"adltestfile01","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}]}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['336'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:18 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -735,23 +651,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0c17ba10-560e-11e7-9546-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:19 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -760,23 +675,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0ca9e7ec-560e-11e7-9b22-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:20 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -785,23 +699,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0d35246c-560e-11e7-b0bb-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:21 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:52 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -810,48 +723,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0db996da-560e-11e7-92fd-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&filesessionid=d3a154df-77a5-4af3-8ba8-ec96e605eae5&OP=OPEN&read=true&offset=0&length=6 response: - body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000384410,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['304'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:21 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: '123456' - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['6'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0e287288-560e-11e7-9968-645106422854] - method: POST - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?offset=6&api-version=2016-11-01&append=true&OP=APPEND - response: - body: {string: ''} + body: {string: '123456'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:22 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-type: [application/octet-stream] + date: ['Thu, 14 Dec 2017 17:58:53 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -860,23 +747,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0eae08c8-560e-11e7-bf49-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":12,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000384371,"modificationTime":1498000403269,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['305'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:23 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -885,49 +771,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0f4b980a-560e-11e7-94dd-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01/adltestfile02 [8c738b6c-2035-498e-8d5d-41751ca6f56a][2017-06-20T16:13:25.3154124-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['250'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:25 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0fd99470-560e-11e7-9836-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=LISTSTATUS - response: - body: {string: '{"FileStatuses":{"FileStatus":[]}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['34'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:25 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -936,101 +795,46 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [0feaaab8-560e-11e7-a35f-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder01/adltestfile02 [4b28cef2-2087-475b-adae-6064fcd1c607][2017-06-20T16:13:25.7980049-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['250'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:24 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} -- request: - body: Local File Content - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['18'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [10231f9e-560e-11e7-bb3c-645106422854] - method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE - response: - body: {string: ''} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:25 GMT'] - Expires: ['-1'] - Location: ['https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 201, message: Created} + status: {code: 200, message: OK} - request: body: null headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1059d486-560e-11e7-b877-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"FileStatus":{"length":18,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000405924,"modificationTime":1498000405966,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['305'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:25 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: sources=adltestfolder01/adltestfile02,adltestfolder02/adltestfile01 - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['67'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [109877ee-560e-11e7-8cbe-645106422854] - method: POST - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?api-version=2016-11-01&OP=MSCONCAT&deleteSourceDirectory=false + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: ''} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:27 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1039,23 +843,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [119c2d0c-560e-11e7-8672-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&filesessionid=d70bb5dc-1ab9-4dd3-850d-38176e4f783a&OP=OPEN&read=true&offset=3&length=3 response: - body: {string: '{"FileStatus":{"length":30,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000408082,"modificationTime":1498000408117,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} + body: {string: '456'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['305'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:27 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-type: [application/octet-stream] + date: ['Thu, 14 Dec 2017 17:58:54 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + transfer-encoding: [chunked] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1064,23 +867,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [11d84ff6-560e-11e7-b68d-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=LISTSTATUS response: - body: {string: '{"FileStatus":{"length":30,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000408082,"modificationTime":1498000408117,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['305'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:28 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatuses":{"FileStatus":[{"length":6,"pathSuffix":"adltestfile01","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}]}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['336'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:56 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1089,23 +891,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [12143308-560e-11e7-936e-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?api-version=2016-11-01&OP=LISTSTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatuses":{"FileStatus":[{"length":30,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000408082,"modificationTime":1498000408117,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}]}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['324'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:28 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1114,23 +915,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1226f7da-560e-11e7-bce8-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?offset=0&api-version=2016-11-01&read=true&OP=OPEN&length=30 + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: Local File Content123456123456} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Type: [application/octet-stream] - Date: ['Tue, 20 Jun 2017 23:13:29 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - Transfer-Encoding: [chunked] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1139,23 +939,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [12774ef6-560e-11e7-ab8c-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatus":{"length":30,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1498000408082,"modificationTime":1498000408117,"replication":1,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","msExpirationTime":0,"aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['305'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:30 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1164,49 +963,46 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [13094234-560e-11e7-a082-645106422854] - method: DELETE - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile03?recursive=False&api-version=2016-11-01&OP=DELETE + method: GET + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"boolean":true}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:31 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":6,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274319902,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['304'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: - body: null + body: '123456' headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['6'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [138d52de-560e-11e7-83a4-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=LISTSTATUS + method: POST + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?filesessionid=9b416a38-4069-4657-933f-8669c0d71ec4&api-version=2016-11-01&OP=APPEND&append=true&leaseid=9b416a38-4069-4657-933f-8669c0d71ec4&offset=6&syncFlag=CLOSE response: - body: {string: '{"FileStatuses":{"FileStatus":[]}}'} + body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['34'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:30 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + date: ['Thu, 14 Dec 2017 17:58:57 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1215,23 +1011,22 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [13c52ac6-560e-11e7-851d-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/.?api-version=2016-11-01&OP=LISTSTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder02/adltestfile01?api-version=2016-11-01&OP=GETFILESTATUS response: - body: {string: '{"FileStatuses":{"FileStatus":[{"length":0,"pathSuffix":"adltestfolder01","type":"DIRECTORY","blockSize":0,"accessTime":1498000382360,"modificationTime":1498000411457,"replication":0,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","aclBit":false}]}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['314'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:31 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + body: {string: '{"FileStatus":{"length":12,"pathSuffix":"","type":"FILE","blockSize":268435456,"accessTime":1513274319799,"modificationTime":1513274338338,"replication":1,"permission":"770","owner":"5963f50c-7c43-405c-af7e-53294de76abd","group":"5963f50c-7c43-405c-af7e-53294de76abd","msExpirationTime":0,"aclBit":false}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['305'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:58 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 200, message: OK} - request: @@ -1240,24 +1035,23 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [13dbfb92-560e-11e7-b2f0-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?api-version=2016-11-01&OP=GETFILESTATUS response: body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder02 [d53aa674-6929-4ad8-8868-16ac3d779e8d][2017-06-20T16:13:32.4152124-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['236'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:31 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + does not exist: /adltestfolder01/adltestfile02 [a6f06831-775d-4ca7-bb00-b8a8db29f9cf][2017-12-14T09:59:00.8361890-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['250'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:58:59 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 404, message: Not Found} - request: @@ -1266,205 +1060,73 @@ interactions: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1414aa90-560e-11e7-9b63-645106422854] - method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=MKDIRS - response: - body: {string: '{"boolean":true}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:34 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1585a49e-560e-11e7-83d8-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/tempfile01.txt?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=LISTSTATUS response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder02/tempfile01.txt [ab0ff87e-3a07-411d-bfe4-ea35966a8351][2017-06-20T16:13:35.3821600-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} + body: {string: '{"FileStatuses":{"FileStatus":[]}}'} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['251'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:34 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['34'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:59:00 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} + status: {code: 200, message: OK} - request: body: null headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [15d990da-560e-11e7-8ce3-645106422854] method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/tempfile01.txt?api-version=2016-11-01&OP=GETFILESTATUS + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?api-version=2016-11-01&OP=GETFILESTATUS response: body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder02/tempfile01.txt [81da36fa-f688-4a81-9c70-847a57b16beb][2017-06-20T16:13:35.6321586-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['251'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:34 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + does not exist: /adltestfolder01/adltestfile02 [11db25ff-8a33-4acb-8306-79045bb7a379][2017-12-14T09:59:01.3434330-08:00]","javaClassName":"java.io.FileNotFoundException"}}'} + headers: + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['250'] + content-type: [application/json; charset=utf-8] + date: ['Thu, 14 Dec 2017 17:59:00 GMT'] + expires: ['-1'] + pragma: [no-cache] + status: ['0x8309000A'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 404, message: Not Found} - request: - body: null + body: Local File Content headers: Accept: ['*/*'] Accept-Encoding: ['gzip, deflate'] Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 + Content-Length: ['18'] + User-Agent: [python/3.5.3 (Windows-10-10.0.16299-SP0) azure.datalake.store.lib/0.0.17 Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [15ffb5ec-560e-11e7-8020-645106422854] method: PUT - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/tempfile01.txt?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE + uri: https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?write=true&overwrite=true&api-version=2016-11-01&OP=CREATE&leaseid=ff951c79-fd70-4f3b-bf8a-90c614234940&filesessionid=ff951c79-fd70-4f3b-bf8a-90c614234940&syncFlag=CLOSE response: body: {string: ''} headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['0'] - ContentLength: ['0'] - Date: ['Tue, 20 Jun 2017 23:13:35 GMT'] - Expires: ['-1'] - Location: ['https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02/tempfile01.txt?overwrite=true&api-version=2016-11-01&write=true&OP=CREATE'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] + cache-control: ['no-cache, no-cache, no-store, max-age=0'] + content-length: ['0'] + contentlength: ['0'] + date: ['Thu, 14 Dec 2017 17:59:00 GMT'] + expires: ['-1'] + location: ['https://cliadls000002.azuredatalakestore.net/webhdfs/v1/adltestfolder01/adltestfile02?write=true&overwrite=true&api-version=2016-11-01&OP=CREATE&leaseid=ff951c79-fd70-4f3b-bf8a-90c614234940&filesessionid=ff951c79-fd70-4f3b-bf8a-90c614234940&syncFlag=CLOSE'] + pragma: [no-cache] + status: ['0x0'] + strict-transport-security: [max-age=15724800; includeSubDomains] + x-content-type-options: [nosniff] x-ms-webhdfs-version: [17.04.22.00] status: {code: 201, message: Created} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1619a68c-560e-11e7-8610-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1498000414804,"modificationTime":1498000415782,"replication":0,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:35 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - Content-Length: ['0'] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1651bb14-560e-11e7-8beb-645106422854] - method: DELETE - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?recursive=True&api-version=2016-11-01&OP=DELETE - response: - body: {string: '{"boolean":true}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['16'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:35 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [166e425e-560e-11e7-924f-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder02?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"RemoteException":{"exception":"FileNotFoundException","message":"File/Folder - does not exist: /adltestfolder02 [85dc8dd4-ecac-4e39-bbd2-9c1e22c286b3][2017-06-20T16:13:37.9329555-07:00]","javaClassName":"java.io.FileNotFoundException"}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['236'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:37 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x8309000A'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 404, message: Not Found} -- request: - body: null - headers: - Accept: ['*/*'] - Accept-Encoding: ['gzip, deflate'] - Connection: [keep-alive] - User-Agent: [python/3.5.2 (Windows-10-10.0.15063-SP0) azure.datalake.store.lib/0.0.12 - Azure-Data-Lake-Store-SDK-For-Python] - x-ms-client-request-id: [1762a11c-560e-11e7-97a6-645106422854] - method: GET - uri: https://cliadls123416.azuredatalakestore.net/webhdfs/v1/adltestfolder01?api-version=2016-11-01&OP=GETFILESTATUS - response: - body: {string: '{"FileStatus":{"length":0,"pathSuffix":"","type":"DIRECTORY","blockSize":0,"accessTime":1498000382360,"modificationTime":1498000411457,"replication":0,"permission":"770","owner":"2e6c02d2-a364-4530-9137-d17403996cbf","group":"2e6c02d2-a364-4530-9137-d17403996cbf","aclBit":false}}'} - headers: - Cache-Control: ['no-cache, no-cache, no-store, max-age=0'] - Content-Length: ['280'] - Content-Type: [application/json; charset=utf-8] - Date: ['Tue, 20 Jun 2017 23:13:38 GMT'] - Expires: ['-1'] - Pragma: [no-cache] - Status: ['0x0'] - Strict-Transport-Security: [max-age=15724800; includeSubDomains] - X-Content-Type-Options: [nosniff] - x-ms-webhdfs-version: [17.04.22.00] - status: {code: 200, message: OK} version: 1 diff --git a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/test_dls_commands.py b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/test_dls_commands.py index 661ef3810d5..b16ad3a4806 100644 --- a/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/test_dls_commands.py +++ b/src/command_modules/azure-cli-dls/azure/cli/command_modules/dls/tests/test_dls_commands.py @@ -12,396 +12,384 @@ from shutil import rmtree from msrestazure.azure_exceptions import CloudError +from azure.cli.testsdk import ScenarioTest, ResourceGroupPreparer + from knack.util import CLIError -from azure.cli.testsdk.vcr_test_base import (ResourceGroupVCRTestBase, JMESPathCheck) -class DataLakeStoreFileAccessScenarioTest(ResourceGroupVCRTestBase): +class DataLakeStoreFileAccessScenarioTest(ScenarioTest): - def __init__(self, test_method): - super(DataLakeStoreFileAccessScenarioTest, self).__init__(__file__, test_method, resource_group='test-adls-access') - self.adls_name = 'cliadls123426' - self.location = 'eastus2' + @ResourceGroupPreparer(name_prefix='cli_test_adls_access') + def test_dls_file_access_mgmt(self, resource_group): - def test_dls_file_access_mgmt(self): - self.execute() + user_id = '470c0ccf-c91a-4597-98cd-48507d2f1486' - def set_up(self): - super(DataLakeStoreFileAccessScenarioTest, self).set_up() + self.kwargs.update({ + 'dls': self.create_random_name('cliadls', 24), + 'loc': 'eastus2', + 'dir': 'adltestfolder01', + 'user_id': user_id, + 'acl_to_add': 'user:{}:rwx'.format(user_id), + 'acl_to_modify': 'user:{}:-w-'.format(user_id), + 'acl_to_remove': 'user:{}'.format(user_id) + }) # create ADLS account - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_name, self.location)) - result = self.cmd('dls account show -g {} -n {}'.format(self.resource_group, self.adls_name)) + self.cmd('dls account create -g {rg} -n {dls} -l {loc} --disable-encryption') + result = self.cmd('dls account show -g {rg} -n {dls}').get_output_in_json() while result['provisioningState'] != 'Succeeded' and result['provisioningState'] != 'Failed': time.sleep(5) - result = self.cmd('dls account show -g {} -n {}'.format(self.resource_group, self.adls_name)) + result = self.cmd('dls account show -g {rg} -n {dls}').get_output_in_json() if result['provisioningState'] == 'Failed': raise CLIError('Failed to create the adls account, tests cannot proceed!') - def body(self): - # define variables - adls = self.adls_name - folder_name = 'adltestfolder01' - user_id = '470c0ccf-c91a-4597-98cd-48507d2f1486' - acl_to_add = 'user:{}:rwx'.format(user_id) - acl_to_modify = 'user:{}:-w-'.format(user_id) - acl_to_remove = 'user:{}'.format(user_id) - # create a folder - self.cmd('dls fs create -n {} --path "{}" --folder --force'.format(adls, folder_name)) + self.cmd('dls fs create -n {dls} --path "{dir}" --folder --force') # get the folder - self.cmd('dls fs show -n {} --path "{}"'.format(adls, folder_name), checks=[ - JMESPathCheck('name', folder_name), - JMESPathCheck('type', 'DIRECTORY'), - JMESPathCheck('length', 0), + self.cmd('dls fs show -n {dls} --path "{dir}"', checks=[ + self.check('name', '{dir}'), + self.check('type', 'DIRECTORY'), + self.check('length', 0), ]) # set the owner and owning group for the file and confirm them - group_id = '80a3ed5f-959e-4696-ba3c-d3c8b2db6766' - user_id = '6361e05d-c381-4275-a932-5535806bb323' - self.cmd('dls fs access set-owner -n {} --path "{}" --group {} --owner {}'.format(adls, folder_name, group_id, user_id)) + self.kwargs.update({ + 'group_id': '80a3ed5f-959e-4696-ba3c-d3c8b2db6766', + 'user_id': '6361e05d-c381-4275-a932-5535806bb323' + }) + self.cmd('dls fs access set-owner -n {dls} --path "{dir}" --group {group_id} --owner {user_id}') # get the file and confirm those values - result = self.cmd('dls fs show -n {} --path "{}"'.format(adls, folder_name), checks=[ - JMESPathCheck('name', folder_name), - JMESPathCheck('type', 'DIRECTORY'), - JMESPathCheck('length', 0), - JMESPathCheck('owner', user_id), - JMESPathCheck('group', group_id), + self.cmd('dls fs show -n {dls} --path "{dir}"', checks=[ + self.check('name', '{dir}'), + self.check('type', 'DIRECTORY'), + self.check('length', 0), + self.check('owner', '{user_id}'), + self.check('group', '{group_id}'), ]) # set the permissions on the file - self.cmd('dls fs access set-permission -n {} --path "{}" --permission {}'.format(adls, folder_name, 777)) + self.cmd('dls fs access set-permission -n {dls} --path "{dir}" --permission 777') # get the file and confirm those values - result = self.cmd('dls fs show -n {} --path "{}"'.format(adls, folder_name), checks=[ - JMESPathCheck('name', folder_name), - JMESPathCheck('type', 'DIRECTORY'), - JMESPathCheck('length', 0), - JMESPathCheck('permission', '777'), + self.cmd('dls fs show -n {dls} --path "{dir}"', checks=[ + self.check('name', '{dir}'), + self.check('type', 'DIRECTORY'), + self.check('length', 0), + self.check('permission', '777'), ]) # get the initial ACE - result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() inital_acl_length = len(result['entries']) new_acl = ','.join(result['entries']) - new_acl += ',{}'.format(acl_to_add) + new_acl += ',{acl_to_add}'.format(**self.kwargs) + self.kwargs['new_acl'] = new_acl # set the full ACL - self.cmd('dls fs access set -n {} --path "{}" --acl-spec {}'.format(adls, folder_name, new_acl)) + self.cmd('dls fs access set -n {dls} --path "{dir}" --acl-spec {new_acl}') # get the ACL and confirm that it has grown - set_result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + set_result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() assert len(set_result['entries']) > inital_acl_length - assert acl_to_add in set_result['entries'] + assert self.kwargs['acl_to_add'] in set_result['entries'] # modify that ACE with set-entry - self.cmd('dls fs access set-entry -n {} --path "{}" --acl-spec {}'.format(adls, folder_name, acl_to_modify)) + self.cmd('dls fs access set-entry -n {dls} --path "{dir}" --acl-spec {acl_to_modify}') # get the ACL and confirm it has been modified - modify_result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + modify_result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() assert len(set_result['entries']) > inital_acl_length - assert acl_to_modify in modify_result['entries'] + assert self.kwargs['acl_to_modify'] in modify_result['entries'] # remove an ACE - self.cmd('dls fs access remove-entry -n {} --path "{}" --acl-spec {}'.format(adls, folder_name, acl_to_remove)) + self.cmd('dls fs access remove-entry -n {dls} --path "{dir}" --acl-spec {acl_to_remove}') # get ACL and ensure that it is smaller than before - remove_result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + remove_result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() assert len(remove_result['entries']) < len(modify_result['entries']) - assert acl_to_modify not in remove_result['entries'] + assert self.kwargs['acl_to_modify'] not in remove_result['entries'] # remove default ACL - self.cmd('dls fs access remove-all -n {} --path "{}" --default-acl'.format(adls, folder_name)) - remove_result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + self.cmd('dls fs access remove-all -n {dls} --path "{dir}" --default-acl') + remove_result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() # there should be four entries left assert 4 == len(remove_result['entries']) # remove ACL - self.cmd('dls fs access remove-all -n {} --path "{}"'.format(adls, folder_name)) - remove_result = self.cmd('dls fs access show -n {} --path "{}"'.format(adls, folder_name)) + self.cmd('dls fs access remove-all -n {dls} --path "{dir}"') + remove_result = self.cmd('dls fs access show -n {dls} --path "{dir}"').get_output_in_json() # there should be three entries left assert 3 == len(remove_result['entries']) -class DataLakeStoreFileScenarioTest(ResourceGroupVCRTestBase): +class DataLakeStoreFileScenarioTest(ScenarioTest): - def __init__(self, test_method): - super(DataLakeStoreFileScenarioTest, self).__init__(__file__, test_method, resource_group='test-adls-file') - self.adls_name = 'cliadls123416' - self.location = 'eastus2' - self.local_folder = os.path.join(os.getcwd(), 'adls_resources') - self.local_file = os.path.join(self.local_folder, 'sample_file.txt') - self.local_file_content = 'Local File Content' + def tearDown(self): + if os.path.exists(self.kwargs['local_folder']): + rmtree(self.kwargs['local_folder']) + return super().tearDown() + @ResourceGroupPreparer(name_prefix='cls_test_adls_file') def test_dls_file_mgmt(self): - self.execute() - def set_up(self): - super(DataLakeStoreFileScenarioTest, self).set_up() + local_folder = 'adls_resources' + self.kwargs.update({ + 'dls': self.create_random_name('cliadls', 24), + 'loc': 'eastus2', + 'local_folder': os.path.join(os.getcwd(), local_folder), + 'local_file': os.path.join(local_folder, 'sample_file.txt'), + 'local_file_content': 'Local File Content', + 'folder1': 'adltestfolder01', + 'folder2': 'adltestfolder02', + 'file': 'adltestfile01', + 'upload_file': 'adltestfile02', + 'join_file': 'adltestfile03', + 'download_file': 'adltestfile04', + 'content': '123456' + }) # create ADLS account - self.cmd('dls account create -g {} -n {} -l {} --disable-encryption'.format(self.resource_group, self.adls_name, self.location)) - result = self.cmd('dls account show -g {} -n {}'.format(self.resource_group, self.adls_name)) + self.cmd('dls account create -g {rg} -n {dls} -l {loc} --disable-encryption') + result = self.cmd('dls account show -g {rg} -n {dls}').get_output_in_json() while result['provisioningState'] != 'Succeeded' and result['provisioningState'] != 'Failed': time.sleep(5) - result = self.cmd('dls account show -g {} -n {}'.format(self.resource_group, self.adls_name)) + result = self.cmd('dls account show -g {rg} -n {dls}').get_output_in_json() if result['provisioningState'] == 'Failed': raise CLIError('Failed to create the adls account, tests cannot proceed!') - def tear_down(self): - super(DataLakeStoreFileScenarioTest, self).tear_down() - if os.path.exists(self.local_folder): - rmtree(self.local_folder) - - def body(self): - adls = self.adls_name - folder_name = 'adltestfolder01' - move_folder_name = 'adltestfolder02' - file_name = 'adltestfile01' - upload_file_name = 'adltestfile02' - join_file_name = 'adltestfile03' - download_file_name = 'adltestfile04' - file_content = '123456' - # create local file - if os.path.exists(self.local_folder): - rmtree(self.local_folder) + if os.path.exists(local_folder): + rmtree(local_folder) - os.makedirs(self.local_folder) - with open(self.local_file, 'w') as f: - f.write(self.local_file_content) + os.makedirs(local_folder) + with open(self.kwargs['local_file'], 'w') as f: + f.write(self.kwargs['local_file_content']) # file and folder manipulation # create a folder - self.cmd('dls fs create -n {} --path "{}" --folder --force'.format(adls, folder_name)) + self.cmd('dls fs create -n {dls} --path "{folder1}" --folder --force') # get the folder - self.cmd('dls fs show -n {} --path "{}"'.format(adls, folder_name), checks=[ - JMESPathCheck('name', folder_name), - JMESPathCheck('type', 'DIRECTORY'), - JMESPathCheck('length', 0), + self.cmd('dls fs show -n {dls} --path "{folder1}"', checks=[ + self.check('name', '{folder1}'), + self.check('type', 'DIRECTORY'), + self.check('length', 0), ]) # create a file - self.cmd('dls fs create -n {} --path "{}/{}" --content {}'.format(adls, folder_name, file_name, file_content)) + self.cmd('dls fs create -n {dls} --path "{folder1}/{file}" --content {content}') # get the file - result = self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, folder_name, file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(folder_name, file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(file_content)), - ]) + result = self.cmd('dls fs show -n {dls} --path "{folder1}/{file}"', checks=[ + self.check('name', '{folder1}/{file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['content'])), + ]).get_output_in_json() # set expiration time on the file # this future time gives the milliseconds since the epoch that have occured as of 01/31/2030 at noon epoch_time = datetime.datetime.utcfromtimestamp(0) final_time = datetime.datetime(2030, 1, 31, 12) - time_in_milliseconds = (final_time - epoch_time).total_seconds() * 1000 - self.cmd('dls fs set-expiry -n {} --path "{}/{}" --expiration-time {}'.format(adls, folder_name, file_name, time_in_milliseconds)) - new_result = self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, folder_name, file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(folder_name, file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(file_content)), - ]) + self.kwargs['time_in_milliseconds'] = (final_time - epoch_time).total_seconds() * 1000 + self.cmd('dls fs set-expiry -n {dls} --path "{folder1}/{file}" --expiration-time {time_in_milliseconds}') + new_result = self.cmd('dls fs show -n {dls} --path "{folder1}/{file}"', checks=[ + self.check('name', '{folder1}/{file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['content'])), + ]).get_output_in_json() # this value is not guaranteed to be exact, but it should be within a very small range (around 200ms) - assert time_in_milliseconds - 100 < new_result['msExpirationTime'] < time_in_milliseconds + 100 + assert self.kwargs['time_in_milliseconds'] - 100 < new_result['msExpirationTime'] < self.kwargs['time_in_milliseconds'] + 100 # remove the expiration time - self.cmd('dls fs remove-expiry -n {} --path "{}/{}"'.format(adls, folder_name, file_name)) - self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, folder_name, file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(folder_name, file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(file_content)), - JMESPathCheck('msExpirationTime', result['msExpirationTime']), + self.cmd('dls fs remove-expiry -n {dls} --path "{folder1}/{file}"') + self.cmd('dls fs show -n {dls} --path "{folder1}/{file}"', checks=[ + self.check('name', '{folder1}/{file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['content'])), + self.check('msExpirationTime', result['msExpirationTime']), ]) # move the file # this requires that the folder exists - self.cmd('dls fs create -n {} --path "{}" --folder --force'.format(adls, move_folder_name)) - self.cmd('dls fs move -n {} --source-path "{}/{}" --destination-path "{}/{}"'.format(adls, folder_name, file_name, move_folder_name, file_name)) + self.cmd('dls fs create -n {dls} --path "{folder2}" --folder --force') + self.cmd('dls fs move -n {dls} --source-path "{folder1}/{file}" --destination-path "{folder2}/{file}"') # get the file at the new location - self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, move_folder_name, file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(move_folder_name, file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(file_content)), + self.cmd('dls fs show -n {dls} --path "{folder2}/{file}"', checks=[ + self.check('name', '{folder2}/{file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['content'])), ]) # preview the file - result = self.cmd('dls fs preview -n {} --path "{}/{}"'.format(adls, move_folder_name, file_name)) - assert result == file_content + result = self.cmd('dls fs preview -n {dls} --path "{folder2}/{file}"').get_output_in_json() + assert result == self.kwargs['content'] # partial file preview - result = self.cmd('dls fs preview -n {} --path "{}/{}" --length 1 --offset 3'.format(adls, move_folder_name, file_name)) + result = self.cmd('dls fs preview -n {dls} --path "{folder2}/{file}" --length 1 --offset 3').get_output_in_json() assert len(result) == 1 assert result == '4' # list the directory, which contains just the one file - self.cmd('dls fs list -n {} --path "{}"'.format(adls, move_folder_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), - JMESPathCheck('[0].pathSuffix', file_name), - JMESPathCheck('[0].type', 'FILE'), - JMESPathCheck('[0].length', len(file_content)), + self.cmd('dls fs list -n {dls} --path "{folder2}"', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), + self.check('[0].pathSuffix', '{file}'), + self.check('[0].type', 'FILE'), + self.check('[0].length', len(self.kwargs['content'])), ]) # append content to a file - self.cmd('dls fs append -n {} --path "{}/{}" --content {}'.format(adls, move_folder_name, file_name, file_content)) + self.cmd('dls fs append -n {dls} --path "{folder2}/{file}" --content {content}') # get the file - self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, move_folder_name, file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(move_folder_name, file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(file_content) * 2), + self.cmd('dls fs show -n {dls} --path "{folder2}/{file}"', checks=[ + self.check('name', '{folder2}/{file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['content']) * 2), ]) # upload a file - self.cmd('dls fs upload -n {} --destination-path "{}/{}" --source-path "{}"'.format(adls, folder_name, upload_file_name, self.local_file)) + self.cmd('dls fs upload -n {dls} --destination-path "{folder1}/{upload_file}" --source-path "{local_file}"') # get the file - self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, folder_name, upload_file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(folder_name, upload_file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(self.local_file_content)), + self.cmd('dls fs show -n {dls} --path "{folder1}/{upload_file}"', checks=[ + self.check('name', '{folder1}/{upload_file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['local_file_content'])), ]) # join the uploaded file to the created file - self.cmd('dls fs join -n {} --destination-path "{}/{}" --source-paths "{}/{}","{}/{}"'.format(adls, folder_name, join_file_name, folder_name, upload_file_name, move_folder_name, file_name)) - self.cmd('dls fs show -n {} --path "{}/{}"'.format(adls, folder_name, join_file_name), checks=[ - JMESPathCheck('name', '{}/{}'.format(folder_name, join_file_name)), - JMESPathCheck('type', 'FILE'), - JMESPathCheck('length', len(self.local_file_content) + (len(file_content) * 2)), + self.cmd('dls fs join -n {dls} --destination-path "{folder1}/{join_file}" --source-paths "{folder1}/{upload_file}","{folder2}/{file}"') + self.cmd('dls fs show -n {dls} --path "{folder1}/{join_file}"', checks=[ + self.check('name', '{folder1}/{join_file}'), + self.check('type', 'FILE'), + self.check('length', len(self.kwargs['local_file_content']) + (len(self.kwargs['content']) * 2)), ]) # download the joined file - self.cmd('dls fs download -n {} --destination-path "{}" --source-path "{}/{}"'.format(adls, os.path.join(self.local_folder, download_file_name), folder_name, join_file_name)) - assert os.path.getsize(os.path.join(self.local_folder, download_file_name)) == len(self.local_file_content) + (len(file_content) * 2) + self.cmd('dls fs download -n {dls} --destination-path "{dir}/{download_file}" --source-path "{folder1}/{join_file}"') + assert os.path.getsize(os.path.join(self.kwargs['dir'], self.kwargs['download_file'])) == len(self.kwargs['local_file_content']) + (len(self.kwargs['content']) * 2) # delete the file and confirm it is gone. - self.cmd('dls fs delete -n {} --path "{}/{}"'.format(adls, folder_name, join_file_name)) - self.cmd('dls fs list -n {} --path "{}"'.format(adls, folder_name), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dls fs delete -n {dls} --path "{folder1}/{join_file}"') + self.cmd('dls fs list -n {dls} --path "{folder1}"', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) # delete a folder that has contents and confirm it is gone. - self.cmd('dls fs create -n {} --path "{}" --folder'.format(adls, move_folder_name)) - self.cmd('dls fs create -n {} --path "{}/{}"'.format(adls, move_folder_name, 'tempfile01.txt')) - self.cmd('dls fs delete -n {} --path "{}" --recurse'.format(adls, move_folder_name)) + self.cmd('dls fs create -n {dls} --path "{folder2}" --folder') + self.cmd('dls fs create -n {dls} --path "{folder2}/tempfile01.txt"') + self.cmd('dls fs delete -n {dls} --path "{folder2}" --recurse') # test that the path is gone - assert not self.cmd('dls fs test -n {} --path "{}"'.format(adls, move_folder_name)) + assert not self.cmd('dls fs test -n {dls} --path "{folder2}"') # test that the other folder still exists - assert self.cmd('dls fs test -n {} --path "{}"'.format(adls, folder_name)) - - if os.path.exists(self.local_folder): - rmtree(self.local_folder) - + assert self.cmd('dls fs test -n {dls} --path "{folder1}"') -class DataLakeStoreAccountScenarioTest(ResourceGroupVCRTestBase): - def __init__(self, test_method): - super(DataLakeStoreAccountScenarioTest, self).__init__(__file__, test_method, resource_group='cli-test-adls-mgmt') - self.adls_name = 'cliadls1234510' - self.location = 'eastus2' +class DataLakeStoreAccountScenarioTest(ScenarioTest): - def test_dls_account_mgmt(self): - self.execute() + @ResourceGroupPreparer(name_prefix='cli_test_adls_mgmt') + def test_dls_account_mgmt(self, resource_group): - def set_up(self): - super(DataLakeStoreAccountScenarioTest, self).set_up() + self.kwargs.update({ + 'dls': self.create_random_name('cliadls', 24), + 'loc': 'eastus2' + }) - def body(self): - rg = self.resource_group - adls = self.adls_name - loc = self.location # test create keyvault with default access policy set - self.cmd('dls account create -g {} -n {} -l {}'.format(rg, adls, loc), checks=[ - JMESPathCheck('name', adls), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('encryptionState', 'Enabled'), + self.cmd('dls account create -g {rg} -n {dls} -l {loc}', checks=[ + self.check('name', '{dls}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('encryptionState', 'Enabled'), ]) - self.cmd('dls account show -n {} -g {}'.format(adls, rg), checks=[ - JMESPathCheck('name', adls), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('encryptionState', 'Enabled'), + self.cmd('dls account show -n {dls} -g {rg}', checks=[ + self.check('name', '{dls}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('encryptionState', 'Enabled'), ]) # attempt to enable the key vault when it is already enabled, which should throw with self.assertRaises(CloudError): - self.cmd('dls account enable-key-vault -n {} -g {}'.format(adls, rg)) - - self.cmd('dls account list -g {}'.format(rg), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), - JMESPathCheck('[0].name', adls), - JMESPathCheck('[0].location', loc), - JMESPathCheck('[0].resourceGroup', rg), + self.cmd('dls account enable-key-vault -n {dls} -g {rg}') + + self.cmd('dls account list -g {rg}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), + self.check('[0].name', '{dls}'), + self.check('[0].location', '{loc}'), + self.check('[0].resourceGroup', '{rg}'), ]) - result = self.cmd('dls account list') + result = self.cmd('dls account list').get_output_in_json() assert isinstance(result, list) assert len(result) >= 1 # test update acct - self.cmd('dls account update -g {} -n {} --firewall-state Enabled --trusted-id-provider-state Enabled'.format(rg, adls)) - self.cmd('dls account show -n {} -g {}'.format(adls, rg), checks=[ - JMESPathCheck('name', adls), - JMESPathCheck('location', loc), - JMESPathCheck('resourceGroup', rg), - JMESPathCheck('firewallState', 'Enabled'), - JMESPathCheck('trustedIdProviderState', 'Enabled'), + self.cmd('dls account update -g {rg} -n {dls} --firewall-state Enabled --trusted-id-provider-state Enabled') + self.cmd('dls account show -n {dls} -g {rg}', checks=[ + self.check('name', '{dls}'), + self.check('location', '{loc}'), + self.check('resourceGroup', '{rg}'), + self.check('firewallState', 'Enabled'), + self.check('trustedIdProviderState', 'Enabled'), ]) # test firewall crud - fw_name = 'testfirewallrule01' - start_ip = '127.0.0.1' - end_ip = '127.0.0.2' - new_end_ip = '127.0.0.3' - self.cmd('dls account firewall create -g {} -n {} --firewall-rule-name {} --start-ip-address {} --end-ip-address {}'.format(rg, adls, fw_name, start_ip, end_ip)) - self.cmd('dls account firewall show -g {} -n {} --firewall-rule-name {}'.format(rg, adls, fw_name), checks=[ - JMESPathCheck('name', fw_name), - JMESPathCheck('startIpAddress', start_ip), - JMESPathCheck('endIpAddress', end_ip), + self.kwargs.update({ + 'fw': 'testfirewallrule01', + 'start_ip': '127.0.0.1', + 'end_ip': '127.0.0.2', + 'new_end_ip': '127.0.0.3' + }) + self.cmd('dls account firewall create -g {rg} -n {dls} --firewall-rule-name {fw} --start-ip-address {start_ip} --end-ip-address {end_ip}') + self.cmd('dls account firewall show -g {rg} -n {dls} --firewall-rule-name {fw}', checks=[ + self.check('name', '{fw}'), + self.check('startIpAddress', '{start_ip}'), + self.check('endIpAddress', '{end_ip}'), ]) - self.cmd('dls account firewall update -g {} -n {} --firewall-rule-name {} --end-ip-address {}'.format(rg, adls, fw_name, new_end_ip)) - self.cmd('dls account firewall show -g {} -n {} --firewall-rule-name {}'.format(rg, adls, fw_name), checks=[ - JMESPathCheck('name', fw_name), - JMESPathCheck('startIpAddress', start_ip), - JMESPathCheck('endIpAddress', new_end_ip), + self.cmd('dls account firewall update -g {rg} -n {dls} --firewall-rule-name {fw} --end-ip-address {new_end_ip}') + self.cmd('dls account firewall show -g {rg} -n {dls} --firewall-rule-name {fw}', checks=[ + self.check('name', '{fw}'), + self.check('startIpAddress', '{start_ip}'), + self.check('endIpAddress', '{new_end_ip}'), ]) - self.cmd('dls account firewall list -g {} -n {}'.format(rg, adls), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dls account firewall list -g {rg} -n {dls}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) - self.cmd('dls account firewall delete -g {} -n {} --firewall-rule-name {}'.format(rg, adls, fw_name)) - self.cmd('dls account firewall list -g {} -n {}'.format(rg, adls), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dls account firewall delete -g {rg} -n {dls} --firewall-rule-name {fw}') + self.cmd('dls account firewall list -g {rg} -n {dls}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) # test trusted id provider CRUD - trusted_provider = 'https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342' - new_provider = 'https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3' - provider_name = 'testprovider01' - self.cmd('dls account trusted-provider create -g {} -n {} --trusted-id-provider-name {} --id-provider {}'.format(rg, adls, provider_name, trusted_provider)) - self.cmd('dls account trusted-provider show -g {} -n {} --trusted-id-provider-name {}'.format(rg, adls, provider_name), checks=[ - JMESPathCheck('name', provider_name), - JMESPathCheck('idProvider', trusted_provider), + self.kwargs.update({ + 'trusted_provider': 'https://sts.windows.net/9d5b43a0-804c-4c82-8791-36aca2f72342', + 'new_provider': 'https://sts.windows.net/fceb709f-96f1-4c65-b06f-2541114bffb3', + 'provider': 'testprovider01' + }) + self.cmd('dls account trusted-provider create -g {rg} -n {dls} --trusted-id-provider-name {provider} --id-provider {trusted_provider}') + self.cmd('dls account trusted-provider show -g {rg} -n {dls} --trusted-id-provider-name {provider}', checks=[ + self.check('name', '{provider}'), + self.check('idProvider', '{trusted_provider}'), ]) - self.cmd('dls account trusted-provider update -g {} -n {} --trusted-id-provider-name {} --id-provider {}'.format(rg, adls, provider_name, new_provider)) - self.cmd('dls account trusted-provider show -g {} -n {} --trusted-id-provider-name {}'.format(rg, adls, provider_name), checks=[ - JMESPathCheck('name', provider_name), - JMESPathCheck('idProvider', new_provider), + self.cmd('dls account trusted-provider update -g {rg} -n {dls} --trusted-id-provider-name {provider} --id-provider {new_provider}') + self.cmd('dls account trusted-provider show -g {rg} -n {dls} --trusted-id-provider-name {provider}', checks=[ + self.check('name', '{provider}'), + self.check('idProvider', '{new_provider}'), ]) - self.cmd('dls account trusted-provider list -g {} -n {}'.format(rg, adls), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 1), + self.cmd('dls account trusted-provider list -g {rg} -n {dls}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 1), ]) - self.cmd('dls account trusted-provider delete -g {} -n {} --trusted-id-provider-name {}'.format(rg, adls, provider_name)) - self.cmd('dls account trusted-provider list -g {} -n {}'.format(rg, adls), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dls account trusted-provider delete -g {rg} -n {dls} --trusted-id-provider-name {provider}') + self.cmd('dls account trusted-provider list -g {rg} -n {dls}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) # test account deletion - self.cmd('dls account delete -g {} -n {}'.format(rg, adls)) - self.cmd('dls account list -g {}'.format(rg), checks=[ - JMESPathCheck('type(@)', 'array'), - JMESPathCheck('length(@)', 0), + self.cmd('dls account delete -g {rg} -n {dls}') + self.cmd('dls account list -g {rg}', checks=[ + self.check('type(@)', 'array'), + self.check('length(@)', 0), ]) diff --git a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/__init__.py b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/__init__.py index df8bff2b480..eb27116c5f4 100644 --- a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/__init__.py +++ b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/__init__.py @@ -6,14 +6,14 @@ import argparse from collections import OrderedDict +from knack.prompting import prompt_y_n +from knack.util import CLIError + from azure.cli.core import AzCommandsLoader from azure.cli.core.commands import CliCommandType import azure.cli.command_modules.extension._help # pylint: disable=unused-import -from knack.prompting import prompt_y_n -from knack.util import CLIError - # pylint: disable=line-too-long class ExtensionCommandsLoader(AzCommandsLoader): diff --git a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_index.py b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_index.py index 97882f514fd..00bf3386a2b 100644 --- a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_index.py +++ b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_index.py @@ -19,6 +19,7 @@ ERR_UNABLE_TO_GET_EXTENSIONS = 'Unable to get extensions from index. Improper index format.' +# pylint: disable=inconsistent-return-statements def get_index(index_url=None): index_url = index_url or DEFAULT_INDEX_URL try: diff --git a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_resolve.py b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_resolve.py index 9403563bf79..383d481f406 100644 --- a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_resolve.py +++ b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/_resolve.py @@ -5,12 +5,12 @@ from wheel.install import WHEEL_INFO_RE from pkg_resources import parse_version +from knack.log import get_logger + from azure.cli.core.extension import ext_compat_with_cli from azure.cli.command_modules.extension._index import get_index_extensions -from knack.log import get_logger - logger = get_logger(__name__) @@ -27,6 +27,7 @@ def _is_not_platform_specific(item): logger.debug("Skipping '%s' as not universal wheel." "We do not currently support platform specific extension detection. " "They can be installed with the full URL %s", item['filename'], item.get('downloadUrl')) + return False def _is_compatible_with_cli_version(item): @@ -36,6 +37,7 @@ def _is_compatible_with_cli_version(item): logger.debug("Skipping '%s' as not compatible with this version of the CLI. " "Extension compatibility result: is_compatible=%s cli_core_version=%s min_required=%s " "max_required=%s", item['filename'], is_compatible, cli_core_version, min_required, max_required) + return False def _is_greater_than_cur_version(cur_version): @@ -49,6 +51,7 @@ def filter_func(item): return True logger.debug("Skipping '%s' as %s not greater than current version %s", item['filename'], item_version, cur_version_parsed) + return False return filter_func diff --git a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/custom.py b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/custom.py index 9b6f8d87605..245abd637a7 100644 --- a/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/custom.py +++ b/src/command_modules/azure-cli-extension/azure/cli/command_modules/extension/custom.py @@ -14,13 +14,13 @@ from wheel.install import WHEEL_INFO_RE from six.moves.urllib.parse import urlparse # pylint: disable=import-error +from knack.log import get_logger + from azure.cli.core.util import CLIError from azure.cli.core.extension import (extension_exists, get_extension_path, get_extensions, get_extension, ext_compat_with_cli, WheelExtension, ExtensionNotInstalledException) -from knack.log import get_logger - from ._homebrew_patch import HomebrewPipPatch from ._index import get_index_extensions from ._resolve import resolve_from_index, NoExtensionCandidatesError diff --git a/src/command_modules/azure-cli-feedback/azure/cli/command_modules/feedback/custom.py b/src/command_modules/azure-cli-feedback/azure/cli/command_modules/feedback/custom.py index b1b562a5d29..f40f2d9fd1a 100644 --- a/src/command_modules/azure-cli-feedback/azure/cli/command_modules/feedback/custom.py +++ b/src/command_modules/azure-cli-feedback/azure/cli/command_modules/feedback/custom.py @@ -6,13 +6,13 @@ from __future__ import print_function import sys -from azure.cli.core import __version__ as core_version -from azure.cli.core.util import COMPONENT_PREFIX - from knack.log import get_logger from knack.prompting import prompt, NoTTYException from knack.util import CLIError +from azure.cli.core import __version__ as core_version +from azure.cli.core.util import COMPONENT_PREFIX + logger = get_logger(__name__) @@ -34,6 +34,7 @@ EVENT_NAME = 'FeedbackEvent' +# pylint: disable=inconsistent-return-statements def _prompt_net_promoter_score(): while True: try: diff --git a/src/command_modules/azure-cli-interactive/azure/cli/command_modules/interactive/__init__.py b/src/command_modules/azure-cli-interactive/azure/cli/command_modules/interactive/__init__.py index d537faa99f7..963dd4efc85 100644 --- a/src/command_modules/azure-cli-interactive/azure/cli/command_modules/interactive/__init__.py +++ b/src/command_modules/azure-cli-interactive/azure/cli/command_modules/interactive/__init__.py @@ -3,11 +3,10 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- +from knack.help_files import helps from azure.cli.core import AzCommandsLoader -from knack.help_files import helps - def start_shell(cmd, style=None): from azclishell.app import AzInteractiveShell diff --git a/src/command_modules/azure-cli-iot/azure/cli/command_modules/iot/custom.py b/src/command_modules/azure-cli-iot/azure/cli/command_modules/iot/custom.py index 41575108008..1620dc30a39 100644 --- a/src/command_modules/azure-cli-iot/azure/cli/command_modules/iot/custom.py +++ b/src/command_modules/azure-cli-iot/azure/cli/command_modules/iot/custom.py @@ -132,6 +132,7 @@ def iot_hub_delete(client, hub_name, resource_group_name=None): return client.iot_hub_resource.delete(resource_group_name, hub_name) +# pylint: disable=inconsistent-return-statements def iot_hub_show_connection_string(client, hub_name=None, resource_group_name=None, policy_name='iothubowner', key_type=KeyType.primary.value): if hub_name is None: @@ -297,6 +298,7 @@ def iot_device_delete(client, hub_name, device_id, resource_group_name=None, eta return device_client.delete(device_id, etag) +# pylint: disable=inconsistent-return-statements def iot_device_show_connection_string(client, hub_name, device_id=None, resource_group_name=None, top=20, key_type=KeyType.primary.value): resource_group_name = _ensure_resource_group_name(client, resource_group_name, hub_name) @@ -319,6 +321,7 @@ def iot_device_send_message(client, hub_name, device_id, resource_group_name=Non return device_client.send_message(device_id, data, message_id, correlation_id, user_id) +# pylint: disable=inconsistent-return-statements def iot_device_receive_message(client, hub_name, device_id, resource_group_name=None, lock_timeout=60): device_client = _get_device_client(client, resource_group_name, hub_name, device_id) result = device_client.receive_message(device_id, lock_timeout, raw=True) diff --git a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_command_type.py b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_command_type.py index f2873a7557e..353bd78659c 100644 --- a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_command_type.py +++ b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_command_type.py @@ -5,11 +5,11 @@ import base64 -from azure.cli.core.commands import LongRunningOperation, AzCommandGroup, AzArgumentContext - from knack.introspection import extract_full_summary_from_signature, extract_args_from_signature from knack.util import CLIError +from azure.cli.core.commands import LongRunningOperation, AzCommandGroup, AzArgumentContext + def _encode_hex(item): """ Recursively crawls the object structure and converts bytes or bytearrays to base64 diff --git a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_params.py b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_params.py index d4661104416..707fad3ed67 100644 --- a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_params.py +++ b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_params.py @@ -5,6 +5,8 @@ from argcomplete.completers import FilesCompleter +from knack.arguments import CLIArgumentType + from azure.mgmt.keyvault.models.key_vault_management_client_enums import \ (SkuName, KeyPermissions, SecretPermissions, CertificatePermissions) import azure.cli.core.commands.arm # pylint: disable=unused-import @@ -26,9 +28,6 @@ validate_x509_certificate_chain, secret_text_encoding_values, secret_binary_encoding_values) -from knack.arguments import CLIArgumentType - - # CUSTOM CHOICE LISTS secret_encoding_values = secret_text_encoding_values + secret_binary_encoding_values diff --git a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_validators.py b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_validators.py index d2bfd9f80b9..6bae62b0a97 100644 --- a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_validators.py +++ b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/_validators.py @@ -9,14 +9,15 @@ from datetime import datetime import re +from knack.util import CLIError + +from msrestazure.tools import parse_resource_id + from azure.mgmt.keyvault import KeyVaultManagementClient from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.cli.core.commands.validators import validate_tags -from knack.util import CLIError - -from msrestazure.tools import parse_resource_id secret_text_encoding_values = ['utf-8', 'utf-16le', 'utf-16be', 'ascii'] secret_binary_encoding_values = ['base64', 'hex'] diff --git a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/custom.py b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/custom.py index fb1f960050b..87f10fbca6e 100644 --- a/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/custom.py +++ b/src/command_modules/azure-cli-keyvault/azure/cli/command_modules/keyvault/custom.py @@ -9,8 +9,14 @@ import re import time -from OpenSSL import crypto +from knack.log import get_logger +from knack.util import CLIError + from msrestazure.azure_exceptions import CloudError + +from OpenSSL import crypto + + from azure.keyvault.models import \ (Action, ActionType, KeyUsageType, CertificateAttributes, CertificatePolicy, IssuerParameters, KeyProperties, LifetimeAction, SecretProperties, X509CertificateProperties, SubjectAlternativeNames, Trigger) @@ -22,10 +28,6 @@ import azure.cli.core.telemetry as telemetry from azure.cli.command_modules.keyvault._validators import secret_text_encoding_values -from knack.log import get_logger -from knack.util import CLIError - - logger = get_logger(__name__) @@ -132,6 +134,7 @@ def list_keyvault(client, resource_group_name=None): return list(vault_list) +# pylint: disable=inconsistent-return-statements def _get_current_user_object_id(graph_client): try: current_user = graph_client.objects.get_current_user() @@ -146,11 +149,11 @@ def _get_object_id_by_spn(graph_client, spn): filter="servicePrincipalNames/any(c:c eq '{}')".format(spn))) if not accounts: logger.warning("Unable to find user with spn '%s'", spn) - return + return None if len(accounts) > 1: logger.warning("Multiple service principals found with spn '%s'. " "You can avoid this by specifying object id.", spn) - return + return None return accounts[0].object_id @@ -158,11 +161,11 @@ def _get_object_id_by_upn(graph_client, upn): accounts = list(graph_client.users.list(filter="userPrincipalName eq '{}'".format(upn))) if not accounts: logger.warning("Unable to find user with upn '%s'", upn) - return + return None if len(accounts) > 1: logger.warning("Multiple users principals found with upn '%s'. " "You can avoid this by specifying object id.", upn) - return + return None return accounts[0].object_id @@ -177,6 +180,7 @@ def _get_object_id_from_subscription(graph_client, subscription): else: logger.warning('Current credentials are not from a user or service principal. ' 'Azure Key Vault does not work with certificate credentials.') + return None def _get_object_id(graph_client, subscription=None, spn=None, upn=None): @@ -554,6 +558,7 @@ def restore_secret(client, vault_base_url, file_path): # region KeyVault Certificate +# pylint: disable=inconsistent-return-statements def create_certificate(client, vault_base_url, certificate_name, certificate_policy, disabled=False, tags=None, validity=None): cert_attrs = CertificateAttributes(not disabled) diff --git a/src/command_modules/azure-cli-lab/azure/cli/command_modules/lab/validators.py b/src/command_modules/azure-cli-lab/azure/cli/command_modules/lab/validators.py index a2043351ff0..1648dc44917 100644 --- a/src/command_modules/azure-cli-lab/azure/cli/command_modules/lab/validators.py +++ b/src/command_modules/azure-cli-lab/azure/cli/command_modules/lab/validators.py @@ -528,6 +528,7 @@ def _get_current_user_object_id(graph_client): return current_user.object_id # pylint:disable=no-member except CloudError: pass + return None def _get_object_id(graph_client, subscription=None, spn=None, upn=None): @@ -549,6 +550,7 @@ def _get_object_id_from_subscription(graph_client, subscription): else: logger.warning('Current credentials are not from a user or service principal. ' 'Azure DevTest Lab does not work with certificate credentials.') + return None def _get_object_id_by_spn(graph_client, spn): @@ -556,11 +558,11 @@ def _get_object_id_by_spn(graph_client, spn): filter="servicePrincipalNames/any(c:c eq '{}')".format(spn))) if not accounts: logger.warning("Unable to find user with spn '%s'", spn) - return + return None if len(accounts) > 1: logger.warning("Multiple service principals found with spn '%s'. " "You can avoid this by specifying object id.", spn) - return + return None return accounts[0].object_id @@ -568,9 +570,9 @@ def _get_object_id_by_upn(graph_client, upn): accounts = list(graph_client.users.list(filter="userPrincipalName eq '{}'".format(upn))) if not accounts: logger.warning("Unable to find user with upn '%s'", upn) - return + return None if len(accounts) > 1: logger.warning("Multiple users principals found with upn '%s'. " "You can avoid this by specifying object id.", upn) - return + return None return accounts[0].object_id diff --git a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_completers.py b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_completers.py index 51f7eb0d83e..a72c7b1f051 100644 --- a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_completers.py +++ b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_completers.py @@ -9,6 +9,7 @@ from azure.cli.command_modules.network.custom import list_traffic_manager_endpoints +# pylint: disable=inconsistent-return-statements @Completer def subnet_completion_list(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argument client = network_client_factory(cmd.cli_ctx) @@ -20,6 +21,7 @@ def subnet_completion_list(cmd, prefix, namespace, **kwargs): # pylint: disable def get_lb_subresource_completion_list(prop): + # pylint: disable=inconsistent-return-statements @Completer def completer(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argument client = network_client_factory(cmd.cli_ctx) @@ -35,6 +37,7 @@ def completer(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argum def get_ag_subresource_completion_list(prop): + # pylint: disable=inconsistent-return-statements @Completer def completer(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argument client = network_client_factory(cmd.cli_ctx) @@ -48,6 +51,7 @@ def completer(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argum return completer +# pylint: disable=inconsistent-return-statements @Completer def ag_url_map_rule_completion_list(cmd, prefix, namespace, **kwargs): # pylint: disable=unused-argument client = network_client_factory(cmd.cli_ctx) diff --git a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_params.py b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_params.py index b01dae11de7..f13cc0051e8 100644 --- a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_params.py +++ b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_params.py @@ -6,6 +6,8 @@ # pylint: disable=line-too-long from argcomplete.completers import FilesCompleter +from knack.arguments import CLIArgumentType, ignore_type + from azure.cli.core.commands.parameters import (get_location_type, get_resource_name_completion_list, tags_type, zone_type, file_type, get_resource_group_completion_list, @@ -29,8 +31,6 @@ ag_url_map_rule_completion_list, tm_endpoint_completion_list) from azure.cli.core.util import get_json_object -from knack.arguments import CLIArgumentType, ignore_type - # pylint: disable=too-many-locals, too-many-branches, too-many-statements def load_arguments(self, _): diff --git a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_validators.py b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_validators.py index 8a70a5e23c4..9bbf83ca55e 100644 --- a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_validators.py +++ b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/_validators.py @@ -8,6 +8,8 @@ import socket import os +from knack.util import CLIError + from azure.cli.core.commands.validators import \ (validate_tags, get_default_location_from_resource_group) from azure.cli.core.commands.template_create import get_folded_parameter_validator @@ -15,8 +17,6 @@ from azure.cli.core.commands.validators import validate_parameter_set from azure.cli.core.profiles import ResourceType -from knack.util import CLIError - # PARAMETER VALIDATORS @@ -77,6 +77,7 @@ def _validate_vnet_name_or_id(namespace): return _validate_vnet_name_or_id +# pylint: disable=inconsistent-return-statements def dns_zone_name_type(value): if value: return value[:-1] if value[-1] == '.' else value diff --git a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/custom.py b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/custom.py index b7be240b2f2..c4f62b1d4c8 100644 --- a/src/command_modules/azure-cli-network/azure/cli/command_modules/network/custom.py +++ b/src/command_modules/azure-cli-network/azure/cli/command_modules/network/custom.py @@ -7,6 +7,8 @@ from collections import Counter, OrderedDict import mock +from knack.log import get_logger + from msrestazure.azure_exceptions import CloudError from msrestazure.tools import parse_resource_id, is_valid_resource_id, resource_id @@ -27,8 +29,6 @@ from azure.cli.command_modules.network.zone_file.make_zone_file import make_zone_file from azure.cli.core.profiles import ResourceType -from knack.log import get_logger - logger = get_logger(__name__) @@ -964,7 +964,7 @@ def export_zone(cmd, resource_group_name, zone_name): print(make_zone_file(zone_obj)) -# pylint: disable=too-many-return-statements +# pylint: disable=too-many-return-statements, inconsistent-return-statements def _build_record(data): record_type = data['type'].lower() try: diff --git a/src/command_modules/azure-cli-profile/azure/cli/command_modules/profile/custom.py b/src/command_modules/azure-cli-profile/azure/cli/command_modules/profile/custom.py index 6f675cf1f49..fbb396f9071 100644 --- a/src/command_modules/azure-cli-profile/azure/cli/command_modules/profile/custom.py +++ b/src/command_modules/azure-cli-profile/azure/cli/command_modules/profile/custom.py @@ -5,15 +5,15 @@ from __future__ import print_function +from knack.log import get_logger +from knack.prompting import prompt_pass, NoTTYException +from knack.util import CLIError + from azure.cli.core._profile import Profile from azure.cli.core.util import in_cloud_console from azure.cli.core.commands.validators import DefaultStr -from knack.log import get_logger -from knack.prompting import prompt_pass, NoTTYException -from knack.util import CLIError - logger = get_logger(__name__) _CLOUD_CONSOLE_WARNING_TEMPLATE = ("Azure Cloud Shell automatically authenticates the user account it was initially" @@ -44,6 +44,7 @@ def list_subscriptions(cmd, all=False, refresh=False): # pylint: disable=redefi return subscriptions +# pylint: disable=inconsistent-return-statements def show_subscription(cmd, subscription=None, show_auth_for_sdk=None): import json profile = Profile(cmd.cli_ctx) @@ -86,6 +87,7 @@ def account_clear(cmd): profile.logout_all() +# pylint: disable=inconsistent-return-statements def login(cmd, username=None, password=None, service_principal=None, tenant=None, allow_no_subscriptions=False, msi=False, msi_port=DefaultStr(50342)): """Log in to access Azure subscriptions""" diff --git a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/__init__.py b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/__init__.py index 75d3ed6e040..d2832021531 100644 --- a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/__init__.py +++ b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/__init__.py @@ -12,12 +12,12 @@ class RdbmsCommandsLoader(AzCommandsLoader): def __init__(self, cli_ctx=None): from azure.cli.core.commands import CliCommandType - from azure.cli.command_modules.rdbms._util import _PolyParametersContext + from azure.cli.command_modules.rdbms._util import RdbmsArgumentContext rdbms_custom = CliCommandType(operations_tmpl='azure.cli.command_modules.rdbms.custom#{}') super(RdbmsCommandsLoader, self).__init__(cli_ctx=cli_ctx, min_profile='2017-03-10-profile', custom_command_type=rdbms_custom, - argument_context_cls=_PolyParametersContext) + argument_context_cls=RdbmsArgumentContext) def load_command_table(self, args): from azure.cli.command_modules.rdbms.commands import load_command_table diff --git a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/_util.py b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/_util.py index 31e9c0d7f0b..484df8aaab0 100644 --- a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/_util.py +++ b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/_util.py @@ -6,27 +6,27 @@ from azure.cli.core.commands import AzArgumentContext -class _PolyParametersContext(AzArgumentContext): +class RdbmsArgumentContext(AzArgumentContext): def __init__(self, command_loader, scope, **kwargs): - super(_PolyParametersContext, self).__init__(command_loader, scope) + super(RdbmsArgumentContext, self).__init__(command_loader, scope) self.validators = [] - def expand(self, argument_name, model_type, group_name=None, patches=None): - super(_PolyParametersContext, self).expand(argument_name, model_type, group_name, patches) + def expand(self, dest, model_type, group_name=None, patches=None): + super(RdbmsArgumentContext, self).expand(dest, model_type, group_name, patches) from knack.arguments import ignore_type # Remove the validator and store it into a list - arg = self.command_loader.argument_registry.arguments[self.command_scope].get(argument_name, None) + arg = self.command_loader.argument_registry.arguments[self.command_scope].get(dest, None) if not arg: # when the argument context scope is N/A return self.validators.append(arg.settings['validator']) - if argument_name == 'parameters': + if dest == 'parameters': from .validators import get_combined_validator - self.argument(argument_name, + self.argument(dest, arg_type=ignore_type, validator=get_combined_validator(self.validators)) else: - self.argument(argument_name, arg_type=ignore_type, validator=None) + self.argument(dest, arg_type=ignore_type, validator=None) diff --git a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/commands.py b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/commands.py index 6b33f4b0c0d..a169dd801da 100644 --- a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/commands.py +++ b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/commands.py @@ -95,7 +95,7 @@ def load_command_table(self, _): g.command('delete', 'delete', confirmation=True) g.command('show', 'get') g.command('list', 'list_by_server') - g.generic_update_command('update', setter_name='_firewall_rule_custom_setter', setter_type=rdbms_custom, custom_func_name='_firewall_rule_update_custom_func') + g.generic_update_command('update', setter_name='_firewall_rule_custom_setter', setter_type=rdbms_custom, custom_func_name='_firewall_rule_update_custom_func') with self.command_group('mysql server configuration', mysql_config_sdk) as g: g.command('set', 'create_or_update') diff --git a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/custom.py b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/custom.py index c62dc0bf272..d84f2efa1b4 100644 --- a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/custom.py +++ b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/custom.py @@ -91,14 +91,14 @@ def _download_log_files( resource_group_name, server_name, file_name): - #:param resource_group_name: The name of the resource group that - #contains the resource. You can obtain this value from the Azure - #Resource Manager API or the portal. - #:type resource_group_name: str - #:param server_name: Name of the server. - #:type server_name: str - #:param file_name: Space separated list of log filenames on the server to download. - #:type filename_contains: str + # :param resource_group_name: The name of the resource group that + # contains the resource. You can obtain this value from the Azure + # Resource Manager API or the portal. + # :type resource_group_name: str + # :param server_name: Name of the server. + # :type server_name: str + # :param file_name: Space separated list of log filenames on the server to download. + # :type filename_contains: str from six.moves.urllib.request import urlretrieve # pylint: disable=import-error # list all files @@ -111,19 +111,19 @@ def _download_log_files( def _list_log_files_with_filter(client, resource_group_name, server_name, filename_contains=None, file_last_written=None, max_file_size=None): - #:param resource_group_name: The name of the resource group that - #contains the resource. You can obtain this value from the Azure - #Resource Manager API or the portal. - #:type resource_group_name: str - #:param server_name: The name of the server. - #:type server_name: str - #:param filename_contains: The pattern that file name should match. - #:type filename_contains: str - #:param file_last_written: Interger in hours to indicate file last modify time, - #default value is 72. - #:type file_last_written: int - #:param max_file_size: The file size limitation to filter files. - #:type max_file_size: int + # :param resource_group_name: The name of the resource group that + # contains the resource. You can obtain this value from the Azure + # Resource Manager API or the portal. + # :type resource_group_name: str + # :param server_name: The name of the server. + # :type server_name: str + # :param filename_contains: The pattern that file name should match. + # :type filename_contains: str + # :param file_last_written: Interger in hours to indicate file last modify time, + # default value is 72. + # :type file_last_written: int + # :param max_file_size: The file size limitation to filter files. + # :type max_file_size: int import re from datetime import datetime, timedelta from dateutil.tz import tzutc diff --git a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/validators.py b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/validators.py index 8edfbad5e17..2e743bd4e68 100644 --- a/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/validators.py +++ b/src/command_modules/azure-cli-rdbms/azure/cli/command_modules/rdbms/validators.py @@ -3,17 +3,18 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- -from azure.cli.core.commands.validators import ( - get_default_location_from_resource_group, validate_tags) - from knack.prompting import prompt_pass, NoTTYException from knack.util import CLIError +from azure.cli.core.commands.validators import ( + get_default_location_from_resource_group, validate_tags) + def get_combined_validator(validators): def _final_validator_impl(cmd, namespace): # do additional creation validation - if namespace._subcommand == 'create': + verb = cmd.name.rsplit(' ', 1)[1] + if verb == 'create': storage_validator(namespace) password_validator(namespace) get_default_location_from_resource_group(cmd, namespace) diff --git a/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/commands.py b/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/commands.py index 60fc6301702..0ac9d8641dc 100644 --- a/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/commands.py +++ b/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/commands.py @@ -172,8 +172,8 @@ def load_command_table(self, _): # Resource feature commands if self.supported_api_version(min_api='2017-05-10'): feature_table_transform = '{Name:name, RegistrationState:properties.state}' - with self.command_group('feature', resource_feature_sdk) as g: - g.custom_command('list', 'list_features', client_factory=cf_features, table_transformer='[].' + feature_table_transform) + with self.command_group('feature', resource_feature_sdk, client_factory=cf_features) as g: + g.custom_command('list', 'list_features', table_transformer='[].' + feature_table_transform) g.command('show', 'get', exception_handler=empty_on_404, table_transformer=feature_table_transform) g.custom_command('register', 'register_feature') diff --git a/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/custom.py b/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/custom.py index 51073cf9f79..cb135996ff9 100644 --- a/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/custom.py +++ b/src/command_modules/azure-cli-resource/azure/cli/command_modules/resource/custom.py @@ -18,6 +18,12 @@ from six.moves.urllib.request import urlopen # pylint: disable=import-error from six.moves.urllib.parse import urlparse # pylint: disable=import-error +from knack.log import get_logger +from knack.prompting import prompt, prompt_pass, prompt_t_f, prompt_choice_list, prompt_int, NoTTYException +from knack.util import CLIError + +from msrestazure.tools import is_valid_resource_id, parse_resource_id, resource_id as resource_dict_to_id + from azure.mgmt.resource.resources.models import GenericResource from azure.mgmt.resource.locks.models import ManagementLockObject @@ -33,12 +39,6 @@ _resource_links_client_factory, _authorization_management_client, _resource_managedapps_client_factory) from azure.cli.command_modules.resource._validators import _parse_lock_id -from knack.log import get_logger -from knack.prompting import prompt, prompt_pass, prompt_t_f, prompt_choice_list, prompt_int, NoTTYException -from knack.util import CLIError - -from msrestazure.tools import is_valid_resource_id, parse_resource_id, resource_id as resource_dict_to_id - logger = get_logger(__name__) @@ -886,6 +886,7 @@ def register_feature(client, resource_provider_namespace, feature_name): return client.register(resource_provider_namespace, feature_name) +# pylint: disable=inconsistent-return-statements def create_policy_assignment(cmd, policy=None, policy_set_definition=None, name=None, display_name=None, params=None, resource_group_name=None, scope=None, sku=None, @@ -1162,6 +1163,7 @@ def list_locks(cmd, resource_group=None, resource_name, filter=filter_string) +# pylint: disable=inconsistent-return-statements def get_lock(cmd, lock_name=None, resource_group=None, resource_provider_namespace=None, parent_resource_path=None, resource_type=None, resource_name=None, ids=None): """ @@ -1206,6 +1208,7 @@ def get_lock(cmd, lock_name=None, resource_group=None, resource_provider_namespa parent_resource_path or '', resource_type, resource_name, lock_name) +# pylint: disable=inconsistent-return-statements def delete_lock(cmd, lock_name=None, resource_group=None, resource_provider_namespace=None, parent_resource_path=None, resource_type=None, resource_name=None, ids=None): """ @@ -1292,6 +1295,7 @@ def create_lock(cmd, lock_name, level, resource_name, lock_name, parameters) +# pylint: disable=inconsistent-return-statements def update_lock(cmd, lock_name=None, resource_group=None, resource_provider_namespace=None, notes=None, parent_resource_path=None, resource_type=None, resource_name=None, level=None, ids=None): """ diff --git a/src/command_modules/azure-cli-role/azure/cli/command_modules/role/_params.py b/src/command_modules/azure-cli-role/azure/cli/command_modules/role/_params.py index 59de4f97db5..1d0028408cc 100644 --- a/src/command_modules/azure-cli-role/azure/cli/command_modules/role/_params.py +++ b/src/command_modules/azure-cli-role/azure/cli/command_modules/role/_params.py @@ -4,13 +4,14 @@ # -------------------------------------------------------------------------------------------- # pylint: disable=line-too-long + +from knack.arguments import CLIArgumentType + from azure.cli.core.commands.parameters import get_enum_type, get_three_state_flag from azure.cli.command_modules.role._completers import get_role_definition_name_completion_list from azure.cli.command_modules.role._validators import validate_group, validate_member_id, validate_cert, VARIANT_GROUP_ID_ARGS -from knack.arguments import CLIArgumentType - name_arg_type = CLIArgumentType(options_list=('--name', '-n'), metavar='NAME') diff --git a/src/command_modules/azure-cli-role/azure/cli/command_modules/role/custom.py b/src/command_modules/azure-cli-role/azure/cli/command_modules/role/custom.py index 00e6454a9be..e529d4b7e1e 100644 --- a/src/command_modules/azure-cli-role/azure/cli/command_modules/role/custom.py +++ b/src/command_modules/azure-cli-role/azure/cli/command_modules/role/custom.py @@ -12,6 +12,9 @@ from dateutil.relativedelta import relativedelta import dateutil.parser +from knack.log import get_logger +from knack.util import CLIError, todict + from azure.cli.core.util import get_file_json, shell_safe_json_parse from azure.mgmt.authorization.models import (RoleAssignmentProperties, Permission, RoleDefinition, @@ -25,9 +28,6 @@ PasswordProfile, ServicePrincipalCreateParameters) -from knack.log import get_logger -from knack.util import CLIError, todict - from ._client_factory import _auth_client_factory, _graph_client_factory logger = get_logger(__name__) @@ -621,6 +621,7 @@ def _validate_app_dates(app_start_date, app_end_date, cert_start_date, cert_end_ return (app_start_date, app_end_date, cert_start_date, cert_end_date) +# pylint: disable=inconsistent-return-statements def create_service_principal_for_rbac( # pylint:disable=too-many-statements,too-many-locals, too-many-branches cmd, name=None, password=None, years=None, diff --git a/src/command_modules/azure-cli-servicefabric/azure/cli/command_modules/servicefabric/custom.py b/src/command_modules/azure-cli-servicefabric/azure/cli/command_modules/servicefabric/custom.py index b6e66975bb1..3124df3e3f9 100644 --- a/src/command_modules/azure-cli-servicefabric/azure/cli/command_modules/servicefabric/custom.py +++ b/src/command_modules/azure-cli-servicefabric/azure/cli/command_modules/servicefabric/custom.py @@ -1152,6 +1152,7 @@ def _create_certificate(cli_ctx, return vault_id, secret_url, certificate_thumbprint, output_file +# pylint: disable=inconsistent-return-statements def _add_cert_to_vmss(cli_ctx, vmss, resource_group_name, vault_id, secret_url): compute_client = compute_client_factory(cli_ctx) secrets = [ @@ -1216,6 +1217,7 @@ def _create_resource_group_name(cli_ctx, rg_name, location, tags=None): client.create_or_update(rg_name, parameters) +# pylint: disable=inconsistent-return-statements def _get_target_instance(reliability_level): level = reliability_level.lower() if level == 'none': @@ -1230,6 +1232,7 @@ def _get_target_instance(reliability_level): return 9 +# pylint: disable=inconsistent-return-statements def _get_reliability_level(cluster_size): size = int(cluster_size) if size > 0 and size < 3: @@ -1310,6 +1313,7 @@ def _get_certificate_name(resource_group_name): return "{}{}".format(certificate_name, suffix) +# pylint: disable=inconsistent-return-statements def _get_vault_from_secret_identifier(cli_ctx, secret_identifier): key_vault_client = keyvault_client_factory(cli_ctx).vaults vault_name = urlparse(secret_identifier).hostname.split('.')[0] @@ -1650,6 +1654,7 @@ def _create_keyvault(cli_ctx, _create_keyvault.__doc__ = VaultProperties.__doc__ +# pylint: disable=inconsistent-return-statements def _get_current_user_object_id(graph_client): try: current_user = graph_client.objects.get_current_user() @@ -1664,11 +1669,11 @@ def _get_object_id_by_spn(graph_client, spn): filter="servicePrincipalNames/any(c:c eq '{}')".format(spn))) if not accounts: logger.warning("Unable to find user with spn '%s'", spn) - return + return None if len(accounts) > 1: logger.warning("Multiple service principals found with spn '%s'. " "You can avoid this by specifying object id.", spn) - return + return None return accounts[0].object_id @@ -1677,11 +1682,11 @@ def _get_object_id_by_upn(graph_client, upn): filter="userPrincipalName eq '{}'".format(upn))) if not accounts: logger.warning("Unable to find user with upn '%s'", upn) - return + return None if len(accounts) > 1: logger.warning("Multiple users principals found with upn '%s'. " "You can avoid this by specifying object id.", upn) - return + return None return accounts[0].object_id diff --git a/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/_params.py b/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/_params.py index 9e86ac3ccf7..5f280cc340d 100644 --- a/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/_params.py +++ b/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/_params.py @@ -6,6 +6,8 @@ import itertools from enum import Enum +from knack.arguments import CLIArgumentType, ignore_type + from azure.cli.core.commands import patch_arg_make_required, patch_arg_make_optional from azure.mgmt.sql.models.database import Database from azure.mgmt.sql.models.elastic_pool import ElasticPool @@ -28,8 +30,6 @@ from azure.cli.core.commands.parameters import (get_three_state_flag, get_enum_type, get_resource_name_completion_list, get_location_type) -from knack.arguments import CLIArgumentType, ignore_type - from .custom import ( ClientAuthenticationType, ClientType, diff --git a/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/custom.py b/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/custom.py index 5c9f5b5f547..bd2ef914dd4 100644 --- a/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/custom.py +++ b/src/command_modules/azure-cli-sql/azure/cli/command_modules/sql/custom.py @@ -4,10 +4,11 @@ # -------------------------------------------------------------------------------------------- # pylint: disable=C0302 - +from enum import Enum import re -from enum import Enum +# url parse package has different names in Python 2 and 3. 'six' package works cross-version. +from six.moves.urllib.parse import (quote, urlparse) # pylint: disable=import-error from azure.cli.core._profile import Profile from azure.cli.core.commands.client_factory import ( @@ -31,9 +32,6 @@ from azure.mgmt.resource import ResourceManagementClient from azure.mgmt.storage import StorageManagementClient -# url parse package has different names in Python 2 and 3. 'six' package works cross-version. -from six.moves.urllib.parse import (quote, urlparse) # pylint: disable=import-error - from ._util import ( get_sql_servers_operations ) @@ -364,6 +362,7 @@ def db_restore( # Fails over a database. Wrapper function which uses the server location so that the user doesn't # need to specify replication link id. +# pylint: disable=inconsistent-return-statements def db_failover( client, database_name, @@ -446,6 +445,7 @@ def db_list_capabilities( return editions +# pylint: disable=inconsistent-return-statements def db_delete_replica_link( client, database_name, diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/__init__.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/__init__.py index 2e330da373a..4cff61386f0 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/__init__.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/__init__.py @@ -141,6 +141,8 @@ def storage_custom_command(self, name, method_name, **kwargs): self._register_data_plane_account_arguments(command_name) def get_handler_suppress_404(self): + + # pylint: disable=inconsistent-return-statements def handler(ex): from azure.cli.core.profiles import get_sdk diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_client_factory.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_client_factory.py index cba2b0c3d23..d32af1cc8c3 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_client_factory.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_client_factory.py @@ -3,13 +3,13 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- +from knack.util import CLIError + from azure.cli.core.commands.client_factory import get_mgmt_service_client, get_data_service_client from azure.cli.core.profiles import ResourceType, get_sdk from azure.cli.command_modules.storage.sdkutil import get_table_data_type -from knack.util import CLIError - NO_CREDENTIALS_ERROR_MESSAGE = """ No credentials specified to access storage service. Please provide any of the following: (1) account name and key (--account-name and --account-key options or diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_validators.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_validators.py index adbfc618ddf..7e036951675 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_validators.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/_validators.py @@ -10,17 +10,17 @@ import re from datetime import datetime +from knack.util import CLIError + from azure.cli.core.commands.client_factory import get_mgmt_service_client from azure.cli.core.commands.validators import validate_key_value_pairs +from azure.cli.core.profiles import ResourceType, get_sdk from azure.cli.command_modules.storage._client_factory import get_storage_data_service_client from azure.cli.command_modules.storage.util import glob_files_locally, guess_content_type from azure.cli.command_modules.storage.sdkutil import get_table_data_type from azure.cli.command_modules.storage.url_quote_util import encode_for_url -from azure.cli.core.profiles import ResourceType, get_sdk - -from knack.util import CLIError storage_account_key_options = {'primary': 'key1', 'secondary': 'key2'} @@ -28,6 +28,7 @@ # Utilities +# pylint: disable=inconsistent-return-statements def _query_account_key(cli_ctx, account_name): """Query the storage account key. This is used when the customer doesn't offer account key but name.""" scf = get_mgmt_service_client(cli_ctx, ResourceType.MGMT_STORAGE) diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/blob.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/blob.py index 145bb664760..cb06e9eef69 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/blob.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/blob.py @@ -58,6 +58,7 @@ def storage_blob_copy_batch(cmd, client, source_client, source_sas = create_short_lived_container_sas(cmd, source_client.account_name, source_client.account_key, source_container) + # pylint: disable=inconsistent-return-statements def action_blob_copy(blob_name): if dryrun: logger.warning(' - copy blob %s', blob_name) @@ -79,6 +80,7 @@ def action_blob_copy(blob_name): source_sas = create_short_lived_share_sas(cmd, source_client.account_name, source_client.account_key, source_share) + # pylint: disable=inconsistent-return-statements def action_file_copy(file_info): dir_name, file_name = file_info if dryrun: diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/file.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/file.py index 6379f47b406..9347980163e 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/file.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/operations/file.py @@ -9,6 +9,9 @@ import os.path +from knack.util import CLIError +from knack.log import get_logger + from azure.common import AzureException, AzureHttpError from azure.cli.command_modules.storage.util import (filter_none, collect_blobs, collect_files, create_blob_service_from_storage_client, @@ -16,9 +19,6 @@ guess_content_type) from azure.cli.command_modules.storage.url_quote_util import encode_for_url, make_encoded_file_url_and_params -from knack.util import CLIError -from knack.log import get_logger - def list_share_files(cmd, client, share_name, directory_name=None, timeout=None, exclude_dir=False, snapshot=None): if cmd.supported_api_version(min_api='2017-04-17'): @@ -149,6 +149,7 @@ def storage_file_copy_batch(cmd, client, source_client, destination_share=None, source_sas = create_short_lived_container_sas(cmd, source_client.account_name, source_client.account_key, source_container) + # pylint: disable=inconsistent-return-statements def action_blob_copy(blob_name): if dryrun: logger.warning(' - copy blob %s', blob_name) @@ -176,6 +177,7 @@ def action_blob_copy(blob_name): source_sas = create_short_lived_share_sas(cmd, source_client.account_name, source_client.account_key, source_share) + # pylint: disable=inconsistent-return-statements def action_file_copy(file_info): dir_name, file_name = file_info if dryrun: diff --git a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/services_wrapper.py b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/services_wrapper.py index 0b7599c25d0..a0746a1d568 100644 --- a/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/services_wrapper.py +++ b/src/command_modules/azure-cli-storage/azure/cli/command_modules/storage/services_wrapper.py @@ -3,11 +3,11 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- +from knack.util import CLIError + from azure.common import AzureHttpError from azure.cli.core.profiles import get_sdk, ResourceType -from knack.util import CLIError - from ._client_factory import generic_data_service_factory diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_actions.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_actions.py index 5c711d7865b..67044eb58ce 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_actions.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_actions.py @@ -5,13 +5,13 @@ import json import re +from six.moves.urllib.request import urlopen # pylint: disable=import-error from knack.util import CLIError + from azure.cli.core.commands.parameters import get_one_of_subscription_locations from azure.cli.core.commands.arm import resource_exists -from six.moves.urllib.request import urlopen # pylint: disable=import-error - from ._client_factory import _compute_client_factory diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_params.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_params.py index 984ebcef0f1..e16e04cb14d 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_params.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_params.py @@ -6,6 +6,8 @@ # pylint: disable=line-too-long from argcomplete.completers import FilesCompleter +from knack.arguments import CLIArgumentType + from azure.mgmt.compute.models import CachingTypes, UpgradeMode from azure.mgmt.storage.models import SkuName @@ -21,8 +23,6 @@ from azure.cli.command_modules.vm._validators import ( validate_nsg_name, validate_vm_nics, validate_vm_nic, validate_vm_disk, validate_asg_names_or_ids) -from knack.arguments import CLIArgumentType - # REUSABLE ARGUMENT DEFINITIONS diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_validators.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_validators.py index 4b2b3a01a01..c90baaf4ee4 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_validators.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/_validators.py @@ -8,6 +8,9 @@ import os import re +from knack.log import get_logger +from knack.util import CLIError + from azure.cli.core.commands.validators import ( get_default_location_from_resource_group, validate_file_or_dict, validate_parameter_set, validate_tags) from azure.cli.core.util import hash_string @@ -15,9 +18,6 @@ from azure.cli.command_modules.vm._template_builder import StorageProfile import azure.cli.core.keys as keys -from knack.log import get_logger -from knack.util import CLIError - from ._client_factory import _compute_client_factory logger = get_logger(__name__) @@ -251,6 +251,7 @@ def _get_image_plan_info_if_exists(cmd, namespace): "will be skipped", namespace.image, ex.message) +# pylint: disable=inconsistent-return-statements def _get_storage_profile_description(profile): if profile == StorageProfile.SACustomImage: return 'create unmanaged OS disk created from generalized VHD' diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/custom.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/custom.py index 45fe25edccb..d11043e0ef3 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/custom.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/custom.py @@ -16,6 +16,12 @@ from urlparse import urlparse # pylint: disable=import-error from six.moves.urllib.request import urlopen # noqa, pylint: disable=import-error,unused-import + +from knack.log import get_logger +from knack.util import CLIError + +from msrestazure.tools import resource_id, is_valid_resource_id, parse_resource_id + from azure.cli.command_modules.vm._validators import _get_resource_group_from_vault_name from azure.cli.core.commands.validators import validate_file_or_dict from azure.keyvault import KeyVaultId @@ -24,11 +30,6 @@ from azure.cli.core.commands.client_factory import get_mgmt_service_client, get_data_service_client from azure.cli.core.profiles import ResourceType -from knack.log import get_logger -from knack.util import CLIError - -from msrestazure.tools import resource_id, is_valid_resource_id, parse_resource_id - from ._vm_utils import read_content_if_is_file from ._vm_diagnostics_templates import get_default_diag_config @@ -834,6 +835,7 @@ def _set_availset(cmd, resource_group_name, name, **kwargs): return _compute_client_factory(cmd.cli_ctx).availability_sets.create_or_update(resource_group_name, name, **kwargs) +# pylint: disable=inconsistent-return-statements def convert_av_set_to_managed_disk(cmd, resource_group_name, availability_set_name): av_set = _get_availset(cmd, resource_group_name, availability_set_name) if av_set.sku.name != 'Aligned': @@ -1036,7 +1038,7 @@ def show_default_diagnostics_configuration(is_windows_os=False): # LAD and WAD are not consistent on sas token format. Call it out here "storageAccountSasToken": "__SAS_TOKEN_{}__".format("WITH_LEADING_QUESTION_MARK" if is_windows_os else "WITHOUT_LEADING_QUESTION_MARK") }, indent=2) - logger.warning('Protected settings with storage account info is required to work with the default configurations, e.g. \n' + protected_settings_info) + logger.warning('Protected settings with storage account info is required to work with the default configurations, e.g. \n%s', protected_settings_info) return public_settings # endregion @@ -1941,6 +1943,7 @@ def restart_vmss(cmd, resource_group_name, vm_scale_set_name, instance_ids=None, raw=no_wait) +# pylint: disable=inconsistent-return-statements def scale_vmss(cmd, resource_group_name, vm_scale_set_name, new_capacity, no_wait=False): VirtualMachineScaleSet = cmd.get_models('VirtualMachineScaleSet') client = _compute_client_factory(cmd.cli_ctx) @@ -2086,6 +2089,7 @@ def delete_vmss_extension(cmd, resource_group_name, vmss_name, extension_name): return client.virtual_machine_scale_sets.create_or_update(resource_group_name, vmss_name, vmss) +# pylint: disable=inconsistent-return-statements def get_vmss_extension(cmd, resource_group_name, vmss_name, extension_name): client = _compute_client_factory(cmd.cli_ctx) vmss = client.virtual_machine_scale_sets.get(resource_group_name, vmss_name) diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_commands.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_commands.py index 41ab2a82057..b73536e13fd 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_commands.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_commands.py @@ -641,7 +641,7 @@ def test_vm_availset(self, resource_group): checks=self.check('tags.test', 'success')) self.cmd('vm availability-set list -g {rg}', checks=[ self.check('length(@)', 1), - self.check('[0].name','{availset}') + self.check('[0].name', '{availset}') ]) self.cmd('vm availability-set list-sizes -g {rg} -n {availset}', checks=self.check('type(@)', 'array')) @@ -1035,7 +1035,7 @@ def test_vm_create_existing_ids_options(self, resource_group, storage_account): subscription_id = self.get_subscription_id() - self.kwargs.update({ + self.kwargs.update({ 'availset': 'vrfavailset', 'pubip': 'vrfpubip', 'vnet': 'vrfvnet', @@ -1625,8 +1625,8 @@ def test_vmss_vms(self, resource_group): instance_list = self.cmd('vmss list-instances --resource-group {rg} --name {vmss}', checks=[ self.check('type(@)', 'array'), - #self.check('length(@)', '{count}'), - #self.check("[].name.starts_with(@, '{vmss}')", [True * '{count}']) + self.check('length(@)', '{count}'), + self.check("[].name.starts_with(@, '{vmss}')", [True * '{count}']) ]).get_output_in_json() self.kwargs['instance_ids'] = [x['instanceId'] for x in instance_list] @@ -1714,7 +1714,7 @@ class VMSSILBTest(ScenarioTest): def test_vmss_with_ilb(self, resource_group): self.kwargs.update({'vmss': 'vmss1'}) - + self.cmd('vmss create -g {rg} -n {vmss} --admin-username admin123 --admin-password PasswordPassword1! --image centos --instance-count 1 --public-ip-address ""') # list connection information should fail with self.assertRaises(CLIError) as err: @@ -2017,7 +2017,7 @@ def test_run_command_e2e(self, resource_group, resource_group_location): 'vm': 'test-run-command-vm', 'loc': resource_group_location }) - + self.cmd('vm run-command list -l {loc}') self.cmd('vm run-command show --command-id RunShellScript -l {loc}') public_ip = self.cmd('vm create -g {rg} -n {vm} --image ubuntults --admin-username clitest1 --admin-password Test12345678!!').get_output_in_json()['publicIpAddress'] diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_defaults.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_defaults.py index 3b1bafe4fdf..fb67bcda9bb 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_defaults.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_defaults.py @@ -3,6 +3,8 @@ # Licensed under the MIT License. See License.txt in the project root for license information. # -------------------------------------------------------------------------------------------- +# pylint: disable=line-too-long, too-many-lines + import argparse import unittest try: @@ -17,8 +19,6 @@ _validate_vm_create_storage_account, _validate_vm_vmss_create_auth) -# pylint: disable=line-too-long -# pylint: disable=too-many-lines def _get_test_cmd(): from azure.cli.testsdk import TestCli diff --git a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_parameters.py b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_parameters.py index bfbe5b87077..8eea6599828 100644 --- a/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_parameters.py +++ b/src/command_modules/azure-cli-vm/azure/cli/command_modules/vm/tests/test_vm_parameters.py @@ -10,20 +10,21 @@ import mock -#def mock_echo_args(command_name, parameters): -# from azure.cli.testsdk import TestCli -# try: -# argv = ' '.join((command_name, parameters)).split() -# cli = TestCli() -# cli.invoke(argv) -# command_table = cli.invocation.commands_loader.command_table -# prefunc = command_table[command_name].handler -# command_table[command_name].handler = lambda args: args -# cli.invoke(argv) -# test = 'banoodle' -# return parsed_namespace -# finally: -# command_table[command_name].handler = prefunc +def mock_echo_args(command_name, parameters): + from azure.cli.testsdk import TestCli + try: + # TODO: continue work on this... + argv = ' '.join((command_name, parameters)).split() + cli = TestCli() + cli.invoke(argv) + command_table = cli.invocation.commands_loader.command_table + prefunc = command_table[command_name].handler + command_table[command_name].handler = lambda args: args + cli.invoke(argv) + parsed_namespace = None # continue this too... + return parsed_namespace + finally: + command_table[command_name].handler = prefunc class TestVMValidators(unittest.TestCase): @@ -72,7 +73,7 @@ def _get_test_cmd(): self.assertEqual(ns.nics[1], nic2_expected) -#class TestArgumentParser(unittest.TestCase): +# class TestArgumentParser(unittest.TestCase): # @classmethod # def setUpClass(cls): # pass