diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web.rb old mode 100644 new mode 100755 index 9d770cab2c..41051e2de4 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web.rb @@ -33,140 +33,131 @@ module Azure::ARM::Web autoload :WebSiteManagementClient, 'generated/azure_mgmt_web/web_site_management_client.rb' module Models - autoload :BackupSchedule, 'generated/azure_mgmt_web/models/backup_schedule.rb' - autoload :GeoRegionCollection, 'generated/azure_mgmt_web/models/geo_region_collection.rb' - autoload :CsmOperationCollection, 'generated/azure_mgmt_web/models/csm_operation_collection.rb' + autoload :ResourceNameAvailabilityRequest, 'generated/azure_mgmt_web/models/resource_name_availability_request.rb' + autoload :AppServiceCertificate, 'generated/azure_mgmt_web/models/app_service_certificate.rb' + autoload :SkuInfos, 'generated/azure_mgmt_web/models/sku_infos.rb' autoload :AppServiceCertificateCollection, 'generated/azure_mgmt_web/models/app_service_certificate_collection.rb' - autoload :Recommendation, 'generated/azure_mgmt_web/models/recommendation.rb' - autoload :ResourceMetricDefinitionCollection, 'generated/azure_mgmt_web/models/resource_metric_definition_collection.rb' - autoload :RecommendationRule, 'generated/azure_mgmt_web/models/recommendation_rule.rb' - autoload :WebAppInstanceCollection, 'generated/azure_mgmt_web/models/web_app_instance_collection.rb' - autoload :Capability, 'generated/azure_mgmt_web/models/capability.rb' - autoload :NameIdentifier, 'generated/azure_mgmt_web/models/name_identifier.rb' - autoload :CsmMoveResourceEnvelope, 'generated/azure_mgmt_web/models/csm_move_resource_envelope.rb' autoload :ResourceMetricAvailability, 'generated/azure_mgmt_web/models/resource_metric_availability.rb' - autoload :VirtualNetworkProfile, 'generated/azure_mgmt_web/models/virtual_network_profile.rb' + autoload :GeoRegionCollection, 'generated/azure_mgmt_web/models/geo_region_collection.rb' + autoload :AppServiceCertificateOrderCollection, 'generated/azure_mgmt_web/models/app_service_certificate_order_collection.rb' + autoload :SkuCapacity, 'generated/azure_mgmt_web/models/sku_capacity.rb' + autoload :SiteCloneabilityCriterion, 'generated/azure_mgmt_web/models/site_cloneability_criterion.rb' + autoload :GlobalCsmSkuDescription, 'generated/azure_mgmt_web/models/global_csm_sku_description.rb' + autoload :VirtualIPMapping, 'generated/azure_mgmt_web/models/virtual_ipmapping.rb' + autoload :ResourceMetric, 'generated/azure_mgmt_web/models/resource_metric.rb' autoload :Resource, 'generated/azure_mgmt_web/models/resource.rb' - autoload :PerfMonCounterCollection, 'generated/azure_mgmt_web/models/perf_mon_counter_collection.rb' + autoload :PremierAddOnOfferCollection, 'generated/azure_mgmt_web/models/premier_add_on_offer_collection.rb' autoload :SiteSealRequest, 'generated/azure_mgmt_web/models/site_seal_request.rb' - autoload :SkuCapacity, 'generated/azure_mgmt_web/models/sku_capacity.rb' + autoload :ResourceNameAvailability, 'generated/azure_mgmt_web/models/resource_name_availability.rb' autoload :Contact, 'generated/azure_mgmt_web/models/contact.rb' - autoload :GlobalCsmSkuDescription, 'generated/azure_mgmt_web/models/global_csm_sku_description.rb' + autoload :ResourceMetricValue, 'generated/azure_mgmt_web/models/resource_metric_value.rb' autoload :DomainPurchaseConsent, 'generated/azure_mgmt_web/models/domain_purchase_consent.rb' - autoload :SiteConfigResourceCollection, 'generated/azure_mgmt_web/models/site_config_resource_collection.rb' + autoload :CertificateDetails, 'generated/azure_mgmt_web/models/certificate_details.rb' autoload :DomainAvailablilityCheckResult, 'generated/azure_mgmt_web/models/domain_availablility_check_result.rb' - autoload :PremierAddOnOfferCollection, 'generated/azure_mgmt_web/models/premier_add_on_offer_collection.rb' + autoload :SlotDifferenceCollection, 'generated/azure_mgmt_web/models/slot_difference_collection.rb' autoload :DomainControlCenterSsoRequest, 'generated/azure_mgmt_web/models/domain_control_center_sso_request.rb' - autoload :ResourceNameAvailability, 'generated/azure_mgmt_web/models/resource_name_availability.rb' + autoload :SourceControlCollection, 'generated/azure_mgmt_web/models/source_control_collection.rb' autoload :DomainOwnershipIdentifierCollection, 'generated/azure_mgmt_web/models/domain_ownership_identifier_collection.rb' - autoload :ResourceNameAvailabilityRequest, 'generated/azure_mgmt_web/models/resource_name_availability_request.rb' + autoload :SnapshotCollection, 'generated/azure_mgmt_web/models/snapshot_collection.rb' autoload :NameIdentifierCollection, 'generated/azure_mgmt_web/models/name_identifier_collection.rb' - autoload :SkuInfos, 'generated/azure_mgmt_web/models/sku_infos.rb' + autoload :ValidateRequest, 'generated/azure_mgmt_web/models/validate_request.rb' autoload :TldLegalAgreementCollection, 'generated/azure_mgmt_web/models/tld_legal_agreement_collection.rb' - autoload :SiteCloneability, 'generated/azure_mgmt_web/models/site_cloneability.rb' + autoload :ValidateResponseError, 'generated/azure_mgmt_web/models/validate_response_error.rb' autoload :TopLevelDomainAgreementOption, 'generated/azure_mgmt_web/models/top_level_domain_agreement_option.rb' - autoload :SourceControlCollection, 'generated/azure_mgmt_web/models/source_control_collection.rb' + autoload :ValidateResponse, 'generated/azure_mgmt_web/models/validate_response.rb' autoload :HostingEnvironmentProfile, 'generated/azure_mgmt_web/models/hosting_environment_profile.rb' - autoload :SiteCloneabilityCriterion, 'generated/azure_mgmt_web/models/site_cloneability_criterion.rb' + autoload :FileSystemApplicationLogsConfig, 'generated/azure_mgmt_web/models/file_system_application_logs_config.rb' autoload :CertificateCollection, 'generated/azure_mgmt_web/models/certificate_collection.rb' - autoload :ValidateRequest, 'generated/azure_mgmt_web/models/validate_request.rb' + autoload :AzureTableStorageApplicationLogsConfig, 'generated/azure_mgmt_web/models/azure_table_storage_application_logs_config.rb' autoload :AutoHealCustomAction, 'generated/azure_mgmt_web/models/auto_heal_custom_action.rb' - autoload :ValidateResponseError, 'generated/azure_mgmt_web/models/validate_response_error.rb' + autoload :AzureBlobStorageApplicationLogsConfig, 'generated/azure_mgmt_web/models/azure_blob_storage_application_logs_config.rb' autoload :RequestsBasedTrigger, 'generated/azure_mgmt_web/models/requests_based_trigger.rb' - autoload :ValidateResponse, 'generated/azure_mgmt_web/models/validate_response.rb' + autoload :ApplicationLogsConfig, 'generated/azure_mgmt_web/models/application_logs_config.rb' autoload :SlowRequestsBasedTrigger, 'generated/azure_mgmt_web/models/slow_requests_based_trigger.rb' - autoload :SlotDifferenceCollection, 'generated/azure_mgmt_web/models/slot_difference_collection.rb' + autoload :AzureBlobStorageHttpLogsConfig, 'generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb' autoload :AutoHealRules, 'generated/azure_mgmt_web/models/auto_heal_rules.rb' - autoload :SnapshotCollection, 'generated/azure_mgmt_web/models/snapshot_collection.rb' + autoload :DatabaseBackupSetting, 'generated/azure_mgmt_web/models/database_backup_setting.rb' autoload :ConnStringInfo, 'generated/azure_mgmt_web/models/conn_string_info.rb' - autoload :SnapshotRecoveryTarget, 'generated/azure_mgmt_web/models/snapshot_recovery_target.rb' + autoload :WebAppCollection, 'generated/azure_mgmt_web/models/web_app_collection.rb' autoload :HostNameSslState, 'generated/azure_mgmt_web/models/host_name_ssl_state.rb' - autoload :FileSystemApplicationLogsConfig, 'generated/azure_mgmt_web/models/file_system_application_logs_config.rb' + autoload :BackupItemCollection, 'generated/azure_mgmt_web/models/backup_item_collection.rb' autoload :SiteMachineKey, 'generated/azure_mgmt_web/models/site_machine_key.rb' - autoload :AzureTableStorageApplicationLogsConfig, 'generated/azure_mgmt_web/models/azure_table_storage_application_logs_config.rb' + autoload :BackupSchedule, 'generated/azure_mgmt_web/models/backup_schedule.rb' autoload :VirtualDirectory, 'generated/azure_mgmt_web/models/virtual_directory.rb' - autoload :AzureBlobStorageApplicationLogsConfig, 'generated/azure_mgmt_web/models/azure_blob_storage_application_logs_config.rb' + autoload :SiteConfigResourceCollection, 'generated/azure_mgmt_web/models/site_config_resource_collection.rb' autoload :RampUpRule, 'generated/azure_mgmt_web/models/ramp_up_rule.rb' - autoload :ApplicationLogsConfig, 'generated/azure_mgmt_web/models/application_logs_config.rb' + autoload :ConnStringValueTypePair, 'generated/azure_mgmt_web/models/conn_string_value_type_pair.rb' autoload :SiteLimits, 'generated/azure_mgmt_web/models/site_limits.rb' - autoload :AzureBlobStorageHttpLogsConfig, 'generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb' autoload :IpSecurityRestriction, 'generated/azure_mgmt_web/models/ip_security_restriction.rb' - autoload :DatabaseBackupSetting, 'generated/azure_mgmt_web/models/database_backup_setting.rb' + autoload :CsmPublishingProfileOptions, 'generated/azure_mgmt_web/models/csm_publishing_profile_options.rb' autoload :SlotSwapStatus, 'generated/azure_mgmt_web/models/slot_swap_status.rb' - autoload :WebAppCollection, 'generated/azure_mgmt_web/models/web_app_collection.rb' + autoload :CsmSiteRecoveryEntity, 'generated/azure_mgmt_web/models/csm_site_recovery_entity.rb' autoload :DeletedWebAppCollection, 'generated/azure_mgmt_web/models/deleted_web_app_collection.rb' - autoload :BackupItemCollection, 'generated/azure_mgmt_web/models/backup_item_collection.rb' - autoload :Dimension, 'generated/azure_mgmt_web/models/dimension.rb' - autoload :AppServiceCertificate, 'generated/azure_mgmt_web/models/app_service_certificate.rb' - autoload :MetricSpecification, 'generated/azure_mgmt_web/models/metric_specification.rb' - autoload :CsmOperationDescriptionProperties, 'generated/azure_mgmt_web/models/csm_operation_description_properties.rb' - autoload :ConnStringValueTypePair, 'generated/azure_mgmt_web/models/conn_string_value_type_pair.rb' - autoload :CertificateDetails, 'generated/azure_mgmt_web/models/certificate_details.rb' - autoload :ResourceCollection, 'generated/azure_mgmt_web/models/resource_collection.rb' - autoload :ResourceMetricCollection, 'generated/azure_mgmt_web/models/resource_metric_collection.rb' - autoload :CsmPublishingProfileOptions, 'generated/azure_mgmt_web/models/csm_publishing_profile_options.rb' - autoload :ResourceMetric, 'generated/azure_mgmt_web/models/resource_metric.rb' autoload :CsmSlotEntity, 'generated/azure_mgmt_web/models/csm_slot_entity.rb' - autoload :Address, 'generated/azure_mgmt_web/models/address.rb' + autoload :RecommendationRule, 'generated/azure_mgmt_web/models/recommendation_rule.rb' autoload :LocalizableString, 'generated/azure_mgmt_web/models/localizable_string.rb' - autoload :ResourceMetricValue, 'generated/azure_mgmt_web/models/resource_metric_value.rb' + autoload :CsmMoveResourceEnvelope, 'generated/azure_mgmt_web/models/csm_move_resource_envelope.rb' autoload :CsmUsageQuota, 'generated/azure_mgmt_web/models/csm_usage_quota.rb' - autoload :ResourceMetricProperty, 'generated/azure_mgmt_web/models/resource_metric_property.rb' + autoload :SiteCloneability, 'generated/azure_mgmt_web/models/site_cloneability.rb' autoload :CsmUsageQuotaCollection, 'generated/azure_mgmt_web/models/csm_usage_quota_collection.rb' - autoload :TldLegalAgreement, 'generated/azure_mgmt_web/models/tld_legal_agreement.rb' + autoload :AddressResponse, 'generated/azure_mgmt_web/models/address_response.rb' autoload :ErrorEntity, 'generated/azure_mgmt_web/models/error_entity.rb' - autoload :TopLevelDomainCollection, 'generated/azure_mgmt_web/models/top_level_domain_collection.rb' + autoload :Address, 'generated/azure_mgmt_web/models/address.rb' + autoload :ResourceCollection, 'generated/azure_mgmt_web/models/resource_collection.rb' + autoload :VirtualNetworkProfile, 'generated/azure_mgmt_web/models/virtual_network_profile.rb' autoload :HybridConnectionCollection, 'generated/azure_mgmt_web/models/hybrid_connection_collection.rb' + autoload :WorkerPool, 'generated/azure_mgmt_web/models/worker_pool.rb' + autoload :DeploymentCollection, 'generated/azure_mgmt_web/models/deployment_collection.rb' + autoload :TldLegalAgreement, 'generated/azure_mgmt_web/models/tld_legal_agreement.rb' + autoload :EnabledConfig, 'generated/azure_mgmt_web/models/enabled_config.rb' + autoload :TopLevelDomainCollection, 'generated/azure_mgmt_web/models/top_level_domain_collection.rb' + autoload :FileSystemHttpLogsConfig, 'generated/azure_mgmt_web/models/file_system_http_logs_config.rb' autoload :ApiDefinitionInfo, 'generated/azure_mgmt_web/models/api_definition_info.rb' autoload :WorkerPoolCollection, 'generated/azure_mgmt_web/models/worker_pool_collection.rb' autoload :StatusCodesBasedTrigger, 'generated/azure_mgmt_web/models/status_codes_based_trigger.rb' - autoload :DeploymentCollection, 'generated/azure_mgmt_web/models/deployment_collection.rb' + autoload :HostNameBindingCollection, 'generated/azure_mgmt_web/models/host_name_binding_collection.rb' autoload :CloningInfo, 'generated/azure_mgmt_web/models/cloning_info.rb' - autoload :EnabledConfig, 'generated/azure_mgmt_web/models/enabled_config.rb' + autoload :HttpLogsConfig, 'generated/azure_mgmt_web/models/http_logs_config.rb' autoload :NameValuePair, 'generated/azure_mgmt_web/models/name_value_pair.rb' - autoload :FileSystemHttpLogsConfig, 'generated/azure_mgmt_web/models/file_system_http_logs_config.rb' - autoload :VirtualApplication, 'generated/azure_mgmt_web/models/virtual_application.rb' autoload :UsageCollection, 'generated/azure_mgmt_web/models/usage_collection.rb' - autoload :PublicCertificateCollection, 'generated/azure_mgmt_web/models/public_certificate_collection.rb' - autoload :HostNameBindingCollection, 'generated/azure_mgmt_web/models/host_name_binding_collection.rb' - autoload :AddressResponse, 'generated/azure_mgmt_web/models/address_response.rb' - autoload :HttpLogsConfig, 'generated/azure_mgmt_web/models/http_logs_config.rb' - autoload :MetricAvailability, 'generated/azure_mgmt_web/models/metric_availability.rb' + autoload :VirtualApplication, 'generated/azure_mgmt_web/models/virtual_application.rb' autoload :StampCapacityCollection, 'generated/azure_mgmt_web/models/stamp_capacity_collection.rb' - autoload :CsmOperationDescription, 'generated/azure_mgmt_web/models/csm_operation_description.rb' + autoload :PushSettings, 'generated/azure_mgmt_web/models/push_settings.rb' autoload :SkuInfoCollection, 'generated/azure_mgmt_web/models/sku_info_collection.rb' - autoload :ProxyOnlyResource, 'generated/azure_mgmt_web/models/proxy_only_resource.rb' + autoload :ResourceMetricCollection, 'generated/azure_mgmt_web/models/resource_metric_collection.rb' + autoload :IdentifierCollection, 'generated/azure_mgmt_web/models/identifier_collection.rb' + autoload :Capability, 'generated/azure_mgmt_web/models/capability.rb' autoload :SkuInfo, 'generated/azure_mgmt_web/models/sku_info.rb' + autoload :NameIdentifier, 'generated/azure_mgmt_web/models/name_identifier.rb' + autoload :MetricAvailabilily, 'generated/azure_mgmt_web/models/metric_availabilily.rb' autoload :HostName, 'generated/azure_mgmt_web/models/host_name.rb' - autoload :IdentifierCollection, 'generated/azure_mgmt_web/models/identifier_collection.rb' + autoload :HostingEnvironmentDiagnostics, 'generated/azure_mgmt_web/models/hosting_environment_diagnostics.rb' autoload :DomainRecommendationSearchParameters, 'generated/azure_mgmt_web/models/domain_recommendation_search_parameters.rb' - autoload :MetricAvailabilily, 'generated/azure_mgmt_web/models/metric_availabilily.rb' - autoload :VirtualIPMapping, 'generated/azure_mgmt_web/models/virtual_ipmapping.rb' - autoload :MSDeployLogEntry, 'generated/azure_mgmt_web/models/msdeploy_log_entry.rb' + autoload :VnetInfo, 'generated/azure_mgmt_web/models/vnet_info.rb' + autoload :StampCapacity, 'generated/azure_mgmt_web/models/stamp_capacity.rb' + autoload :AppServicePlanCollection, 'generated/azure_mgmt_web/models/app_service_plan_collection.rb' autoload :AutoHealTriggers, 'generated/azure_mgmt_web/models/auto_heal_triggers.rb' - autoload :HostingEnvironmentDiagnostics, 'generated/azure_mgmt_web/models/hosting_environment_diagnostics.rb' + autoload :SkuDescription, 'generated/azure_mgmt_web/models/sku_description.rb' autoload :HandlerMapping, 'generated/azure_mgmt_web/models/handler_mapping.rb' - autoload :AppServicePlanCollection, 'generated/azure_mgmt_web/models/app_service_plan_collection.rb' + autoload :Operation, 'generated/azure_mgmt_web/models/operation.rb' autoload :SiteConfig, 'generated/azure_mgmt_web/models/site_config.rb' - autoload :SkuDescription, 'generated/azure_mgmt_web/models/sku_description.rb' - autoload :ServiceSpecification, 'generated/azure_mgmt_web/models/service_specification.rb' + autoload :PerfMonSample, 'generated/azure_mgmt_web/models/perf_mon_sample.rb' + autoload :WebAppInstanceCollection, 'generated/azure_mgmt_web/models/web_app_instance_collection.rb' + autoload :PerfMonSet, 'generated/azure_mgmt_web/models/perf_mon_set.rb' + autoload :DomainCollection, 'generated/azure_mgmt_web/models/domain_collection.rb' + autoload :PerfMonResponse, 'generated/azure_mgmt_web/models/perf_mon_response.rb' + autoload :AutoHealActions, 'generated/azure_mgmt_web/models/auto_heal_actions.rb' + autoload :PerfMonCounterCollection, 'generated/azure_mgmt_web/models/perf_mon_counter_collection.rb' + autoload :Experiments, 'generated/azure_mgmt_web/models/experiments.rb' autoload :AppServiceEnvironmentCollection, 'generated/azure_mgmt_web/models/app_service_environment_collection.rb' autoload :SiteSeal, 'generated/azure_mgmt_web/models/site_seal.rb' autoload :AppServiceEnvironment, 'generated/azure_mgmt_web/models/app_service_environment.rb' - autoload :ResourceMetricName, 'generated/azure_mgmt_web/models/resource_metric_name.rb' - autoload :NetworkAccessControlEntry, 'generated/azure_mgmt_web/models/network_access_control_entry.rb' autoload :CorsSettings, 'generated/azure_mgmt_web/models/cors_settings.rb' - autoload :StampCapacity, 'generated/azure_mgmt_web/models/stamp_capacity.rb' - autoload :CsmOperationDisplay, 'generated/azure_mgmt_web/models/csm_operation_display.rb' - autoload :WorkerPool, 'generated/azure_mgmt_web/models/worker_pool.rb' - autoload :DomainCollection, 'generated/azure_mgmt_web/models/domain_collection.rb' - autoload :Operation, 'generated/azure_mgmt_web/models/operation.rb' - autoload :Experiments, 'generated/azure_mgmt_web/models/experiments.rb' - autoload :PerfMonSample, 'generated/azure_mgmt_web/models/perf_mon_sample.rb' - autoload :AutoHealActions, 'generated/azure_mgmt_web/models/auto_heal_actions.rb' - autoload :PerfMonSet, 'generated/azure_mgmt_web/models/perf_mon_set.rb' - autoload :AppServiceCertificateOrderCollection, 'generated/azure_mgmt_web/models/app_service_certificate_order_collection.rb' - autoload :PerfMonResponse, 'generated/azure_mgmt_web/models/perf_mon_response.rb' + autoload :NetworkAccessControlEntry, 'generated/azure_mgmt_web/models/network_access_control_entry.rb' + autoload :ResourceMetricDefinitionCollection, 'generated/azure_mgmt_web/models/resource_metric_definition_collection.rb' + autoload :ResourceMetricName, 'generated/azure_mgmt_web/models/resource_metric_name.rb' + autoload :Recommendation, 'generated/azure_mgmt_web/models/recommendation.rb' + autoload :ResourceMetricProperty, 'generated/azure_mgmt_web/models/resource_metric_property.rb' autoload :AppServiceCertificateResource, 'generated/azure_mgmt_web/models/app_service_certificate_resource.rb' autoload :AppServiceCertificateOrder, 'generated/azure_mgmt_web/models/app_service_certificate_order.rb' autoload :CertificateEmail, 'generated/azure_mgmt_web/models/certificate_email.rb' @@ -177,15 +168,11 @@ module Models autoload :DomainOwnershipIdentifier, 'generated/azure_mgmt_web/models/domain_ownership_identifier.rb' autoload :TopLevelDomain, 'generated/azure_mgmt_web/models/top_level_domain.rb' autoload :Certificate, 'generated/azure_mgmt_web/models/certificate.rb' - autoload :PushSettings, 'generated/azure_mgmt_web/models/push_settings.rb' autoload :DeletedSite, 'generated/azure_mgmt_web/models/deleted_site.rb' autoload :GeoRegion, 'generated/azure_mgmt_web/models/geo_region.rb' autoload :PremierAddOnOffer, 'generated/azure_mgmt_web/models/premier_add_on_offer.rb' autoload :SourceControl, 'generated/azure_mgmt_web/models/source_control.rb' autoload :User, 'generated/azure_mgmt_web/models/user.rb' - autoload :VnetParameters, 'generated/azure_mgmt_web/models/vnet_parameters.rb' - autoload :VnetValidationTestFailure, 'generated/azure_mgmt_web/models/vnet_validation_test_failure.rb' - autoload :VnetValidationFailureDetails, 'generated/azure_mgmt_web/models/vnet_validation_failure_details.rb' autoload :BackupItem, 'generated/azure_mgmt_web/models/backup_item.rb' autoload :BackupRequest, 'generated/azure_mgmt_web/models/backup_request.rb' autoload :ConnectionStringDictionary, 'generated/azure_mgmt_web/models/connection_string_dictionary.rb' @@ -195,18 +182,14 @@ module Models autoload :HybridConnection, 'generated/azure_mgmt_web/models/hybrid_connection.rb' autoload :HybridConnectionKey, 'generated/azure_mgmt_web/models/hybrid_connection_key.rb' autoload :Identifier, 'generated/azure_mgmt_web/models/identifier.rb' - autoload :MSDeploy, 'generated/azure_mgmt_web/models/msdeploy.rb' - autoload :MSDeployLog, 'generated/azure_mgmt_web/models/msdeploy_log.rb' - autoload :MSDeployStatus, 'generated/azure_mgmt_web/models/msdeploy_status.rb' autoload :MigrateMySqlRequest, 'generated/azure_mgmt_web/models/migrate_my_sql_request.rb' autoload :MigrateMySqlStatus, 'generated/azure_mgmt_web/models/migrate_my_sql_status.rb' autoload :VnetRoute, 'generated/azure_mgmt_web/models/vnet_route.rb' - autoload :VnetInfo, 'generated/azure_mgmt_web/models/vnet_info.rb' autoload :RelayServiceConnectionEntity, 'generated/azure_mgmt_web/models/relay_service_connection_entity.rb' autoload :NetworkFeatures, 'generated/azure_mgmt_web/models/network_features.rb' autoload :PremierAddOn, 'generated/azure_mgmt_web/models/premier_add_on.rb' - autoload :PublicCertificate, 'generated/azure_mgmt_web/models/public_certificate.rb' autoload :RecoverResponse, 'generated/azure_mgmt_web/models/recover_response.rb' + autoload :ResourceHealthMetadata, 'generated/azure_mgmt_web/models/resource_health_metadata.rb' autoload :ResourceMetricDefinition, 'generated/azure_mgmt_web/models/resource_metric_definition.rb' autoload :RestoreRequest, 'generated/azure_mgmt_web/models/restore_request.rb' autoload :RestoreResponse, 'generated/azure_mgmt_web/models/restore_response.rb' @@ -221,7 +204,6 @@ module Models autoload :SlotConfigNamesResource, 'generated/azure_mgmt_web/models/slot_config_names_resource.rb' autoload :SlotDifference, 'generated/azure_mgmt_web/models/slot_difference.rb' autoload :Snapshot, 'generated/azure_mgmt_web/models/snapshot.rb' - autoload :SnapshotRecoveryRequest, 'generated/azure_mgmt_web/models/snapshot_recovery_request.rb' autoload :StorageMigrationOptions, 'generated/azure_mgmt_web/models/storage_migration_options.rb' autoload :StorageMigrationResponse, 'generated/azure_mgmt_web/models/storage_migration_response.rb' autoload :StringDictionary, 'generated/azure_mgmt_web/models/string_dictionary.rb' @@ -266,12 +248,8 @@ module Models autoload :BackupRestoreOperationType, 'generated/azure_mgmt_web/models/backup_restore_operation_type.rb' autoload :PublishingProfileFormat, 'generated/azure_mgmt_web/models/publishing_profile_format.rb' autoload :DnsVerificationTestResult, 'generated/azure_mgmt_web/models/dns_verification_test_result.rb' - autoload :MSDeployLogEntryType, 'generated/azure_mgmt_web/models/msdeploy_log_entry_type.rb' - autoload :MSDeployProvisioningState, 'generated/azure_mgmt_web/models/msdeploy_provisioning_state.rb' - autoload :MySqlMigrationType, 'generated/azure_mgmt_web/models/my_sql_migration_type.rb' autoload :OperationStatus, 'generated/azure_mgmt_web/models/operation_status.rb' autoload :RouteType, 'generated/azure_mgmt_web/models/route_type.rb' - autoload :PublicCertificateLocation, 'generated/azure_mgmt_web/models/public_certificate_location.rb' autoload :UnauthenticatedClientAction, 'generated/azure_mgmt_web/models/unauthenticated_client_action.rb' autoload :BuiltInAuthenticationProvider, 'generated/azure_mgmt_web/models/built_in_authentication_provider.rb' autoload :CloneAbilityResult, 'generated/azure_mgmt_web/models/clone_ability_result.rb' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_certificate_orders.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_certificate_orders.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_environments.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_environments.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_plans.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/app_service_plans.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/certificates.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/certificates.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/deleted_web_apps.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/deleted_web_apps.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/domains.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/domains.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/access_control_entry_action.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/access_control_entry_action.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/address.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/address.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/address_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/address_response.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/api_definition_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/api_definition_info.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order.rb old mode 100644 new mode 100755 index fc1400e782..a8b77d707a --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order.rb @@ -107,7 +107,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -129,7 +128,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_order_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_resource.rb old mode 100644 new mode 100755 index 27abcd223f..b29aa8d2f1 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_certificate_resource.rb @@ -52,7 +52,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -74,7 +73,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_resource.rb old mode 100644 new mode 100755 index dbf167d12a..626504688c --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_environment_resource.rb @@ -170,7 +170,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -192,7 +191,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan.rb old mode 100644 new mode 100755 index 3ddf7582f9..cb0bb82f98 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan.rb @@ -92,7 +92,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -114,7 +113,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan_restrictions.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/app_service_plan_restrictions.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/application_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/application_logs_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_action_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_action_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_actions.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_actions.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_custom_action.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_custom_action.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_rules.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_rules.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_triggers.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/auto_heal_triggers.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_application_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_application_logs_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb old mode 100644 new mode 100755 index b38a1f3e23..d84ec6c101 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_blob_storage_http_logs_config.rb @@ -22,8 +22,7 @@ class AzureBlobStorageHttpLogsConfig # 0 or lower means no retention. attr_accessor :retention_in_days - # @return [Boolean] True if configuration is enabled, false if it is - # disabled and null if configuration is not set. + # @return [Boolean] Enabled. attr_accessor :enabled diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_resource_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_resource_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_table_storage_application_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/azure_table_storage_application_logs_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item.rb old mode 100644 new mode 100755 index 4aae341795..cbd0b21cd4 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item.rb @@ -8,7 +8,7 @@ module Models # # Backup description. # - class BackupItem < MsRestAzure::ProxyOnlyResource + class BackupItem < MsRestAzure::Resource include MsRestAzure @@ -87,7 +87,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -100,14 +99,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, backup_id: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_item_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_request.rb old mode 100644 new mode 100755 index 1e4a7c5629..99ac8081be --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_request.rb @@ -8,7 +8,7 @@ module Models # # Description of a backup which will be performed. # - class BackupRequest < MsRestAzure::ProxyOnlyResource + class BackupRequest < MsRestAzure::Resource include MsRestAzure @@ -33,7 +33,7 @@ class BackupRequest < MsRestAzure::ProxyOnlyResource attr_accessor :databases # @return [BackupRestoreOperationType] Type of the backup. Possible - # values include: 'Default', 'Clone', 'Relocation', 'Snapshot' + # values include: 'Default', 'Clone', 'Relocation' attr_accessor :backup_request_type @@ -59,7 +59,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -72,14 +71,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, backup_request_name: { required: false, serialized_name: 'properties.name', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_restore_operation_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_restore_operation_type.rb old mode 100644 new mode 100755 index bd4b6a4826..33c69bd33d --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_restore_operation_type.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_restore_operation_type.rb @@ -12,7 +12,6 @@ module BackupRestoreOperationType Default = "Default" Clone = "Clone" Relocation = "Relocation" - Snapshot = "Snapshot" end end end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_schedule.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/backup_schedule.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/built_in_authentication_provider.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/built_in_authentication_provider.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/capability.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/capability.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate.rb old mode 100644 new mode 100755 index b6a20d870a..6cbf43fed5 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate.rb @@ -108,7 +108,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -130,7 +129,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_details.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_details.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_email.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_email.rb old mode 100644 new mode 100755 index a1aa97ab53..64f10583a3 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_email.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_email.rb @@ -8,7 +8,7 @@ module Models # # SSL certificate email. # - class CertificateEmail < MsRestAzure::ProxyOnlyResource + class CertificateEmail < MsRestAzure::Resource include MsRestAzure @@ -42,7 +42,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -55,14 +54,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, email_id: { required: false, serialized_name: 'properties.emailId', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action.rb old mode 100644 new mode 100755 index b6286be8fc..cba2c9202c --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action.rb @@ -48,7 +48,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -70,7 +69,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_action_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_order_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_product_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/certificate_product_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/channels.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/channels.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/check_name_resource_types.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/check_name_resource_types.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/clone_ability_result.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/clone_ability_result.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/cloning_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/cloning_info.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/compute_mode_options.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/compute_mode_options.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/conn_string_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/conn_string_info.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/conn_string_value_type_pair.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/conn_string_value_type_pair.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_dictionary.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_dictionary.rb old mode 100644 new mode 100755 index 48066e8fb9..a675ecf57c --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_dictionary.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_dictionary.rb @@ -8,7 +8,7 @@ module Models # # String dictionary resource. # - class ConnectionStringDictionary < MsRestAzure::ProxyOnlyResource + class ConnectionStringDictionary < MsRestAzure::Resource include MsRestAzure @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -52,14 +51,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, properties: { required: false, serialized_name: 'properties', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/connection_string_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/contact.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/contact.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/cors_settings.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/cors_settings.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_move_resource_envelope.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_move_resource_envelope.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_collection.rb deleted file mode 100644 index bdf47a3d48..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_collection.rb +++ /dev/null @@ -1,94 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Collection of Azure resource manager operation metadata. - # - class CsmOperationCollection - - include MsRestAzure - - include MsRest::JSONable - # @return [Array] Collection of resources. - attr_accessor :value - - # @return [String] Link to next page of resources. - attr_accessor :next_link - - # return [Proc] with next page method call. - attr_accessor :next_method - - # - # Gets the rest of the items for the request, enabling auto-pagination. - # - # @return [Array] operation results. - # - def get_all_items - items = @value - page = self - while page.next_link != nil do - page = page.get_next_page - items.concat(page.value) - end - items - end - - # - # Gets the next page of results. - # - # @return [CsmOperationCollection] with next page content. - # - def get_next_page - response = @next_method.call(@next_link).value! unless @next_method.nil? - unless response.nil? - @next_link = response.body.next_link - @value = response.body.value - self - end - end - - # - # Mapper for CsmOperationCollection class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'CsmOperationCollection', - type: { - name: 'Composite', - class_name: 'CsmOperationCollection', - model_properties: { - value: { - required: true, - serialized_name: 'value', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'CsmOperationDescriptionElementType', - type: { - name: 'Composite', - class_name: 'CsmOperationDescription' - } - } - } - }, - next_link: { - required: false, - serialized_name: 'nextLink', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description.rb deleted file mode 100644 index d40f5f6a5d..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description.rb +++ /dev/null @@ -1,78 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class CsmOperationDescription - - include MsRestAzure - - include MsRest::JSONable - # @return [String] - attr_accessor :name - - # @return [CsmOperationDisplay] - attr_accessor :display - - # @return [String] - attr_accessor :origin - - # @return [CsmOperationDescriptionProperties] - attr_accessor :properties - - - # - # Mapper for CsmOperationDescription class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'CsmOperationDescription', - type: { - name: 'Composite', - class_name: 'CsmOperationDescription', - model_properties: { - name: { - required: false, - serialized_name: 'name', - type: { - name: 'String' - } - }, - display: { - required: false, - serialized_name: 'display', - type: { - name: 'Composite', - class_name: 'CsmOperationDisplay' - } - }, - origin: { - required: false, - serialized_name: 'origin', - type: { - name: 'String' - } - }, - properties: { - required: false, - serialized_name: 'properties', - type: { - name: 'Composite', - class_name: 'CsmOperationDescriptionProperties' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description_properties.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description_properties.rb deleted file mode 100644 index d7634367bd..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_description_properties.rb +++ /dev/null @@ -1,47 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class CsmOperationDescriptionProperties - - include MsRestAzure - - include MsRest::JSONable - # @return [ServiceSpecification] - attr_accessor :service_specification - - - # - # Mapper for CsmOperationDescriptionProperties class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'CsmOperationDescriptionProperties', - type: { - name: 'Composite', - class_name: 'CsmOperationDescriptionProperties', - model_properties: { - service_specification: { - required: false, - serialized_name: 'serviceSpecification', - type: { - name: 'Composite', - class_name: 'ServiceSpecification' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_display.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_display.rb deleted file mode 100644 index 3fe8d2c8ae..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_operation_display.rb +++ /dev/null @@ -1,76 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class CsmOperationDisplay - - include MsRestAzure - - include MsRest::JSONable - # @return [String] - attr_accessor :provider - - # @return [String] - attr_accessor :resource - - # @return [String] - attr_accessor :operation - - # @return [String] - attr_accessor :description - - - # - # Mapper for CsmOperationDisplay class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'CsmOperationDisplay', - type: { - name: 'Composite', - class_name: 'CsmOperationDisplay', - model_properties: { - provider: { - required: false, - serialized_name: 'provider', - type: { - name: 'String' - } - }, - resource: { - required: false, - serialized_name: 'resource', - type: { - name: 'String' - } - }, - operation: { - required: false, - serialized_name: 'operation', - type: { - name: 'String' - } - }, - description: { - required: false, - serialized_name: 'description', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_publishing_profile_options.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_publishing_profile_options.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_site_recovery_entity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_site_recovery_entity.rb new file mode 100755 index 0000000000..ff7633abcb --- /dev/null +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_site_recovery_entity.rb @@ -0,0 +1,68 @@ +# encoding: utf-8 +# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 +# Changes may cause incorrect behavior and will be lost if the code is +# regenerated. + +module Azure::ARM::Web + module Models + # + # Details about app recovery operation. + # + class CsmSiteRecoveryEntity + + include MsRestAzure + + include MsRest::JSONable + # @return [DateTime] Point in time in which the app recovery should be + # attempted. + attr_accessor :snapshot_time + + # @return [String] [Optional] Destination app name into which app should + # be recovered. This is case when new app should be created instead. + attr_accessor :site_name + + # @return [String] [Optional] Destination app slot name into which app + # should be recovered. + attr_accessor :slot_name + + + # + # Mapper for CsmSiteRecoveryEntity class as Ruby Hash. + # This will be used for serialization/deserialization. + # + def self.mapper() + { + required: false, + serialized_name: 'CsmSiteRecoveryEntity', + type: { + name: 'Composite', + class_name: 'CsmSiteRecoveryEntity', + model_properties: { + snapshot_time: { + required: false, + serialized_name: 'snapshotTime', + type: { + name: 'DateTime' + } + }, + site_name: { + required: false, + serialized_name: 'siteName', + type: { + name: 'String' + } + }, + slot_name: { + required: false, + serialized_name: 'slotName', + type: { + name: 'String' + } + } + } + } + } + end + end + end +end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_slot_entity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_slot_entity.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_usage_quota.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_usage_quota.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_usage_quota_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/csm_usage_quota_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_host_name_dns_record_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_host_name_dns_record_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_hostname_analysis_result.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_hostname_analysis_result.rb old mode 100644 new mode 100755 index ac02c80f76..84bec5fb1f --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_hostname_analysis_result.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/custom_hostname_analysis_result.rb @@ -8,7 +8,7 @@ module Models # # Custom domain analysis. # - class CustomHostnameAnalysisResult < MsRestAzure::ProxyOnlyResource + class CustomHostnameAnalysisResult < MsRestAzure::Resource include MsRestAzure @@ -79,7 +79,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -92,14 +91,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, is_hostname_already_verified: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/database_backup_setting.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/database_backup_setting.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/database_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/database_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_site.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_site.rb old mode 100644 new mode 100755 index ca9011a135..b31dd48337 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_site.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_site.rb @@ -168,7 +168,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -190,7 +189,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_web_app_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deleted_web_app_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment.rb old mode 100644 new mode 100755 index aec77f5a65..1584a7b76b --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment.rb @@ -8,24 +8,24 @@ module Models # # User crendentials used for publishing activity. # - class Deployment < MsRestAzure::ProxyOnlyResource + class Deployment < MsRestAzure::Resource include MsRestAzure include MsRest::JSONable - # @return [String] Identifier for deployment. + # @return [String] ID. attr_accessor :deployment_id - # @return [Integer] Deployment status. + # @return [Integer] Status. attr_accessor :status - # @return [String] Details about deployment status. + # @return [String] Message. attr_accessor :message - # @return [String] Who authored the deployment. + # @return [String] Author. attr_accessor :author - # @return [String] Who performed the deployment. + # @return [String] Deployer. attr_accessor :deployer # @return [String] Author email. @@ -37,11 +37,10 @@ class Deployment < MsRestAzure::ProxyOnlyResource # @return [DateTime] End time. attr_accessor :end_time - # @return [Boolean] True if deployment is currently active, false if - # completed and null if not started. + # @return [Boolean] Active. attr_accessor :active - # @return [String] Details on deployment. + # @return [String] Detail. attr_accessor :details @@ -67,7 +66,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -80,14 +78,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, deployment_id: { required: false, serialized_name: 'properties.id', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/deployment_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dimension.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dimension.rb deleted file mode 100644 index 30433b25ee..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dimension.rb +++ /dev/null @@ -1,76 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class Dimension - - include MsRestAzure - - include MsRest::JSONable - # @return [String] - attr_accessor :name - - # @return [String] - attr_accessor :display_name - - # @return [String] - attr_accessor :internal_name - - # @return [Boolean] - attr_accessor :to_be_exported_for_shoebox - - - # - # Mapper for Dimension class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'Dimension', - type: { - name: 'Composite', - class_name: 'Dimension', - model_properties: { - name: { - required: false, - serialized_name: 'name', - type: { - name: 'String' - } - }, - display_name: { - required: false, - serialized_name: 'displayName', - type: { - name: 'String' - } - }, - internal_name: { - required: false, - serialized_name: 'internalName', - type: { - name: 'String' - } - }, - to_be_exported_for_shoebox: { - required: false, - serialized_name: 'toBeExportedForShoebox', - type: { - name: 'Boolean' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dns_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dns_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dns_verification_test_result.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/dns_verification_test_result.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain.rb old mode 100644 new mode 100755 index b57bb0598d..72ad8046e2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain.rb @@ -110,7 +110,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -132,7 +131,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_availablility_check_result.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_availablility_check_result.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_control_center_sso_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_control_center_sso_request.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier.rb old mode 100644 new mode 100755 index e670a44873..3d64f5fdfc --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier.rb @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -61,7 +60,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_ownership_identifier_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_purchase_consent.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_purchase_consent.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_recommendation_search_parameters.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_recommendation_search_parameters.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/domain_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/enabled_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/enabled_config.rb old mode 100644 new mode 100755 index a416a1e8f7..3731d10f0e --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/enabled_config.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/enabled_config.rb @@ -13,8 +13,7 @@ class EnabledConfig include MsRestAzure include MsRest::JSONable - # @return [Boolean] True if configuration is enabled, false if it is - # disabled and null if configuration is not set. + # @return [Boolean] Enabled. attr_accessor :enabled diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/error_entity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/error_entity.rb old mode 100644 new mode 100755 index 48773333f0..a3d4439649 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/error_entity.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/error_entity.rb @@ -13,12 +13,6 @@ class ErrorEntity include MsRestAzure include MsRest::JSONable - # @return [String] Basic error code. - attr_accessor :code - - # @return [String] Any details of the error. - attr_accessor :message - # @return [String] Type of error. attr_accessor :extended_code @@ -31,6 +25,12 @@ class ErrorEntity # @return [Array] Inner errors. attr_accessor :inner_errors + # @return [String] Basic error code. + attr_accessor :code + + # @return [String] Any details of the error. + attr_accessor :message + # # Mapper for ErrorEntity class as Ruby Hash. @@ -44,20 +44,6 @@ def self.mapper() name: 'Composite', class_name: 'ErrorEntity', model_properties: { - code: { - required: false, - serialized_name: 'code', - type: { - name: 'String' - } - }, - message: { - required: false, - serialized_name: 'message', - type: { - name: 'String' - } - }, extended_code: { required: false, serialized_name: 'extendedCode', @@ -100,6 +86,20 @@ def self.mapper() } } } + }, + code: { + required: false, + serialized_name: 'code', + type: { + name: 'String' + } + }, + message: { + required: false, + serialized_name: 'message', + type: { + name: 'String' + } } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/experiments.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/experiments.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_application_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_application_logs_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_http_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_http_logs_config.rb old mode 100644 new mode 100755 index 84963bfef0..77e1829848 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_http_logs_config.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/file_system_http_logs_config.rb @@ -24,8 +24,7 @@ class FileSystemHttpLogsConfig # 0 or lower means no retention. attr_accessor :retention_in_days - # @return [Boolean] True if configuration is enabled, false if it is - # disabled and null if configuration is not set. + # @return [Boolean] Enabled. attr_accessor :enabled diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/frequency_unit.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/frequency_unit.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region.rb old mode 100644 new mode 100755 index b64e57f93b..b4978f9349 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region.rb @@ -8,7 +8,7 @@ module Models # # Geographical region. # - class GeoRegion < MsRestAzure::ProxyOnlyResource + class GeoRegion < MsRestAzure::Resource include MsRestAzure @@ -45,7 +45,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -58,14 +57,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, geo_region_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/geo_region_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/global_csm_sku_description.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/global_csm_sku_description.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/handler_mapping.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/handler_mapping.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding.rb old mode 100644 new mode 100755 index 7b120725d0..ab974e914f --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding.rb @@ -8,7 +8,7 @@ module Models # # A hostname binding object. # - class HostNameBinding < MsRestAzure::ProxyOnlyResource + class HostNameBinding < MsRestAzure::Resource include MsRestAzure @@ -71,7 +71,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -84,14 +83,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, host_name_binding_name: { required: false, serialized_name: 'properties.name', @@ -161,7 +180,6 @@ def self.mapper() }, virtual_ip: { required: false, - read_only: true, serialized_name: 'properties.virtualIP', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_binding_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_ssl_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_ssl_state.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_name_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/host_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_diagnostics.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_diagnostics.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_profile.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_profile.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hosting_environment_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/http_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/http_logs_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection.rb old mode 100644 new mode 100755 index 1493ec2557..b880ab6712 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection.rb @@ -9,7 +9,7 @@ module Models # Hybrid Connection contract. This is used to configure a Hybrid # Connection. # - class HybridConnection < MsRestAzure::ProxyOnlyResource + class HybridConnection < MsRestAzure::Resource include MsRestAzure @@ -38,10 +38,6 @@ class HybridConnection < MsRestAzure::ProxyOnlyResource # normally, use the POST /listKeys API instead. attr_accessor :send_key_value - # @return [String] The suffix for the service bus endpoint. By default - # this is .servicebus.windows.net - attr_accessor :service_bus_suffix - # # Mapper for HybridConnection class as Ruby Hash. @@ -65,7 +61,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -78,14 +73,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, service_bus_namespace: { required: false, serialized_name: 'properties.serviceBusNamespace', @@ -134,13 +149,6 @@ def self.mapper() type: { name: 'String' } - }, - service_bus_suffix: { - required: false, - serialized_name: 'properties.serviceBusSuffix', - type: { - name: 'String' - } } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_key.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_key.rb old mode 100644 new mode 100755 index 5eac114f08..bbc3a3fa09 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_key.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_key.rb @@ -9,7 +9,7 @@ module Models # Hybrid Connection key contract. This has the send key name and value for # a Hybrid Connection. # - class HybridConnectionKey < MsRestAzure::ProxyOnlyResource + class HybridConnectionKey < MsRestAzure::Resource include MsRestAzure @@ -43,7 +43,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -56,14 +55,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, send_key_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_limits.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_limits.rb old mode 100644 new mode 100755 index 9419139fda..a9ac0f5e7b --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_limits.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/hybrid_connection_limits.rb @@ -9,7 +9,7 @@ module Models # Hybrid Connection limits contract. This is used to return the plan limits # of Hybrid Connections. # - class HybridConnectionLimits < MsRestAzure::ProxyOnlyResource + class HybridConnectionLimits < MsRestAzure::Resource include MsRestAzure @@ -43,7 +43,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -56,14 +55,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, current: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier.rb old mode 100644 new mode 100755 index 81dbc377a7..d6a03f45be --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier.rb @@ -8,12 +8,12 @@ module Models # # Identifier. # - class Identifier < MsRestAzure::ProxyOnlyResource + class Identifier < MsRestAzure::Resource include MsRestAzure include MsRest::JSONable - # @return [String] String representation of the identity. + # @return [String] ID. attr_accessor :identifier_id @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -52,14 +51,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, identifier_id: { required: false, serialized_name: 'properties.id', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/identifier_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/in_availability_reason_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/in_availability_reason_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/internal_load_balancing_mode.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/internal_load_balancing_mode.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ip_security_restriction.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ip_security_restriction.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/key_vault_secret_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/key_vault_secret_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/localizable_string.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/localizable_string.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/log_level.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/log_level.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/managed_pipeline_mode.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/managed_pipeline_mode.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_availabilily.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_availabilily.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_availability.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_availability.rb deleted file mode 100644 index 1eb9df156d..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_availability.rb +++ /dev/null @@ -1,56 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class MetricAvailability - - include MsRestAzure - - include MsRest::JSONable - # @return [String] - attr_accessor :time_grain - - # @return [String] - attr_accessor :blob_duration - - - # - # Mapper for MetricAvailability class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MetricAvailability', - type: { - name: 'Composite', - class_name: 'MetricAvailability', - model_properties: { - time_grain: { - required: false, - serialized_name: 'timeGrain', - type: { - name: 'String' - } - }, - blob_duration: { - required: false, - serialized_name: 'blobDuration', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_definition.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_definition.rb old mode 100644 new mode 100755 index c5f4e83643..74d0578610 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_definition.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_definition.rb @@ -8,7 +8,7 @@ module Models # # Metadata for a metric. # - class MetricDefinition < MsRestAzure::ProxyOnlyResource + class MetricDefinition < MsRestAzure::Resource include MsRestAzure @@ -52,7 +52,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -65,14 +64,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, metric_definition_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_specification.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_specification.rb deleted file mode 100644 index c28691fdc5..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/metric_specification.rb +++ /dev/null @@ -1,202 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class MetricSpecification - - include MsRestAzure - - include MsRest::JSONable - # @return [String] - attr_accessor :name - - # @return [String] - attr_accessor :display_name - - # @return [String] - attr_accessor :display_description - - # @return [String] - attr_accessor :unit - - # @return [String] - attr_accessor :aggregation_type - - # @return [Boolean] - attr_accessor :supports_instance_level_aggregation - - # @return [Boolean] - attr_accessor :enable_regional_mdm_account - - # @return [String] - attr_accessor :source_mdm_account - - # @return [String] - attr_accessor :source_mdm_namespace - - # @return [String] - attr_accessor :metric_filter_pattern - - # @return [Boolean] - attr_accessor :fill_gap_with_zero - - # @return [Boolean] - attr_accessor :is_internal - - # @return [Array] - attr_accessor :dimensions - - # @return [String] - attr_accessor :category - - # @return [Array] - attr_accessor :availabilities - - - # - # Mapper for MetricSpecification class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MetricSpecification', - type: { - name: 'Composite', - class_name: 'MetricSpecification', - model_properties: { - name: { - required: false, - serialized_name: 'name', - type: { - name: 'String' - } - }, - display_name: { - required: false, - serialized_name: 'displayName', - type: { - name: 'String' - } - }, - display_description: { - required: false, - serialized_name: 'displayDescription', - type: { - name: 'String' - } - }, - unit: { - required: false, - serialized_name: 'unit', - type: { - name: 'String' - } - }, - aggregation_type: { - required: false, - serialized_name: 'aggregationType', - type: { - name: 'String' - } - }, - supports_instance_level_aggregation: { - required: false, - serialized_name: 'supportsInstanceLevelAggregation', - type: { - name: 'Boolean' - } - }, - enable_regional_mdm_account: { - required: false, - serialized_name: 'enableRegionalMdmAccount', - type: { - name: 'Boolean' - } - }, - source_mdm_account: { - required: false, - serialized_name: 'sourceMdmAccount', - type: { - name: 'String' - } - }, - source_mdm_namespace: { - required: false, - serialized_name: 'sourceMdmNamespace', - type: { - name: 'String' - } - }, - metric_filter_pattern: { - required: false, - serialized_name: 'metricFilterPattern', - type: { - name: 'String' - } - }, - fill_gap_with_zero: { - required: false, - serialized_name: 'fillGapWithZero', - type: { - name: 'Boolean' - } - }, - is_internal: { - required: false, - serialized_name: 'isInternal', - type: { - name: 'Boolean' - } - }, - dimensions: { - required: false, - serialized_name: 'dimensions', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'DimensionElementType', - type: { - name: 'Composite', - class_name: 'Dimension' - } - } - } - }, - category: { - required: false, - serialized_name: 'category', - type: { - name: 'String' - } - }, - availabilities: { - required: false, - serialized_name: 'availabilities', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'MetricAvailabilityElementType', - type: { - name: 'Composite', - class_name: 'MetricAvailability' - } - } - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_request.rb old mode 100644 new mode 100755 index 134a53f65a..ee46a4db9d --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_request.rb @@ -8,18 +8,15 @@ module Models # # MySQL migration request. # - class MigrateMySqlRequest < MsRestAzure::ProxyOnlyResource + class MigrateMySqlRequest < MsRestAzure::Resource include MsRestAzure include MsRest::JSONable - # @return [String] Connection string to the remote MySQL database. + # @return [String] Connection string to the remote MySQL database to + # which data should be migrated. attr_accessor :connection_string - # @return [MySqlMigrationType] The type of migration operation to be - # done. Possible values include: 'LocalToRemote', 'RemoteToLocal' - attr_accessor :migration_type - # # Mapper for MigrateMySqlRequest class as Ruby Hash. @@ -43,7 +40,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -56,27 +52,39 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, - connection_string: { + tags: { required: false, - serialized_name: 'properties.connectionString', + serialized_name: 'tags', type: { - name: 'String' + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } } }, - migration_type: { + connection_string: { required: false, - serialized_name: 'properties.migrationType', + serialized_name: 'properties.connectionString', type: { - name: 'Enum', - module: 'MySqlMigrationType' + name: 'String' } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_status.rb old mode 100644 new mode 100755 index dc52e936a3..382ed0c2d3 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_status.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/migrate_my_sql_status.rb @@ -8,7 +8,7 @@ module Models # # MySQL migration status. # - class MigrateMySqlStatus < MsRestAzure::ProxyOnlyResource + class MigrateMySqlStatus < MsRestAzure::Resource include MsRestAzure @@ -46,7 +46,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -59,14 +58,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, migration_operation_status: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy.rb deleted file mode 100644 index 4317af8d16..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy.rb +++ /dev/null @@ -1,148 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # MSDeploy ARM PUT information - # - class MSDeploy < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] Package URI - attr_accessor :package_uri - - # @return [String] SQL Connection String - attr_accessor :connection_string - - # @return [String] Database Type - attr_accessor :db_type - - # @return [String] URI of MSDeploy Parameters file. Must not be set if - # SetParameters is used. - attr_accessor :set_parameters_xml_file_uri - - # @return [Hash{String => String}] MSDeploy Parameters. Must not be set - # if SetParametersXmlFileUri is used. - attr_accessor :set_parameters - - # @return [Boolean] Controls whether the MSDeploy operation skips the - # AppData directory. If set to true, the existing AppData directory on - # the destination will not be deleted and overwritten. - attr_accessor :skip_app_data - - # @return [Boolean] Sets the AppOffline rule while the MSDeploy operation - # executes. - attr_accessor :app_offline - - - # - # Mapper for MSDeploy class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MSDeploy', - type: { - name: 'Composite', - class_name: 'MSDeploy', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - package_uri: { - required: false, - serialized_name: 'properties.packageUri', - type: { - name: 'String' - } - }, - connection_string: { - required: false, - serialized_name: 'properties.connectionString', - type: { - name: 'String' - } - }, - db_type: { - required: false, - serialized_name: 'properties.dbType', - type: { - name: 'String' - } - }, - set_parameters_xml_file_uri: { - required: false, - serialized_name: 'properties.setParametersXmlFileUri', - type: { - name: 'String' - } - }, - set_parameters: { - required: false, - serialized_name: 'properties.setParameters', - type: { - name: 'Dictionary', - value: { - required: false, - serialized_name: 'StringElementType', - type: { - name: 'String' - } - } - } - }, - skip_app_data: { - required: false, - serialized_name: 'properties.skipAppData', - type: { - name: 'Boolean' - } - }, - app_offline: { - required: false, - serialized_name: 'properties.appOffline', - type: { - name: 'Boolean' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log.rb deleted file mode 100644 index 6d2fe4ac99..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log.rb +++ /dev/null @@ -1,85 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # MSDeploy log - # - class MSDeployLog < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [Array] List of log entry messages - attr_accessor :entries - - - # - # Mapper for MSDeployLog class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MSDeployLog', - type: { - name: 'Composite', - class_name: 'MSDeployLog', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - entries: { - required: false, - read_only: true, - serialized_name: 'properties.entries', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'MSDeployLogEntryElementType', - type: { - name: 'Composite', - class_name: 'MSDeployLogEntry' - } - } - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry.rb deleted file mode 100644 index 7e256ebb68..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry.rb +++ /dev/null @@ -1,70 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # MSDeploy log entry - # - class MSDeployLogEntry - - include MsRestAzure - - include MsRest::JSONable - # @return [DateTime] Timestamp of log entry - attr_accessor :time - - # @return [MSDeployLogEntryType] Log entry type. Possible values include: - # 'Message', 'Warning', 'Error' - attr_accessor :type - - # @return [String] Log entry message - attr_accessor :message - - - # - # Mapper for MSDeployLogEntry class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MSDeployLogEntry', - type: { - name: 'Composite', - class_name: 'MSDeployLogEntry', - model_properties: { - time: { - required: false, - read_only: true, - serialized_name: 'time', - type: { - name: 'DateTime' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'Enum', - module: 'MSDeployLogEntryType' - } - }, - message: { - required: false, - read_only: true, - serialized_name: 'message', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry_type.rb deleted file mode 100644 index a672823e9c..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_log_entry_type.rb +++ /dev/null @@ -1,17 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Defines values for MSDeployLogEntryType - # - module MSDeployLogEntryType - Message = "Message" - Warning = "Warning" - Error = "Error" - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_provisioning_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_provisioning_state.rb deleted file mode 100644 index 8f376150a0..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_provisioning_state.rb +++ /dev/null @@ -1,19 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Defines values for MSDeployProvisioningState - # - module MSDeployProvisioningState - Accepted = "accepted" - Running = "running" - Succeeded = "succeeded" - Failed = "failed" - Canceled = "canceled" - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_status.rb deleted file mode 100644 index a394f832d8..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/msdeploy_status.rb +++ /dev/null @@ -1,123 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # MSDeploy ARM response - # - class MSDeployStatus < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] Username of deployer - attr_accessor :deployer - - # @return [MSDeployProvisioningState] Provisioning state. Possible values - # include: 'accepted', 'running', 'succeeded', 'failed', 'canceled' - attr_accessor :provisioning_state - - # @return [DateTime] Start time of deploy operation - attr_accessor :start_time - - # @return [DateTime] End time of deploy operation - attr_accessor :end_time - - # @return [Boolean] Whether the deployment operation has completed - attr_accessor :complete - - - # - # Mapper for MSDeployStatus class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'MSDeployStatus', - type: { - name: 'Composite', - class_name: 'MSDeployStatus', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - deployer: { - required: false, - read_only: true, - serialized_name: 'properties.deployer', - type: { - name: 'String' - } - }, - provisioning_state: { - required: false, - read_only: true, - serialized_name: 'properties.provisioningState', - type: { - name: 'Enum', - module: 'MSDeployProvisioningState' - } - }, - start_time: { - required: false, - read_only: true, - serialized_name: 'properties.startTime', - type: { - name: 'DateTime' - } - }, - end_time: { - required: false, - read_only: true, - serialized_name: 'properties.endTime', - type: { - name: 'DateTime' - } - }, - complete: { - required: false, - read_only: true, - serialized_name: 'properties.complete', - type: { - name: 'Boolean' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/my_sql_migration_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/my_sql_migration_type.rb deleted file mode 100644 index e37e69ada1..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/my_sql_migration_type.rb +++ /dev/null @@ -1,16 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Defines values for MySqlMigrationType - # - module MySqlMigrationType - LocalToRemote = "LocalToRemote" - RemoteToLocal = "RemoteToLocal" - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_identifier.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_identifier.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_identifier_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_identifier_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_value_pair.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/name_value_pair.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_access_control_entry.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_access_control_entry.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_features.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_features.rb old mode 100644 new mode 100755 index 9742110f63..6070172681 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_features.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/network_features.rb @@ -9,7 +9,7 @@ module Models # Full view of network features for an app (presently VNET integration and # Hybrid Connections). # - class NetworkFeatures < MsRestAzure::ProxyOnlyResource + class NetworkFeatures < MsRestAzure::Resource include MsRestAzure @@ -51,7 +51,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -64,14 +63,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, virtual_network_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/notification_level.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/notification_level.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/operation.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/operation.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/operation_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/operation_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_counter_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_counter_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_response.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_sample.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_sample.rb old mode 100644 new mode 100755 index 59bcd5fb95..44c040c7b8 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_sample.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_sample.rb @@ -22,9 +22,6 @@ class PerfMonSample # @return [Float] Value of counter at a certain time. attr_accessor :value - # @return [Integer] Core Count of worker. Not a data member - attr_accessor :core_count - # # Mapper for PerfMonSample class as Ruby Hash. @@ -58,13 +55,6 @@ def self.mapper() type: { name: 'Double' } - }, - core_count: { - required: false, - serialized_name: 'coreCount', - type: { - name: 'Number' - } } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_set.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/perf_mon_set.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on.rb old mode 100644 new mode 100755 index 72d1bcc5ae..f332db7d6b --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on.rb @@ -60,7 +60,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -82,7 +81,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer.rb old mode 100644 new mode 100755 index 0e1c00432f..c459468d1d --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer.rb @@ -8,7 +8,7 @@ module Models # # Premier add-on offer. # - class PremierAddOnOffer < MsRestAzure::ProxyOnlyResource + class PremierAddOnOffer < MsRestAzure::Resource include MsRestAzure @@ -72,7 +72,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -85,14 +84,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, sku: { required: false, serialized_name: 'properties.sku', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/premier_add_on_offer_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/provisioning_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/provisioning_state.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/proxy_only_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/proxy_only_resource.rb deleted file mode 100644 index 080812dffe..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/proxy_only_resource.rb +++ /dev/null @@ -1,79 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Azure proxy only resource. This resource is not tracked by Azure Resource - # Manager. - # - class ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] Resource Id. - attr_accessor :id - - # @return [String] Resource Name. - attr_accessor :name - - # @return [String] Kind of resource. - attr_accessor :kind - - # @return [String] Resource type. - attr_accessor :type - - - # - # Mapper for ProxyOnlyResource class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'ProxyOnlyResource', - type: { - name: 'Composite', - class_name: 'ProxyOnlyResource', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate.rb deleted file mode 100644 index a5fb51953f..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate.rb +++ /dev/null @@ -1,99 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Public certificate object - # - class PublicCertificate < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] Public Certificate byte array - attr_accessor :blob - - # @return [PublicCertificateLocation] Public Certificate Location. - # Possible values include: 'CurrentUserMy', 'LocalMachineMy', 'Unknown' - attr_accessor :public_certificate_location - - # @return [String] Certificate Thumbprint - attr_accessor :thumbprint - - - # - # Mapper for PublicCertificate class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'PublicCertificate', - type: { - name: 'Composite', - class_name: 'PublicCertificate', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - blob: { - required: false, - serialized_name: 'properties.blob', - type: { - name: 'String' - } - }, - public_certificate_location: { - required: false, - serialized_name: 'properties.publicCertificateLocation', - type: { - name: 'Enum', - module: 'PublicCertificateLocation' - } - }, - thumbprint: { - required: false, - read_only: true, - serialized_name: 'properties.thumbprint', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_collection.rb deleted file mode 100644 index 86329937fe..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_collection.rb +++ /dev/null @@ -1,94 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Collection of public certificates - # - class PublicCertificateCollection - - include MsRestAzure - - include MsRest::JSONable - # @return [Array] Collection of resources. - attr_accessor :value - - # @return [String] Link to next page of resources. - attr_accessor :next_link - - # return [Proc] with next page method call. - attr_accessor :next_method - - # - # Gets the rest of the items for the request, enabling auto-pagination. - # - # @return [Array] operation results. - # - def get_all_items - items = @value - page = self - while page.next_link != nil do - page = page.get_next_page - items.concat(page.value) - end - items - end - - # - # Gets the next page of results. - # - # @return [PublicCertificateCollection] with next page content. - # - def get_next_page - response = @next_method.call(@next_link).value! unless @next_method.nil? - unless response.nil? - @next_link = response.body.next_link - @value = response.body.value - self - end - end - - # - # Mapper for PublicCertificateCollection class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'PublicCertificateCollection', - type: { - name: 'Composite', - class_name: 'PublicCertificateCollection', - model_properties: { - value: { - required: true, - serialized_name: 'value', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'PublicCertificateElementType', - type: { - name: 'Composite', - class_name: 'PublicCertificate' - } - } - } - }, - next_link: { - required: false, - serialized_name: 'nextLink', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_location.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_location.rb deleted file mode 100644 index 3e634479e7..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/public_certificate_location.rb +++ /dev/null @@ -1,17 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Defines values for PublicCertificateLocation - # - module PublicCertificateLocation - CurrentUserMy = "CurrentUserMy" - LocalMachineMy = "LocalMachineMy" - Unknown = "Unknown" - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/publishing_profile_format.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/publishing_profile_format.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/push_settings.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/push_settings.rb old mode 100644 new mode 100755 index a30f981fb0..dd82f0e402 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/push_settings.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/push_settings.rb @@ -8,7 +8,7 @@ module Models # # Push settings for the App. # - class PushSettings < MsRestAzure::ProxyOnlyResource + class PushSettings include MsRestAzure @@ -34,27 +34,6 @@ class PushSettings < MsRestAzure::ProxyOnlyResource # registration endpoint. attr_accessor :dynamic_tags_json - # @return [Boolean] Gets or sets a flag indicating whether the Push - # endpoint is enabled. - attr_accessor :is_push_enabled1 - - # @return [String] Gets or sets a JSON string containing a list of tags - # that are whitelisted for use by the push registration endpoint. - attr_accessor :tag_whitelist_json1 - - # @return [String] Gets or sets a JSON string containing a list of tags - # that require user authentication to be used in the push registration - # endpoint. - # Tags can consist of alphanumeric characters and the following: - # '_', '@', '#', '.', ':', '-'. - # Validation should be performed at the PushRequestHandler. - attr_accessor :tags_requiring_auth1 - - # @return [String] Gets or sets a JSON string containing a list of - # dynamic tags that will be evaluated from user claims in the push - # registration endpoint. - attr_accessor :dynamic_tags_json1 - # # Mapper for PushSettings class as Ruby Hash. @@ -68,37 +47,6 @@ def self.mapper() name: 'Composite', class_name: 'PushSettings', model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, is_push_enabled: { required: true, serialized_name: 'isPushEnabled', @@ -126,34 +74,6 @@ def self.mapper() type: { name: 'String' } - }, - is_push_enabled1: { - required: false, - serialized_name: 'properties.isPushEnabled', - type: { - name: 'Boolean' - } - }, - tag_whitelist_json1: { - required: false, - serialized_name: 'properties.tagWhitelistJson', - type: { - name: 'String' - } - }, - tags_requiring_auth1: { - required: false, - serialized_name: 'properties.tagsRequiringAuth', - type: { - name: 'String' - } - }, - dynamic_tags_json1: { - required: false, - serialized_name: 'properties.dynamicTagsJson', - type: { - name: 'String' - } } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ramp_up_rule.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ramp_up_rule.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recommendation.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recommendation.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recommendation_rule.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recommendation_rule.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recover_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recover_response.rb old mode 100644 new mode 100755 index 43184028f2..e378baebd2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recover_response.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/recover_response.rb @@ -40,7 +40,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -62,7 +61,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/reissue_certificate_order_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/reissue_certificate_order_request.rb old mode 100644 new mode 100755 index 20888594d0..8c3b7f1bd7 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/reissue_certificate_order_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/reissue_certificate_order_request.rb @@ -50,7 +50,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -72,7 +71,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/relay_service_connection_entity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/relay_service_connection_entity.rb old mode 100644 new mode 100755 index 3aa8c41f1b..38c48a5a1e --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/relay_service_connection_entity.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/relay_service_connection_entity.rb @@ -8,7 +8,7 @@ module Models # # Hybrid Connection for an App Service app. # - class RelayServiceConnectionEntity < MsRestAzure::ProxyOnlyResource + class RelayServiceConnectionEntity < MsRestAzure::Resource include MsRestAzure @@ -57,7 +57,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -70,14 +69,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, entity_name: { required: false, serialized_name: 'properties.entityName', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/renew_certificate_order_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/renew_certificate_order_request.rb old mode 100644 new mode 100755 index e9e5e41c14..6b4d343bd2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/renew_certificate_order_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/renew_certificate_order_request.rb @@ -46,7 +46,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -68,7 +67,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/requests_based_trigger.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/requests_based_trigger.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource.rb old mode 100644 new mode 100755 index 0d43d12048..5f4dfa292f --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource.rb @@ -6,7 +6,7 @@ module Azure::ARM::Web module Models # - # Azure resource. This resource is tracked in Azure Resource Manager + # Azure resource. # class Resource < MsRestAzure::Resource @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -61,7 +60,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_health_metadata.rb old mode 100644 new mode 100755 similarity index 54% rename from management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_request.rb rename to management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_health_metadata.rb index 7eb04ca581..44d52bdefe --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_health_metadata.rb @@ -6,41 +6,35 @@ module Azure::ARM::Web module Models # - # Details about app recovery operation. + # Used for getting ResourceHealthCheck settings. # - class SnapshotRecoveryRequest < MsRestAzure::ProxyOnlyResource + class ResourceHealthMetadata < MsRestAzure::Resource include MsRestAzure include MsRest::JSONable - # @return [DateTime] Point in time in which the app recovery should be - # attempted. - attr_accessor :snapshot_time + # @return [String] ARM Resource Id + attr_accessor :resource_health_metadata_id - # @return [SnapshotRecoveryTarget] Specifies the web app that snapshot - # contents will be written to. - attr_accessor :recovery_target + # @return [String] The category that the resource matches in the RHC + # Policy File + attr_accessor :category - # @return [Boolean] true if the recovery operation can - # overwrite source app; otherwise, false. - attr_accessor :overwrite - - # @return [Boolean] Site configuration, in addition to content, will be - # reverted if this is true. - attr_accessor :recover_configuration + # @return [Boolean] Is there a health signal for the resource + attr_accessor :signal_availability # - # Mapper for SnapshotRecoveryRequest class as Ruby Hash. + # Mapper for ResourceHealthMetadata class as Ruby Hash. # This will be used for serialization/deserialization. # def self.mapper() { required: false, - serialized_name: 'SnapshotRecoveryRequest', + serialized_name: 'ResourceHealthMetadata', type: { name: 'Composite', - class_name: 'SnapshotRecoveryRequest', + class_name: 'ResourceHealthMetadata', model_properties: { id: { required: false, @@ -52,7 +46,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -65,39 +58,51 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, - snapshot_time: { + tags: { required: false, - serialized_name: 'properties.snapshotTime', + serialized_name: 'tags', type: { - name: 'DateTime' + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } } }, - recovery_target: { + resource_health_metadata_id: { required: false, - serialized_name: 'properties.recoveryTarget', + serialized_name: 'properties.id', type: { - name: 'Composite', - class_name: 'SnapshotRecoveryTarget' + name: 'String' } }, - overwrite: { + category: { required: false, - serialized_name: 'properties.overwrite', + serialized_name: 'properties.category', type: { - name: 'Boolean' + name: 'String' } }, - recover_configuration: { + signal_availability: { required: false, - serialized_name: 'properties.recoverConfiguration', + serialized_name: 'properties.signalAvailability', type: { name: 'Boolean' } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_availability.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_availability.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition.rb old mode 100644 new mode 100755 index a7b0a4101e..dac5ed9a81 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition.rb @@ -8,7 +8,7 @@ module Models # # Metadata for the metrics. # - class ResourceMetricDefinition < MsRestAzure::ProxyOnlyResource + class ResourceMetricDefinition < MsRestAzure::Resource include MsRestAzure @@ -58,7 +58,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -71,14 +70,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, resource_metric_definition_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_definition_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_name.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_name.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_property.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_property.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_value.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_metric_value.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_name_availability.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_name_availability.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_name_availability_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_name_availability_request.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_scope_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/resource_scope_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_request.rb old mode 100644 new mode 100755 index 4f302cedc3..9294cb7392 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_request.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_request.rb @@ -8,7 +8,7 @@ module Models # # Description of a restore request. # - class RestoreRequest < MsRestAzure::ProxyOnlyResource + class RestoreRequest < MsRestAzure::Resource include MsRestAzure @@ -39,13 +39,8 @@ class RestoreRequest < MsRestAzure::ProxyOnlyResource # conflicts during the operation. Default value: false . attr_accessor :ignore_conflicting_host_names - # @return [Boolean] Ignore the databases and only restore the site - # content. Default value: false . - attr_accessor :ignore_databases - # @return [BackupRestoreOperationType] Operation type. Possible values - # include: 'Default', 'Clone', 'Relocation', 'Snapshot'. Default value: - # 'Default' . + # include: 'Default', 'Clone', 'Relocation'. Default value: 'Default' . attr_accessor :operation_type # @return [Boolean] true if SiteConfig.ConnectionStrings @@ -79,7 +74,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -92,14 +86,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, storage_account_url: { required: false, serialized_name: 'properties.storageAccountUrl', @@ -151,14 +165,6 @@ def self.mapper() name: 'Boolean' } }, - ignore_databases: { - required: false, - serialized_name: 'properties.ignoreDatabases', - default_value: false, - type: { - name: 'Boolean' - } - }, operation_type: { required: false, serialized_name: 'properties.operationType', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_response.rb old mode 100644 new mode 100755 index 7a72a68023..50e603f94f --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_response.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/restore_response.rb @@ -8,7 +8,7 @@ module Models # # Response for an app restore request. # - class RestoreResponse < MsRestAzure::ProxyOnlyResource + class RestoreResponse < MsRestAzure::Resource include MsRestAzure @@ -40,7 +40,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -53,14 +52,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, operation_id: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/route_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/route_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/scm_type.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/scm_type.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/service_specification.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/service_specification.rb deleted file mode 100644 index 6604b76098..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/service_specification.rb +++ /dev/null @@ -1,54 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Model object. - # - # - class ServiceSpecification - - include MsRestAzure - - include MsRest::JSONable - # @return [Array] - attr_accessor :metric_specifications - - - # - # Mapper for ServiceSpecification class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'ServiceSpecification', - type: { - name: 'Composite', - class_name: 'ServiceSpecification', - model_properties: { - metric_specifications: { - required: false, - serialized_name: 'metricSpecifications', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'MetricSpecificationElementType', - type: { - name: 'Composite', - class_name: 'MetricSpecification' - } - } - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site.rb old mode 100644 new mode 100755 index 4c9fe5f1a0..a3ffe2d9cb --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site.rb @@ -64,6 +64,9 @@ class Site < MsRestAzure::Resource # the app. Read-only. attr_accessor :traffic_manager_host_names + # @return [Boolean] Indicates whether app is deployed as a premium app. + attr_accessor :premium_app_deployed + # @return [Boolean] true to stop SCM (KUDU) site when the # app is stopped; otherwise, false. The default is # false. Default value: false . @@ -77,6 +80,13 @@ class Site < MsRestAzure::Resource # the app. attr_accessor :hosting_environment_profile + # @return [String] Micro services like apps, logic apps. Default value: + # 'WebSites' . + attr_accessor :micro_service + + # @return [String] Name of gateway app associated with the app. + attr_accessor :gateway_site_name + # @return [Boolean] true to enable client affinity; # false to stop sending session affinity cookies, which # route client requests in the same session to the same instance. Default @@ -132,16 +142,6 @@ class Site < MsRestAzure::Resource # operation. attr_accessor :slot_swap_status - # @return [Boolean] Indicates whether app is deployed as a premium app. - attr_accessor :premium_app_deployed - - # @return [String] Micro services like apps, logic apps. Default value: - # 'WebSites' . - attr_accessor :micro_service - - # @return [String] Name of gateway app associated with the app. - attr_accessor :gateway_site_name - # # Mapper for Site class as Ruby Hash. @@ -165,7 +165,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -187,7 +186,6 @@ def self.mapper() }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' @@ -339,6 +337,14 @@ def self.mapper() } } }, + premium_app_deployed: { + required: false, + read_only: true, + serialized_name: 'properties.premiumAppDeployed', + type: { + name: 'Boolean' + } + }, scm_site_also_stopped: { required: false, serialized_name: 'properties.scmSiteAlsoStopped', @@ -363,6 +369,21 @@ def self.mapper() class_name: 'HostingEnvironmentProfile' } }, + micro_service: { + required: false, + serialized_name: 'properties.microService', + default_value: 'WebSites', + type: { + name: 'String' + } + }, + gateway_site_name: { + required: false, + serialized_name: 'properties.gatewaySiteName', + type: { + name: 'String' + } + }, client_affinity_enabled: { required: false, serialized_name: 'properties.clientAffinityEnabled', @@ -462,29 +483,6 @@ def self.mapper() name: 'Composite', class_name: 'SlotSwapStatus' } - }, - premium_app_deployed: { - required: false, - read_only: true, - serialized_name: 'properties.premiumAppDeployed', - type: { - name: 'Boolean' - } - }, - micro_service: { - required: false, - serialized_name: 'properties.microService', - default_value: 'WebSites', - type: { - name: 'String' - } - }, - gateway_site_name: { - required: false, - serialized_name: 'properties.gatewaySiteName', - type: { - name: 'String' - } } } } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_auth_settings.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_auth_settings.rb old mode 100644 new mode 100755 index 468a0141fa..0c4ac3326e --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_auth_settings.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_auth_settings.rb @@ -9,7 +9,7 @@ module Models # Configuration settings for the Azure App Service Authentication / # Authorization feature. # - class SiteAuthSettings < MsRestAzure::ProxyOnlyResource + class SiteAuthSettings < MsRestAzure::Resource include MsRestAzure @@ -197,7 +197,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -210,14 +209,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, enabled: { required: false, serialized_name: 'properties.enabled', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_availability_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_availability_state.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_cloneability.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_cloneability.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_cloneability_criterion.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_cloneability_criterion.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource.rb old mode 100644 new mode 100755 index c150f89c80..2af2b7d454 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource.rb @@ -8,7 +8,7 @@ module Models # # Web app configuration ARM resource. # - class SiteConfigResource < MsRestAzure::ProxyOnlyResource + class SiteConfigResource < MsRestAzure::Resource include MsRestAzure @@ -181,7 +181,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -194,14 +193,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, number_of_workers: { required: false, serialized_name: 'properties.numberOfWorkers', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_config_resource_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_configuration_snapshot_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_configuration_snapshot_info.rb old mode 100644 new mode 100755 index 8b0d0ea5c2..7bca650451 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_configuration_snapshot_info.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_configuration_snapshot_info.rb @@ -8,7 +8,7 @@ module Models # # A snapshot of a web app configuration. # - class SiteConfigurationSnapshotInfo < MsRestAzure::ProxyOnlyResource + class SiteConfigurationSnapshotInfo < MsRestAzure::Resource include MsRestAzure @@ -42,7 +42,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -55,14 +54,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, time: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_instance.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_instance.rb old mode 100644 new mode 100755 index a1c333c4bd..9454aa12a1 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_instance.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_instance.rb @@ -8,7 +8,7 @@ module Models # # Instance of an app. # - class SiteInstance < MsRestAzure::ProxyOnlyResource + class SiteInstance < MsRestAzure::Resource include MsRestAzure @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -52,14 +51,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, site_instance_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_limits.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_limits.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_load_balancing.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_load_balancing.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_logs_config.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_logs_config.rb old mode 100644 new mode 100755 index 4d4df1fabf..4dfd47e574 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_logs_config.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_logs_config.rb @@ -8,7 +8,7 @@ module Models # # Configuration of App Service site logs. # - class SiteLogsConfig < MsRestAzure::ProxyOnlyResource + class SiteLogsConfig < MsRestAzure::Resource include MsRestAzure @@ -48,7 +48,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -61,14 +60,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, application_logs: { required: false, serialized_name: 'properties.applicationLogs', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_machine_key.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_machine_key.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_php_error_log_flag.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_php_error_log_flag.rb old mode 100644 new mode 100755 index 25618b12c9..34ce470603 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_php_error_log_flag.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_php_error_log_flag.rb @@ -8,7 +8,7 @@ module Models # # Used for getting PHP error logging flag. # - class SitePhpErrorLogFlag < MsRestAzure::ProxyOnlyResource + class SitePhpErrorLogFlag < MsRestAzure::Resource include MsRestAzure @@ -48,7 +48,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -61,14 +60,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, local_log_errors: { required: false, serialized_name: 'properties.localLogErrors', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_seal.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_seal.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_seal_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_seal_request.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_source_control.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_source_control.rb old mode 100644 new mode 100755 index bc44b598a3..c8026985e2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_source_control.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/site_source_control.rb @@ -8,7 +8,7 @@ module Models # # Source control configuration for an app. # - class SiteSourceControl < MsRestAzure::ProxyOnlyResource + class SiteSourceControl < MsRestAzure::Resource include MsRestAzure @@ -55,7 +55,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -68,14 +67,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, repo_url: { required: false, serialized_name: 'properties.repoUrl', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_capacity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_capacity.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_description.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_description.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_info.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_info_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_info_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_infos.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_infos.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_name.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/sku_name.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_config_names_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_config_names_resource.rb old mode 100644 new mode 100755 index ca1bdefcf1..2cfbe3c1c2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_config_names_resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_config_names_resource.rb @@ -8,7 +8,7 @@ module Models # # Slot Config names azure resource. # - class SlotConfigNamesResource < MsRestAzure::ProxyOnlyResource + class SlotConfigNamesResource < MsRestAzure::Resource include MsRestAzure @@ -42,7 +42,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -55,14 +54,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, connection_string_names: { required: false, serialized_name: 'properties.connectionStringNames', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference.rb old mode 100644 new mode 100755 index 82ee72f19d..5de32d0f52 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference.rb @@ -8,7 +8,7 @@ module Models # # A setting difference between two deployment slots of an app. # - class SlotDifference < MsRestAzure::ProxyOnlyResource + class SlotDifference < MsRestAzure::Resource include MsRestAzure @@ -59,7 +59,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -72,14 +71,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, slot_difference_type: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_difference_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_swap_status.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slot_swap_status.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slow_requests_based_trigger.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/slow_requests_based_trigger.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot.rb old mode 100644 new mode 100755 index bef456e3b1..9539c708ec --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot.rb @@ -8,7 +8,7 @@ module Models # # A snapshot of an app. # - class Snapshot < MsRestAzure::ProxyOnlyResource + class Snapshot < MsRestAzure::Resource include MsRestAzure @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -52,14 +51,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, time: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_target.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_target.rb deleted file mode 100644 index 3d0471f8bb..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/snapshot_recovery_target.rb +++ /dev/null @@ -1,60 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # Specifies the web app that snapshot contents will be written to. - # - class SnapshotRecoveryTarget - - include MsRestAzure - - include MsRest::JSONable - # @return [String] Geographical location of the target web app, e.g. - # SouthEastAsia, SouthCentralUS - attr_accessor :location - - # @return [String] ARM resource ID of the target app. - # /subscriptions/{subId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{siteName} - # for production slots and - # /subscriptions/{subId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{siteName}/slots/{slotName} - # for other slots. - attr_accessor :id - - - # - # Mapper for SnapshotRecoveryTarget class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'SnapshotRecoveryTarget', - type: { - name: 'Composite', - class_name: 'SnapshotRecoveryTarget', - model_properties: { - location: { - required: false, - serialized_name: 'location', - type: { - name: 'String' - } - }, - id: { - required: false, - serialized_name: 'id', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control.rb old mode 100644 new mode 100755 index 98882133a4..19b35330af --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control.rb @@ -8,7 +8,7 @@ module Models # # The source control OAuth token. # - class SourceControl < MsRestAzure::ProxyOnlyResource + class SourceControl < MsRestAzure::Resource include MsRestAzure @@ -51,7 +51,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -64,14 +63,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, source_control_name: { required: false, serialized_name: 'properties.name', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/source_control_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ssl_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/ssl_state.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/stamp_capacity.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/stamp_capacity.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/stamp_capacity_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/stamp_capacity_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/status_codes_based_trigger.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/status_codes_based_trigger.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/status_options.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/status_options.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_options.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_options.rb old mode 100644 new mode 100755 index b287b17b15..f0b043afd4 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_options.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_options.rb @@ -8,7 +8,7 @@ module Models # # Options for app content migration. # - class StorageMigrationOptions < MsRestAzure::ProxyOnlyResource + class StorageMigrationOptions < MsRestAzure::Resource include MsRestAzure @@ -51,7 +51,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -64,14 +63,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, azurefiles_connection_string: { required: false, serialized_name: 'properties.azurefilesConnectionString', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_response.rb old mode 100644 new mode 100755 index fa92f86bbf..9c8620d690 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_response.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/storage_migration_response.rb @@ -8,7 +8,7 @@ module Models # # Response for a migration of app content request. # - class StorageMigrationResponse < MsRestAzure::ProxyOnlyResource + class StorageMigrationResponse < MsRestAzure::Resource include MsRestAzure @@ -40,7 +40,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -53,14 +52,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, operation_id: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/string_dictionary.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/string_dictionary.rb old mode 100644 new mode 100755 index 9fbae777d4..a4bc740378 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/string_dictionary.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/string_dictionary.rb @@ -8,7 +8,7 @@ module Models # # String dictionary resource. # - class StringDictionary < MsRestAzure::ProxyOnlyResource + class StringDictionary < MsRestAzure::Resource include MsRestAzure @@ -39,7 +39,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -52,14 +51,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, properties: { required: false, serialized_name: 'properties', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/tld_legal_agreement.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/tld_legal_agreement.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/tld_legal_agreement_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/tld_legal_agreement_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain.rb old mode 100644 new mode 100755 index 84dd2193c0..bb7cf58f0f --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain.rb @@ -8,7 +8,7 @@ module Models # # A top level domain object. # - class TopLevelDomain < MsRestAzure::ProxyOnlyResource + class TopLevelDomain < MsRestAzure::Resource include MsRestAzure @@ -43,7 +43,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -56,14 +55,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, domain_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain_agreement_option.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain_agreement_option.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/top_level_domain_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/unauthenticated_client_action.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/unauthenticated_client_action.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage.rb old mode 100644 new mode 100755 index 4a15311a93..67a1e3756e --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage.rb @@ -8,7 +8,7 @@ module Models # # Usage of the quota resource. # - class Usage < MsRestAzure::ProxyOnlyResource + class Usage < MsRestAzure::Resource include MsRestAzure @@ -64,7 +64,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -77,14 +76,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, display_name: { required: false, read_only: true, diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage_state.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/usage_state.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/user.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/user.rb old mode 100644 new mode 100755 index 89b75f87f6..99cf3dc3d2 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/user.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/user.rb @@ -8,7 +8,7 @@ module Models # # User crendentials used for publishing activity. # - class User < MsRestAzure::ProxyOnlyResource + class User < MsRestAzure::Resource include MsRestAzure @@ -51,7 +51,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -64,14 +63,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, user_name: { required: false, serialized_name: 'properties.name', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_request.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_request.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_resource_types.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_resource_types.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_response.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_response.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_response_error.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/validate_response_error.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_application.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_application.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_directory.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_directory.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_ipmapping.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_ipmapping.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_network_profile.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/virtual_network_profile.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_gateway.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_gateway.rb old mode 100644 new mode 100755 index 76cd363fa5..610cf06f5b --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_gateway.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_gateway.rb @@ -9,7 +9,7 @@ module Models # The Virtual Network gateway contract. This is used to give the Virtual # Network gateway access to the VPN package. # - class VnetGateway < MsRestAzure::ProxyOnlyResource + class VnetGateway < MsRestAzure::Resource include MsRestAzure @@ -43,7 +43,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -56,14 +55,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, vnet_name: { required: false, serialized_name: 'properties.vnetName', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_info.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_info.rb old mode 100644 new mode 100755 index d280365c73..038b45a8fe --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_info.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_info.rb @@ -8,7 +8,7 @@ module Models # # Virtual Network information contract. # - class VnetInfo < MsRestAzure::ProxyOnlyResource + class VnetInfo include MsRestAzure @@ -49,40 +49,9 @@ def self.mapper() name: 'Composite', class_name: 'VnetInfo', model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, vnet_resource_id: { required: false, - serialized_name: 'properties.vnetResourceId', + serialized_name: 'vnetResourceId', type: { name: 'String' } @@ -90,14 +59,14 @@ def self.mapper() cert_thumbprint: { required: false, read_only: true, - serialized_name: 'properties.certThumbprint', + serialized_name: 'certThumbprint', type: { name: 'String' } }, cert_blob: { required: false, - serialized_name: 'properties.certBlob', + serialized_name: 'certBlob', type: { name: 'String' } @@ -105,7 +74,7 @@ def self.mapper() routes: { required: false, read_only: true, - serialized_name: 'properties.routes', + serialized_name: 'routes', type: { name: 'Sequence', element: { @@ -121,14 +90,14 @@ def self.mapper() resync_required: { required: false, read_only: true, - serialized_name: 'properties.resyncRequired', + serialized_name: 'resyncRequired', type: { name: 'Boolean' } }, dns_servers: { required: false, - serialized_name: 'properties.dnsServers', + serialized_name: 'dnsServers', type: { name: 'String' } diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_parameters.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_parameters.rb deleted file mode 100644 index cf24d29cd5..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_parameters.rb +++ /dev/null @@ -1,96 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # The required set of inputs to validate a VNET - # - class VnetParameters < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] The Resource Group of the VNET to be validated - attr_accessor :vnet_resource_group - - # @return [String] The name of the VNET to be validated - attr_accessor :vnet_name - - # @return [String] The subnet name to be validated - attr_accessor :vnet_subnet_name - - - # - # Mapper for VnetParameters class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'VnetParameters', - type: { - name: 'Composite', - class_name: 'VnetParameters', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - vnet_resource_group: { - required: false, - serialized_name: 'properties.vnetResourceGroup', - type: { - name: 'String' - } - }, - vnet_name: { - required: false, - serialized_name: 'properties.vnetName', - type: { - name: 'String' - } - }, - vnet_subnet_name: { - required: false, - serialized_name: 'properties.vnetSubnetName', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_route.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_route.rb old mode 100644 new mode 100755 index 5175ed3f43..5a4438d3e7 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_route.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_route.rb @@ -9,7 +9,7 @@ module Models # Virtual Network route contract used to pass routing information for a # Virtual Network. # - class VnetRoute < MsRestAzure::ProxyOnlyResource + class VnetRoute < MsRestAzure::Resource include MsRestAzure @@ -61,7 +61,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -74,14 +73,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, vnet_route_name: { required: false, serialized_name: 'properties.name', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_failure_details.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_failure_details.rb deleted file mode 100644 index 083ed51d25..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_failure_details.rb +++ /dev/null @@ -1,95 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # A class that describes the reason for a validation failure. - # - class VnetValidationFailureDetails < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [Boolean] A flag describing whether or not validation failed. - attr_accessor :failed - - # @return [Array] A list of tests that failed - # in the validation. - attr_accessor :failed_tests - - - # - # Mapper for VnetValidationFailureDetails class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'VnetValidationFailureDetails', - type: { - name: 'Composite', - class_name: 'VnetValidationFailureDetails', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - failed: { - required: false, - serialized_name: 'properties.failed', - type: { - name: 'Boolean' - } - }, - failed_tests: { - required: false, - serialized_name: 'properties.failedTests', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'VnetValidationTestFailureElementType', - type: { - name: 'Composite', - class_name: 'VnetValidationTestFailure' - } - } - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_test_failure.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_test_failure.rb deleted file mode 100644 index 4e04f76bd0..0000000000 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/vnet_validation_test_failure.rb +++ /dev/null @@ -1,87 +0,0 @@ -# encoding: utf-8 -# Code generated by Microsoft (R) AutoRest Code Generator 1.2.2.0 -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. - -module Azure::ARM::Web - module Models - # - # A class that describes a test that failed during NSG and UDR validation. - # - class VnetValidationTestFailure < MsRestAzure::ProxyOnlyResource - - include MsRestAzure - - include MsRest::JSONable - # @return [String] The name of the test that failed. - attr_accessor :test_name - - # @return [String] The details of what caused the failure, e.g. the - # blocking rule name, etc. - attr_accessor :details - - - # - # Mapper for VnetValidationTestFailure class as Ruby Hash. - # This will be used for serialization/deserialization. - # - def self.mapper() - { - required: false, - serialized_name: 'VnetValidationTestFailure', - type: { - name: 'Composite', - class_name: 'VnetValidationTestFailure', - model_properties: { - id: { - required: false, - read_only: true, - serialized_name: 'id', - type: { - name: 'String' - } - }, - name: { - required: false, - read_only: true, - serialized_name: 'name', - type: { - name: 'String' - } - }, - kind: { - required: false, - serialized_name: 'kind', - type: { - name: 'String' - } - }, - type: { - required: false, - read_only: true, - serialized_name: 'type', - type: { - name: 'String' - } - }, - test_name: { - required: false, - serialized_name: 'properties.testName', - type: { - name: 'String' - } - }, - details: { - required: false, - serialized_name: 'properties.details', - type: { - name: 'String' - } - } - } - } - } - end - end - end -end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/web_app_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/web_app_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/web_app_instance_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/web_app_instance_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_collection.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_collection.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_resource.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_resource.rb old mode 100644 new mode 100755 index dc2546611b..d8c60c0efe --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_resource.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_pool_resource.rb @@ -8,7 +8,7 @@ module Models # # Worker pool of an App Service Environment ARM resource. # - class WorkerPoolResource < MsRestAzure::ProxyOnlyResource + class WorkerPoolResource < MsRestAzure::Resource include MsRestAzure @@ -56,7 +56,6 @@ def self.mapper() }, name: { required: false, - read_only: true, serialized_name: 'name', type: { name: 'String' @@ -69,14 +68,34 @@ def self.mapper() name: 'String' } }, + location: { + required: true, + serialized_name: 'location', + type: { + name: 'String' + } + }, type: { required: false, - read_only: true, serialized_name: 'type', type: { name: 'String' } }, + tags: { + required: false, + serialized_name: 'tags', + type: { + name: 'Dictionary', + value: { + required: false, + serialized_name: 'StringElementType', + type: { + name: 'String' + } + } + } + }, worker_size_id: { required: false, serialized_name: 'properties.workerSizeId', diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_size_options.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/models/worker_size_options.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/module_definition.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/module_definition.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/provider.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/provider.rb old mode 100644 new mode 100755 index 8d9e180e27..fcfcf3c969 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/provider.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/provider.rb @@ -98,81 +98,6 @@ def get_available_stacks_async(custom_headers = nil) promise.execute end - # - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Array] operation results. - # - def list_operations(custom_headers = nil) - first_page = list_operations_as_lazy(custom_headers) - first_page.get_all_items - end - - # - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_operations_with_http_info(custom_headers = nil) - list_operations_async(custom_headers).value! - end - - # - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_operations_async(custom_headers = nil) - api_version = '2016-03-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'providers/Microsoft.Web/operations' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::CsmOperationCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - # # Get available application frameworks and their versions # @@ -252,104 +177,5 @@ def get_available_stacks_on_prem_async(custom_headers = nil) promise.execute end - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [CsmOperationCollection] operation results. - # - def list_operations_next(next_page_link, custom_headers = nil) - response = list_operations_next_async(next_page_link, custom_headers).value! - response.body unless response.nil? - end - - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_operations_next_with_http_info(next_page_link, custom_headers = nil) - list_operations_next_async(next_page_link, custom_headers).value! - end - - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_operations_next_async(next_page_link, custom_headers = nil) - fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = '{nextLink}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - skip_encoding_path_params: {'nextLink' => next_page_link}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::CsmOperationCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [CsmOperationCollection] which provide lazy access to pages of the - # response. - # - def list_operations_as_lazy(custom_headers = nil) - response = list_operations_async(custom_headers).value! - unless response.nil? - page = response.body - page.next_method = Proc.new do |next_page_link| - list_operations_next_async(next_page_link, custom_headers) - end - page - end - end - end end diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/recommendations.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/recommendations.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/top_level_domains.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/top_level_domains.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/version.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/version.rb old mode 100644 new mode 100755 diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_apps.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_apps.rb old mode 100644 new mode 100755 index f074acd40d..e0f6bb81bb --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_apps.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_apps.rb @@ -5046,54 +5046,54 @@ def update_domain_ownership_identifier_async(resource_group_name, name, domain_o end # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [Array] operation results. # - def get_msdeploy_status(resource_group_name, name, custom_headers = nil) - response = get_msdeploy_status_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? + def list_host_name_bindings(resource_group_name, name, custom_headers = nil) + first_page = list_host_name_bindings_as_lazy(resource_group_name, name, custom_headers) + first_page.get_all_items end # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_msdeploy_status_with_http_info(resource_group_name, name, custom_headers = nil) - get_msdeploy_status_async(resource_group_name, name, custom_headers).value! + def list_host_name_bindings_with_http_info(resource_group_name, name, custom_headers = nil) + list_host_name_bindings_async(resource_group_name, name, custom_headers).value! end # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # - # Invoke the MSDeploy web app extension as pass-through API + # Get hostname bindings for an app or a deployment slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_msdeploy_status_async(resource_group_name, name, custom_headers = nil) + def list_host_name_bindings_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? @@ -5105,7 +5105,7 @@ def get_msdeploy_status_async(resource_group_name, name, custom_headers = nil) # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings' request_url = @base_url || @client.base_url @@ -5132,7 +5132,7 @@ def get_msdeploy_status_async(resource_group_name, name, custom_headers = nil) if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::HostNameBindingCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -5146,104 +5146,60 @@ def get_msdeploy_status_async(resource_group_name, name, custom_headers = nil) end # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MSDeployStatus] operation results. - # - def create_msdeploy_operation(resource_group_name, name, msdeploy, custom_headers = nil) - response = create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers).value! - response.body unless response.nil? - end - - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers = nil) - # Send request - promise = begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployLog] operation results. + # @return [HostNameBinding] operation results. # - def get_msdeploy_log(resource_group_name, name, custom_headers = nil) - response = get_msdeploy_log_async(resource_group_name, name, custom_headers).value! + def get_host_name_binding(resource_group_name, name, host_name, custom_headers = nil) + response = get_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_msdeploy_log_with_http_info(resource_group_name, name, custom_headers = nil) - get_msdeploy_log_async(resource_group_name, name, custom_headers).value! + def get_host_name_binding_with_http_info(resource_group_name, name, host_name, custom_headers = nil) + get_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_msdeploy_log_async(resource_group_name, name, custom_headers = nil) + def get_host_name_binding_async(resource_group_name, name, host_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5253,13 +5209,13 @@ def get_msdeploy_log_async(resource_group_name, name, custom_headers = nil) # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy/log' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -5280,7 +5236,7 @@ def get_msdeploy_log_async(resource_group_name, name, custom_headers = nil) if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployLog.mapper() + result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -5294,56 +5250,67 @@ def get_msdeploy_log_async(resource_group_name, name, custom_headers = nil) end # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [String] operation results. + # @return [HostNameBinding] operation results. # - def get_functions_admin_token(resource_group_name, name, custom_headers = nil) - response = get_functions_admin_token_async(resource_group_name, name, custom_headers).value! + def create_or_update_host_name_binding(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) + response = create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers).value! response.body unless response.nil? end # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_functions_admin_token_with_http_info(resource_group_name, name, custom_headers = nil) - get_functions_admin_token_async(resource_group_name, name, custom_headers).value! + def create_or_update_host_name_binding_with_http_info(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) + create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers).value! end # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # - # Fetch a short lived token that can be exchanged for a master key. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_functions_admin_token_async(resource_group_name, name, custom_headers = nil) + def create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? + fail ArgumentError, 'host_name_binding is nil' if host_name_binding.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5353,18 +5320,27 @@ def get_functions_admin_token_async(resource_group_name, name, custom_headers = # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/functions/admin/token' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + request_content = @client.serialize(request_mapper, host_name_binding) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -5380,13 +5356,7 @@ def get_functions_admin_token_async(resource_group_name, name, custom_headers = if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } + result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -5400,56 +5370,59 @@ def get_functions_admin_token_async(resource_group_name, name, custom_headers = end # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. # - def list_host_name_bindings(resource_group_name, name, custom_headers = nil) - first_page = list_host_name_bindings_as_lazy(resource_group_name, name, custom_headers) - first_page.get_all_items + def delete_host_name_binding(resource_group_name, name, host_name, custom_headers = nil) + response = delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! + nil end # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_host_name_bindings_with_http_info(resource_group_name, name, custom_headers = nil) - list_host_name_bindings_async(resource_group_name, name, custom_headers).value! + def delete_host_name_binding_with_http_info(resource_group_name, name, host_name, custom_headers = nil) + delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! end # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # - # Get hostname bindings for an app or a deployment slot. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_host_name_bindings_async(resource_group_name, name, custom_headers = nil) + def delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5459,39 +5432,29 @@ def list_host_name_bindings_async(resource_group_name, name, custom_headers = ni # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBindingCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -5500,60 +5463,64 @@ def list_host_name_bindings_async(resource_group_name, name, custom_headers = ni end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HostNameBinding] operation results. + # @return [HybridConnection] operation results. # - def get_host_name_binding(resource_group_name, name, host_name, custom_headers = nil) - response = get_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! + def get_hybrid_connection(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + response = get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! response.body unless response.nil? end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_host_name_binding_with_http_info(resource_group_name, name, host_name, custom_headers = nil) - get_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! + def get_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_host_name_binding_async(resource_group_name, name, host_name, custom_headers = nil) + def get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5563,13 +5530,13 @@ def get_host_name_binding_async(resource_group_name, name, host_name, custom_hea # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -5590,7 +5557,7 @@ def get_host_name_binding_async(resource_group_name, name, host_name, custom_hea if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -5604,67 +5571,71 @@ def get_host_name_binding_async(resource_group_name, name, host_name, custom_hea end # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HostNameBinding] operation results. + # @return [HybridConnection] operation results. # - def create_or_update_host_name_binding(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) - response = create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers).value! + def create_or_update_hybrid_connection(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + response = create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! response.body unless response.nil? end # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_host_name_binding_with_http_info(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) - create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers).value! + def create_or_update_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! end # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Creates a hostname binding for an app. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_host_name_binding_async(resource_group_name, name, host_name, host_name_binding, custom_headers = nil) + def create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? - fail ArgumentError, 'host_name_binding is nil' if host_name_binding.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5678,17 +5649,17 @@ def create_or_update_host_name_binding_async(resource_group_name, name, host_nam request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() - request_content = @client.serialize(request_mapper, host_name_binding) + request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), @@ -5710,7 +5681,7 @@ def create_or_update_host_name_binding_async(resource_group_name, name, host_nam if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -5724,59 +5695,63 @@ def create_or_update_host_name_binding_async(resource_group_name, name, host_nam end # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # - def delete_host_name_binding(resource_group_name, name, host_name, custom_headers = nil) - response = delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! + def delete_hybrid_connection(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + response = delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! nil end # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_host_name_binding_with_http_info(resource_group_name, name, host_name, custom_headers = nil) - delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers).value! + def delete_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! end # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # - # Deletes a hostname binding for an app. + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_host_name_binding_async(resource_group_name, name, host_name, custom_headers = nil) + def delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5786,13 +5761,13 @@ def delete_host_name_binding_async(resource_group_name, name, host_name, custom_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hostNameBindings/{hostName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -5803,7 +5778,7 @@ def delete_host_name_binding_async(resource_group_name, name, host_name, custom_ http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -5817,64 +5792,71 @@ def delete_host_name_binding_async(resource_group_name, name, host_name, custom_ end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [HybridConnection] operation results. # - def get_hybrid_connection(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - response = get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! + def update_hybrid_connection(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + response = update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! response.body unless response.nil? end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! + def update_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + def update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5884,6 +5866,14 @@ def get_hybrid_connection_async(resource_group_name, name, namespace_name, relay # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url @@ -5892,10 +5882,11 @@ def get_hybrid_connection_async(resource_group_name, name, namespace_name, relay middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response @@ -5925,71 +5916,64 @@ def get_hybrid_connection_async(resource_group_name, name, namespace_name, relay end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. + # @return [HybridConnectionKey] operation results. # - def create_or_update_hybrid_connection(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) - response = create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! + def list_hybrid_connection_keys(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + response = list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! response.body unless response.nil? end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) - create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! + def list_hybrid_connection_keys_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app # @param namespace_name [String] The namespace for this hybrid connection # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + def list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? fail ArgumentError, 'relay_name is nil' if relay_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -5999,15 +5983,7 @@ def create_or_update_hybrid_connection_async(resource_group_name, name, namespac # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}/listKeys' request_url = @base_url || @client.base_url @@ -6015,11 +5991,10 @@ def create_or_update_hybrid_connection_async(resource_group_name, name, namespac middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6035,7 +6010,7 @@ def create_or_update_hybrid_connection_async(resource_group_name, name, namespac if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnectionKey.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -6049,63 +6024,56 @@ def create_or_update_hybrid_connection_async(resource_group_name, name, namespac end # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [HybridConnection] operation results. # - def delete_hybrid_connection(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - response = delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! - nil + def list_hybrid_connections(resource_group_name, name, custom_headers = nil) + response = list_hybrid_connections_async(resource_group_name, name, custom_headers).value! + response.body unless response.nil? end # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! + def list_hybrid_connections_with_http_info(resource_group_name, name, custom_headers = nil) + list_hybrid_connections_async(resource_group_name, name, custom_headers).value! end # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Removes a Hybrid Connection from this site. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + def list_hybrid_connections_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6115,29 +6083,39 @@ def delete_hybrid_connection_async(resource_group_name, name, namespace_name, re # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionRelays' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -6146,71 +6124,62 @@ def delete_hybrid_connection_async(resource_group_name, name, namespace_name, re end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def update_hybrid_connection(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) - response = update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! + def list_relay_service_connections(resource_group_name, name, custom_headers = nil) + response = list_relay_service_connections_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_hybrid_connection_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) - update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers).value! + def list_relay_service_connections_with_http_info(resource_group_name, name, custom_headers = nil) + list_relay_service_connections_async(resource_group_name, name, custom_headers).value! end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection + # @param name [String] Name of the app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_hybrid_connection_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, custom_headers = nil) + def list_relay_service_connections_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6220,27 +6189,18 @@ def update_hybrid_connection_async(resource_group_name, name, namespace_name, re # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6256,7 +6216,7 @@ def update_hybrid_connection_async(resource_group_name, name, namespace_name, re if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -6270,64 +6230,60 @@ def update_hybrid_connection_async(resource_group_name, name, namespace_name, re end # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnectionKey] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def list_hybrid_connection_keys(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - response = list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! + def get_relay_service_connection(resource_group_name, name, entity_name, custom_headers = nil) + response = get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! response.body unless response.nil? end # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_hybrid_connection_keys_with_http_info(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) - list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers).value! + def get_relay_service_connection_with_http_info(resource_group_name, name, entity_name, custom_headers = nil) + get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! end # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # - # Gets the send key name and value for a Hybrid Connection. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, relay_name, custom_headers = nil) + def get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6337,18 +6293,18 @@ def list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}/listKeys' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6364,7 +6320,7 @@ def list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnectionKey.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -6378,56 +6334,73 @@ def list_hybrid_connection_keys_async(resource_group_name, name, namespace_name, end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def list_hybrid_connections(resource_group_name, name, custom_headers = nil) - response = list_hybrid_connections_async(resource_group_name, name, custom_headers).value! + def create_or_update_relay_service_connection(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + response = create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! response.body unless response.nil? end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_hybrid_connections_with_http_info(resource_group_name, name, custom_headers = nil) - list_hybrid_connections_async(resource_group_name, name, custom_headers).value! + def create_or_update_relay_service_connection_with_http_info(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_hybrid_connections_async(resource_group_name, name, custom_headers = nil) + def create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6437,18 +6410,27 @@ def list_hybrid_connections_async(resource_group_name, name, custom_headers = ni # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridConnectionRelays' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6464,7 +6446,7 @@ def list_hybrid_connections_async(resource_group_name, name, custom_headers = ni if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -6478,62 +6460,59 @@ def list_hybrid_connections_async(resource_group_name, name, custom_headers = ni end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. # - def list_relay_service_connections(resource_group_name, name, custom_headers = nil) - response = list_relay_service_connections_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? + def delete_relay_service_connection(resource_group_name, name, entity_name, custom_headers = nil) + response = delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! + nil end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_relay_service_connections_with_http_info(resource_group_name, name, custom_headers = nil) - list_relay_service_connections_async(resource_group_name, name, custom_headers).value! + def delete_relay_service_connection_with_http_info(resource_group_name, name, entity_name, custom_headers = nil) + delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_relay_service_connections_async(resource_group_name, name, custom_headers = nil) + def delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6543,39 +6522,29 @@ def list_relay_service_connections_async(resource_group_name, name, custom_heade # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -6584,60 +6553,73 @@ def list_relay_service_connections_async(resource_group_name, name, custom_heade end # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [RelayServiceConnectionEntity] operation results. # - def get_relay_service_connection(resource_group_name, name, entity_name, custom_headers = nil) - response = get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! + def update_relay_service_connection(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + response = update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! response.body unless response.nil? end # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_relay_service_connection_with_http_info(resource_group_name, name, entity_name, custom_headers = nil) - get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! + def update_relay_service_connection_with_http_info(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! end # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Gets a hybrid connection configuration by its name. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers = nil) + def update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6647,6 +6629,14 @@ def get_relay_service_connection_async(resource_group_name, name, entity_name, c # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url @@ -6655,10 +6645,11 @@ def get_relay_service_connection_async(resource_group_name, name, entity_name, c middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6688,73 +6679,56 @@ def get_relay_service_connection_async(resource_group_name, name, entity_name, c end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. + # @return [Array] operation results. # - def create_or_update_relay_service_connection(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) - response = create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! - response.body unless response.nil? + def list_instance_identifiers(resource_group_name, name, custom_headers = nil) + first_page = list_instance_identifiers_as_lazy(resource_group_name, name, custom_headers) + first_page.get_all_items end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_relay_service_connection_with_http_info(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) - create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! + def list_instance_identifiers_with_http_info(resource_group_name, name, custom_headers = nil) + list_instance_identifiers_async(resource_group_name, name, custom_headers).value! end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + def list_instance_identifiers_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6764,27 +6738,18 @@ def create_or_update_relay_service_connection_async(resource_group_name, name, e # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -6800,7 +6765,7 @@ def create_or_update_relay_service_connection_async(resource_group_name, name, e if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + result_mapper = Azure::ARM::Web::Models::WebAppInstanceCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -6814,59 +6779,72 @@ def create_or_update_relay_service_connection_async(resource_group_name, name, e end # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [Array] operation results. # - def delete_relay_service_connection(resource_group_name, name, entity_name, custom_headers = nil) - response = delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! - nil + def list_instance_deployments(resource_group_name, name, instance_id, custom_headers = nil) + first_page = list_instance_deployments_as_lazy(resource_group_name, name, instance_id, custom_headers) + first_page.get_all_items end # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_relay_service_connection_with_http_info(resource_group_name, name, entity_name, custom_headers = nil) - delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers).value! + def list_instance_deployments_with_http_info(resource_group_name, name, instance_id, custom_headers = nil) + list_instance_deployments_async(resource_group_name, name, instance_id, custom_headers).value! end # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Deletes a relay service connection by its name. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_relay_service_connection_async(resource_group_name, name, entity_name, custom_headers = nil) + def list_instance_deployments_async(resource_group_name, name, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6876,29 +6854,39 @@ def delete_relay_service_connection_async(resource_group_name, name, entity_name # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -6907,73 +6895,76 @@ def delete_relay_service_connection_async(resource_group_name, name, entity_name end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. + # @return [Deployment] operation results. # - def update_relay_service_connection(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) - response = update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! + def get_instance_deployment(resource_group_name, name, id, instance_id, custom_headers = nil) + response = get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! response.body unless response.nil? end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_relay_service_connection_with_http_info(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) - update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers).value! + def get_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, custom_headers = nil) + get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_relay_service_connection_async(resource_group_name, name, entity_name, connection_envelope, custom_headers = nil) + def get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? + fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -6983,27 +6974,18 @@ def update_relay_service_connection_async(resource_group_name, name, entity_name # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/hybridconnection/{entityName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -7019,7 +7001,7 @@ def update_relay_service_connection_async(resource_group_name, name, entity_name if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7033,56 +7015,80 @@ def update_relay_service_connection_async(resource_group_name, name, entity_name end # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [Deployment] operation results. # - def list_instance_identifiers(resource_group_name, name, custom_headers = nil) - first_page = list_instance_identifiers_as_lazy(resource_group_name, name, custom_headers) - first_page.get_all_items + def create_instance_deployment(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) + response = create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers).value! + response.body unless response.nil? end # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_instance_identifiers_with_http_info(resource_group_name, name, custom_headers = nil) - list_instance_identifiers_async(resource_group_name, name, custom_headers).value! + def create_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) + create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers).value! end # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets all scale-out instances of an app. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_instance_identifiers_async(resource_group_name, name, custom_headers = nil) + def create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? + fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7092,18 +7098,27 @@ def list_instance_identifiers_async(resource_group_name, name, custom_headers = # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances' - request_url = @base_url || @client.base_url + request_headers['Content-Type'] = 'application/json; charset=utf-8' - options = { + # Serialize Request + request_mapper = Azure::ARM::Web::Models::Deployment.mapper() + request_content = @client.serialize(request_mapper, deployment) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' + + request_url = @base_url || @client.base_url + + options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -7119,7 +7134,7 @@ def list_instance_identifiers_async(resource_group_name, name, custom_headers = if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::WebAppInstanceCollection.mapper() + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7133,71 +7148,74 @@ def list_instance_identifiers_async(resource_group_name, name, custom_headers = end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. # - def list_instance_deployments(resource_group_name, name, instance_id, custom_headers = nil) - first_page = list_instance_deployments_as_lazy(resource_group_name, name, instance_id, custom_headers) - first_page.get_all_items + def delete_instance_deployment(resource_group_name, name, id, instance_id, custom_headers = nil) + response = delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! + nil end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_instance_deployments_with_http_info(resource_group_name, name, instance_id, custom_headers = nil) - list_instance_deployments_async(resource_group_name, name, instance_id, custom_headers).value! + def delete_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, custom_headers = nil) + delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET + # @param id [String] Deployment ID. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_instance_deployments_async(resource_group_name, name, instance_id, custom_headers = nil) + def delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7208,39 +7226,29 @@ def list_instance_deployments_async(resource_group_name, name, instance_id, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -7249,76 +7257,56 @@ def list_instance_deployments_async(resource_group_name, name, instance_id, cust end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [SiteCloneability] operation results. # - def get_instance_deployment(resource_group_name, name, id, instance_id, custom_headers = nil) - response = get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! + def is_cloneable(resource_group_name, name, custom_headers = nil) + response = is_cloneable_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, custom_headers = nil) - get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! + def is_cloneable_with_http_info(resource_group_name, name, custom_headers = nil) + is_cloneable_async(resource_group_name, name, custom_headers).value! end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers = nil) + def is_cloneable_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7328,18 +7316,18 @@ def get_instance_deployment_async(resource_group_name, name, id, instance_id, cu # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/iscloneable' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -7355,7 +7343,7 @@ def get_instance_deployment_async(resource_group_name, name, id, instance_id, cu if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::SiteCloneability.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7369,80 +7357,56 @@ def get_instance_deployment_async(resource_group_name, name, id, instance_id, cu end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [Array] operation results. # - def create_instance_deployment(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) - response = create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers).value! - response.body unless response.nil? + def list_metric_definitions(resource_group_name, name, custom_headers = nil) + first_page = list_metric_definitions_as_lazy(resource_group_name, name, custom_headers) + first_page.get_all_items end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) - create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers).value! + def list_metric_definitions_with_http_info(resource_group_name, name, custom_headers = nil) + list_metric_definitions_async(resource_group_name, name, custom_headers).value! end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_instance_deployment_async(resource_group_name, name, id, instance_id, deployment, custom_headers = nil) + def list_metric_definitions_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? - fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7452,27 +7416,18 @@ def create_instance_deployment_async(resource_group_name, name, id, instance_id, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::Deployment.mapper() - request_content = @client.serialize(request_mapper, deployment) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/metricdefinitions' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -7488,7 +7443,7 @@ def create_instance_deployment_async(resource_group_name, name, id, instance_id, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::ResourceMetricDefinitionCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7502,75 +7457,74 @@ def create_instance_deployment_async(resource_group_name, name, id, instance_id, end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [Array] operation results. # - def delete_instance_deployment(resource_group_name, name, id, instance_id, custom_headers = nil) - response = delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! - nil + def list_metrics(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) + first_page = list_metrics_as_lazy(resource_group_name, name, details, filter, custom_headers) + first_page.get_all_items end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_instance_deployment_with_http_info(resource_group_name, name, id, instance_id, custom_headers = nil) - delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers).value! + def list_metrics_with_http_info(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) + list_metrics_async(resource_group_name, name, details, filter, custom_headers).value! end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_instance_deployment_async(resource_group_name, name, id, instance_id, custom_headers = nil) + def list_metrics_async(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7580,29 +7534,40 @@ def delete_instance_deployment_async(resource_group_name, name, id, instance_id, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/metrics' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + query_params: {'details' => details,'api-version' => api_version}, + skip_encoding_query_params: {'$filter' => filter}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::ResourceMetricCollection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -7611,126 +7576,72 @@ def delete_instance_deployment_async(resource_group_name, name, id, instance_id, end # - # Invoke the MSDeploy web app extension as pass-through API + # Restores a web app. # - # Invoke the MSDeploy web app extension as pass-through API + # Restores a web app. # + # @param subscription_name [String] Azure subscription # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance + # @param migration_options [StorageMigrationOptions] Migration migrationOptions # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [StorageMigrationResponse] operation results. # - def get_instance_ms_deploy_status(resource_group_name, name, instance_id, custom_headers = nil) - response = get_instance_ms_deploy_status_async(resource_group_name, name, instance_id, custom_headers).value! + def migrate_storage(subscription_name, resource_group_name, name, migration_options, custom_headers = nil) + response = migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # + # @param subscription_name [String] Azure subscription # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance + # @param migration_options [StorageMigrationOptions] Migration migrationOptions # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_instance_ms_deploy_status_with_http_info(resource_group_name, name, instance_id, custom_headers = nil) - get_instance_ms_deploy_status_async(resource_group_name, name, instance_id, custom_headers).value! - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. + # @return [Concurrent::Promise] promise which provides async access to http + # response. # - def get_instance_ms_deploy_status_async(resource_group_name, name, instance_id, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end + def migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers = nil) + # Send request + promise = begin_migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers) - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end + promise = promise.then do |response| + # Defining deserialization method. + deserialize_method = lambda do |parsed_response| + result_mapper = Azure::ARM::Web::Models::StorageMigrationResponse.mapper() + parsed_response = @client.deserialize(result_mapper, parsed_response) end - result + # Waiting for response. + @client.get_long_running_operation_result(response, deserialize_method) end - promise.execute + promise end # - # Invoke the MSDeploy web app extension as pass-through API + # Migrates a local (in-app) MySql database to a remote MySql database. # - # Invoke the MSDeploy web app extension as pass-through API + # Migrates a local (in-app) MySql database to a remote MySql database. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param migration_request_envelope [MigrateMySqlRequest] MySql migration + # options # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [Operation] operation results. # - def create_instance_msdeploy_operation(resource_group_name, name, instance_id, msdeploy, custom_headers = nil) - response = create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers).value! + def migrate_my_sql(resource_group_name, name, migration_request_envelope, custom_headers = nil) + response = migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers).value! response.body unless response.nil? end @@ -7738,22 +7649,22 @@ def create_instance_msdeploy_operation(resource_group_name, name, instance_id, m # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param migration_request_envelope [MigrateMySqlRequest] MySql migration + # options # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [Concurrent::Promise] promise which provides async access to http # response. # - def create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers = nil) + def migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers = nil) # Send request - promise = begin_create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers) + promise = begin_migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::Operation.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end @@ -7765,60 +7676,62 @@ def create_instance_msdeploy_operation_async(resource_group_name, name, instance end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployLog] operation results. + # @return [MigrateMySqlStatus] operation results. # - def get_instance_msdeploy_log(resource_group_name, name, instance_id, custom_headers = nil) - response = get_instance_msdeploy_log_async(resource_group_name, name, instance_id, custom_headers).value! + def get_migrate_my_sql_status(resource_group_name, name, custom_headers = nil) + response = get_migrate_my_sql_status_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_instance_msdeploy_log_with_http_info(resource_group_name, name, instance_id, custom_headers = nil) - get_instance_msdeploy_log_async(resource_group_name, name, instance_id, custom_headers).value! + def get_migrate_my_sql_status_with_http_info(resource_group_name, name, custom_headers = nil) + get_migrate_my_sql_status_async(resource_group_name, name, custom_headers).value! end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Invoke the MSDeploy Log web app extension as pass-through API + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_instance_msdeploy_log_async(resource_group_name, name, instance_id, custom_headers = nil) + def get_migrate_my_sql_status_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7828,13 +7741,13 @@ def get_instance_msdeploy_log_async(resource_group_name, name, instance_id, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy/log' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/migratemysql/status' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -7855,7 +7768,7 @@ def get_instance_msdeploy_log_async(resource_group_name, name, instance_id, cust if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployLog.mapper() + result_mapper = Azure::ARM::Web::Models::MigrateMySqlStatus.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7869,56 +7782,63 @@ def get_instance_msdeploy_log_async(resource_group_name, name, instance_id, cust end # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteCloneability] operation results. + # @return [NetworkFeatures] operation results. # - def is_cloneable(resource_group_name, name, custom_headers = nil) - response = is_cloneable_async(resource_group_name, name, custom_headers).value! + def list_network_features(resource_group_name, name, view, custom_headers = nil) + response = list_network_features_async(resource_group_name, name, view, custom_headers).value! response.body unless response.nil? end # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def is_cloneable_with_http_info(resource_group_name, name, custom_headers = nil) - is_cloneable_async(resource_group_name, name, custom_headers).value! + def list_network_features_with_http_info(resource_group_name, name, view, custom_headers = nil) + list_network_features_async(resource_group_name, name, view, custom_headers).value! end # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # - # Shows whether an app can be cloned to another resource group or subscription. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def is_cloneable_async(resource_group_name, name, custom_headers = nil) + def list_network_features_async(resource_group_name, name, view, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'view is nil' if view.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -7928,24 +7848,24 @@ def is_cloneable_async(resource_group_name, name, custom_headers = nil) # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/iscloneable' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkFeatures/{view}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'view' => view,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -7955,7 +7875,7 @@ def is_cloneable_async(resource_group_name, name, custom_headers = nil) if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteCloneability.mapper() + result_mapper = Azure::ARM::Web::Models::NetworkFeatures.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -7969,54 +7889,69 @@ def is_cloneable_async(resource_group_name, name, custom_headers = nil) end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] The name of the web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [String] operation results. # - def list_metric_definitions(resource_group_name, name, custom_headers = nil) - first_page = list_metric_definitions_as_lazy(resource_group_name, name, custom_headers) - first_page.get_all_items + def start_web_site_network_trace(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) + response = start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! + response.body unless response.nil? end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] The name of the web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_metric_definitions_with_http_info(resource_group_name, name, custom_headers = nil) - list_metric_definitions_async(resource_group_name, name, custom_headers).value! + def start_web_site_network_trace_with_http_info(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) + start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] The name of the web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_metric_definitions_async(resource_group_name, name, custom_headers = nil) + def start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? @@ -8028,18 +7963,18 @@ def list_metric_definitions_async(resource_group_name, name, custom_headers = ni # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/metricdefinitions' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/start' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + query_params: {'durationInSeconds' => duration_in_seconds,'maxFrameLength' => max_frame_length,'sasUrl' => sas_url,'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -8055,7 +7990,13 @@ def list_metric_definitions_async(resource_group_name, name, custom_headers = ni if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ResourceMetricDefinitionCollection.mapper() + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'String' + } + } result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -8069,2043 +8010,54 @@ def list_metric_definitions_async(resource_group_name, name, custom_headers = ni end # - # Gets performance metrics of an app (or deployment slot, if specified). + # Stop ongoing capturing network packets for the site. # - # Gets performance metrics of an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Array] operation results. - # - def list_metrics(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) - first_page = list_metrics_as_lazy(resource_group_name, name, details, filter, custom_headers) - first_page.get_all_items - end - - # - # Gets performance metrics of an app (or deployment slot, if specified). - # - # Gets performance metrics of an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_metrics_with_http_info(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) - list_metrics_async(resource_group_name, name, details, filter, custom_headers).value! - end - - # - # Gets performance metrics of an app (or deployment slot, if specified). - # - # Gets performance metrics of an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_metrics_async(resource_group_name, name, details = nil, filter = nil, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/metrics' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'details' => details,'api-version' => api_version}, - skip_encoding_query_params: {'$filter' => filter}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ResourceMetricCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Restores a web app. - # - # Restores a web app. - # - # @param subscription_name [String] Azure subscription - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param migration_options [StorageMigrationOptions] Migration migrationOptions - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [StorageMigrationResponse] operation results. - # - def migrate_storage(subscription_name, resource_group_name, name, migration_options, custom_headers = nil) - response = migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers).value! - response.body unless response.nil? - end - - # - # @param subscription_name [String] Azure subscription - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param migration_options [StorageMigrationOptions] Migration migrationOptions - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers = nil) - # Send request - promise = begin_migrate_storage_async(subscription_name, resource_group_name, name, migration_options, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::StorageMigrationResponse.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Migrates a local (in-app) MySql database to a remote MySql database. - # - # Migrates a local (in-app) MySql database to a remote MySql database. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param migration_request_envelope [MigrateMySqlRequest] MySql migration - # options - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Operation] operation results. - # - def migrate_my_sql(resource_group_name, name, migration_request_envelope, custom_headers = nil) - response = migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers).value! - response.body unless response.nil? - end - - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param migration_request_envelope [MigrateMySqlRequest] MySql migration - # options - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers = nil) - # Send request - promise = begin_migrate_my_sql_async(resource_group_name, name, migration_request_envelope, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::Operation.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MigrateMySqlStatus] operation results. - # - def get_migrate_my_sql_status(resource_group_name, name, custom_headers = nil) - response = get_migrate_my_sql_status_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? - end - - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_migrate_my_sql_status_with_http_info(resource_group_name, name, custom_headers = nil) - get_migrate_my_sql_status_async(resource_group_name, name, custom_headers).value! - end - - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def get_migrate_my_sql_status_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/migratemysql/status' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MigrateMySqlStatus.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [NetworkFeatures] operation results. - # - def list_network_features(resource_group_name, name, view, custom_headers = nil) - response = list_network_features_async(resource_group_name, name, view, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_network_features_with_http_info(resource_group_name, name, view, custom_headers = nil) - list_network_features_async(resource_group_name, name, view, custom_headers).value! - end - - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # Gets all network features used by the app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_network_features_async(resource_group_name, name, view, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'view is nil' if view.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkFeatures/{view}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'view' => view,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 || status_code == 404 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::NetworkFeatures.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Start capturing network packets for the site. - # - # Start capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [String] operation results. - # - def start_web_site_network_trace(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) - response = start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! - response.body unless response.nil? - end - - # - # Start capturing network packets for the site. - # - # Start capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def start_web_site_network_trace_with_http_info(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) - start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! - end - - # - # Start capturing network packets for the site. - # - # Start capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def start_web_site_network_trace_async(resource_group_name, name, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/start' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'durationInSeconds' => duration_in_seconds,'maxFrameLength' => max_frame_length,'sasUrl' => sas_url,'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Stop ongoing capturing network packets for the site. - # - # Stop ongoing capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [String] operation results. - # - def stop_web_site_network_trace(resource_group_name, name, custom_headers = nil) - response = stop_web_site_network_trace_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? - end - - # - # Stop ongoing capturing network packets for the site. - # - # Stop ongoing capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def stop_web_site_network_trace_with_http_info(resource_group_name, name, custom_headers = nil) - stop_web_site_network_trace_async(resource_group_name, name, custom_headers).value! - end - - # - # Stop ongoing capturing network packets for the site. - # - # Stop ongoing capturing network packets for the site. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def stop_web_site_network_trace_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/stop' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # - def generate_new_site_publishing_password(resource_group_name, name, custom_headers = nil) - response = generate_new_site_publishing_password_async(resource_group_name, name, custom_headers).value! - nil - end - - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def generate_new_site_publishing_password_with_http_info(resource_group_name, name, custom_headers = nil) - generate_new_site_publishing_password_async(resource_group_name, name, custom_headers).value! - end - - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # Generates a new publishing password for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def generate_new_site_publishing_password_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/newpassword' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 204 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - - result - end - - promise.execute - end - - # - # Gets perfmon counters for web app. - # - # Gets perfmon counters for web app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Array] operation results. - # - def list_perf_mon_counters(resource_group_name, name, filter = nil, custom_headers = nil) - first_page = list_perf_mon_counters_as_lazy(resource_group_name, name, filter, custom_headers) - first_page.get_all_items - end - - # - # Gets perfmon counters for web app. - # - # Gets perfmon counters for web app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_perf_mon_counters_with_http_info(resource_group_name, name, filter = nil, custom_headers = nil) - list_perf_mon_counters_async(resource_group_name, name, filter, custom_headers).value! - end - - # - # Gets perfmon counters for web app. - # - # Gets perfmon counters for web app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_perf_mon_counters_async(resource_group_name, name, filter = nil, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/perfcounters' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - skip_encoding_query_params: {'$filter' => filter}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PerfMonCounterCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets web app's event logs. - # - # Gets web app's event logs. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [SitePhpErrorLogFlag] operation results. - # - def get_site_php_error_log_flag(resource_group_name, name, custom_headers = nil) - response = get_site_php_error_log_flag_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets web app's event logs. - # - # Gets web app's event logs. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_site_php_error_log_flag_with_http_info(resource_group_name, name, custom_headers = nil) - get_site_php_error_log_flag_async(resource_group_name, name, custom_headers).value! - end - - # - # Gets web app's event logs. - # - # Gets web app's event logs. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def get_site_php_error_log_flag_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/phplogging' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SitePhpErrorLogFlag.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets the premier add-ons of an app. - # - # Gets the premier add-ons of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PremierAddOn] operation results. - # - def list_premier_add_ons(resource_group_name, name, custom_headers = nil) - response = list_premier_add_ons_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets the premier add-ons of an app. - # - # Gets the premier add-ons of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_premier_add_ons_with_http_info(resource_group_name, name, custom_headers = nil) - list_premier_add_ons_async(resource_group_name, name, custom_headers).value! - end - - # - # Gets the premier add-ons of an app. - # - # Gets the premier add-ons of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_premier_add_ons_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets a named add-on of an app. - # - # Gets a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PremierAddOn] operation results. - # - def get_premier_add_on(resource_group_name, name, premier_add_on_name, custom_headers = nil) - response = get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets a named add-on of an app. - # - # Gets a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, custom_headers = nil) - get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! - end - - # - # Gets a named add-on of an app. - # - # Gets a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Updates a named add-on of an app. - # - # Updates a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PremierAddOn] operation results. - # - def add_premier_add_on(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) - response = add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers).value! - response.body unless response.nil? - end - - # - # Updates a named add-on of an app. - # - # Updates a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def add_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) - add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers).value! - end - - # - # Updates a named add-on of an app. - # - # Updates a named add-on of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? - fail ArgumentError, 'premier_add_on is nil' if premier_add_on.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - request_content = @client.serialize(request_mapper, premier_add_on) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:put, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Delete a premier add-on from an app. - # - # Delete a premier add-on from an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # - def delete_premier_add_on(resource_group_name, name, premier_add_on_name, custom_headers = nil) - response = delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! - nil - end - - # - # Delete a premier add-on from an app. - # - # Delete a premier add-on from an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def delete_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, custom_headers = nil) - delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! - end - - # - # Delete a premier add-on from an app. - # - # Delete a premier add-on from an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:delete, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - - result - end - - promise.execute - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Array] operation results. - # - def list_public_certificates(resource_group_name, name, custom_headers = nil) - first_page = list_public_certificates_as_lazy(resource_group_name, name, custom_headers) - first_page.get_all_items - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_public_certificates_with_http_info(resource_group_name, name, custom_headers = nil) - list_public_certificates_async(resource_group_name, name, custom_headers).value! - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_public_certificates_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificateCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public CertificateName - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificate] operation results. - # - def get_public_certificate(resource_group_name, name, public_certificate_name, custom_headers = nil) - response = get_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers).value! - response.body unless response.nil? - end - - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public CertificateName - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_public_certificate_with_http_info(resource_group_name, name, public_certificate_name, custom_headers = nil) - get_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers).value! - end - - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # Get the named public certificate for an app (or deployment slot, if - # specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public CertificateName - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def get_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'publicCertificateName' => public_certificate_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Creates a hostname binding for an app. - # - # Creates a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificate] operation results. - # - def create_or_update_public_certificate(resource_group_name, name, public_certificate_name, public_certificate, custom_headers = nil) - response = create_or_update_public_certificate_async(resource_group_name, name, public_certificate_name, public_certificate, custom_headers).value! - response.body unless response.nil? - end - - # - # Creates a hostname binding for an app. - # - # Creates a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def create_or_update_public_certificate_with_http_info(resource_group_name, name, public_certificate_name, public_certificate, custom_headers = nil) - create_or_update_public_certificate_async(resource_group_name, name, public_certificate_name, public_certificate, custom_headers).value! - end - - # - # Creates a hostname binding for an app. - # - # Creates a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def create_or_update_public_certificate_async(resource_group_name, name, public_certificate_name, public_certificate, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? - fail ArgumentError, 'public_certificate is nil' if public_certificate.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() - request_content = @client.serialize(request_mapper, public_certificate) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'publicCertificateName' => public_certificate_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:put, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Deletes a hostname binding for an app. - # - # Deletes a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public Certificate Name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # - def delete_public_certificate(resource_group_name, name, public_certificate_name, custom_headers = nil) - response = delete_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers).value! - nil - end - - # - # Deletes a hostname binding for an app. - # - # Deletes a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public Certificate Name. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def delete_public_certificate_with_http_info(resource_group_name, name, public_certificate_name, custom_headers = nil) - delete_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers).value! - end - - # - # Deletes a hostname binding for an app. - # - # Deletes a hostname binding for an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param public_certificate_name [String] Public Certificate Name. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def delete_public_certificate_async(resource_group_name, name, public_certificate_name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publicCertificates/{publicCertificateName}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'publicCertificateName' => public_certificate_name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:delete, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 || status_code == 204 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - - result - end - - promise.execute - end - - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies - # publishingProfileOptions for publishing profile. For example, use {"format": - # "FileZilla3"} to get a FileZilla publishing profile. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [NOT_IMPLEMENTED] operation results. - # - def list_publishing_profile_xml_with_secrets(resource_group_name, name, publishing_profile_options, custom_headers = nil) - response = list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies - # publishingProfileOptions for publishing profile. For example, use {"format": - # "FileZilla3"} to get a FileZilla publishing profile. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_publishing_profile_xml_with_secrets_with_http_info(resource_group_name, name, publishing_profile_options, custom_headers = nil) - list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers).value! - end - - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # Gets the publishing profile for an app (or deployment slot, if specified). - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies - # publishingProfileOptions for publishing profile. For example, use {"format": - # "FileZilla3"} to get a FileZilla publishing profile. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'publishing_profile_options is nil' if publishing_profile_options.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::CsmPublishingProfileOptions.mapper() - request_content = @client.serialize(request_mapper, publishing_profile_options) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publishxml' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'Stream' - } - } - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Recovers a deleted web app. - # - # Recovers a deleted web app. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param name [String] The name of the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RecoverResponse] operation results. + # @return [String] operation results. # - def recover(resource_group_name, name, recovery_entity, custom_headers = nil) - response = recover_async(resource_group_name, name, recovery_entity, custom_headers).value! + def stop_web_site_network_trace(resource_group_name, name, custom_headers = nil) + response = stop_web_site_network_trace_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def recover_async(resource_group_name, name, recovery_entity, custom_headers = nil) - # Send request - promise = begin_recover_async(resource_group_name, name, recovery_entity, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::RecoverResponse.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. - # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # - def reset_production_slot_config(resource_group_name, name, custom_headers = nil) - response = reset_production_slot_config_async(resource_group_name, name, custom_headers).value! - nil - end - - # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Stop ongoing capturing network packets for the site. # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] The name of the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def reset_production_slot_config_with_http_info(resource_group_name, name, custom_headers = nil) - reset_production_slot_config_async(resource_group_name, name, custom_headers).value! + def stop_web_site_network_trace_with_http_info(resource_group_name, name, custom_headers = nil) + stop_web_site_network_trace_async(resource_group_name, name, custom_headers).value! end # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Stop ongoing capturing network packets for the site. # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] The name of the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def reset_production_slot_config_async(resource_group_name, name, custom_headers = nil) + def stop_web_site_network_trace_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? @@ -10117,7 +8069,7 @@ def reset_production_slot_config_async(resource_group_name, name, custom_headers # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/resetSlotConfig' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/networkTrace/stop' request_url = @base_url || @client.base_url @@ -10140,6 +8092,22 @@ def reset_production_slot_config_async(resource_group_name, name, custom_headers end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'String' + } + } + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -10148,71 +8116,59 @@ def reset_production_slot_config_async(resource_group_name, name, custom_headers end # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param soft_restart [Boolean] Specify true to apply the configuration - # settings and restarts the app only if necessary. By default, the API always - # restarts and reprovisions the app. - # @param synchronous [Boolean] Specify true to block until the app is - # restarted. By default, it is set to false, and the API responds immediately - # (asynchronous). # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # - def restart(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) - response = restart_async(resource_group_name, name, soft_restart, synchronous, custom_headers).value! + def generate_new_site_publishing_password(resource_group_name, name, custom_headers = nil) + response = generate_new_site_publishing_password_async(resource_group_name, name, custom_headers).value! nil end # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param soft_restart [Boolean] Specify true to apply the configuration - # settings and restarts the app only if necessary. By default, the API always - # restarts and reprovisions the app. - # @param synchronous [Boolean] Specify true to block until the app is - # restarted. By default, it is set to false, and the API responds immediately - # (asynchronous). # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def restart_with_http_info(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) - restart_async(resource_group_name, name, soft_restart, synchronous, custom_headers).value! + def generate_new_site_publishing_password_with_http_info(resource_group_name, name, custom_headers = nil) + generate_new_site_publishing_password_async(resource_group_name, name, custom_headers).value! end # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Restarts an app (or deployment slot, if specified). + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param soft_restart [Boolean] Specify true to apply the configuration - # settings and restarts the app only if necessary. By default, the API always - # restarts and reprovisions the app. - # @param synchronous [Boolean] Specify true to block until the app is - # restarted. By default, it is set to false, and the API responds immediately - # (asynchronous). # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def restart_async(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) + def generate_new_site_publishing_password_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? @@ -10224,14 +8180,14 @@ def restart_async(resource_group_name, name, soft_restart = nil, synchronous = n # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/restart' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/newpassword' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'softRestart' => soft_restart,'synchronous' => synchronous,'api-version' => api_version}, + query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } @@ -10241,7 +8197,7 @@ def restart_async(resource_group_name, name, soft_restart = nil, synchronous = n http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -10255,54 +8211,66 @@ def restart_async(resource_group_name, name, soft_restart = nil, synchronous = n end # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] Name of web app + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [Array] operation results. # - def list_slots(resource_group_name, name, custom_headers = nil) - first_page = list_slots_as_lazy(resource_group_name, name, custom_headers) + def list_perf_mon_counters(resource_group_name, name, filter = nil, custom_headers = nil) + first_page = list_perf_mon_counters_as_lazy(resource_group_name, name, filter, custom_headers) first_page.get_all_items end # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] Name of web app + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_slots_with_http_info(resource_group_name, name, custom_headers = nil) - list_slots_async(resource_group_name, name, custom_headers).value! + def list_perf_mon_counters_with_http_info(resource_group_name, name, filter = nil, custom_headers = nil) + list_perf_mon_counters_async(resource_group_name, name, filter, custom_headers).value! end # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # - # Gets an app's deployment slots. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. + # @param name [String] Name of web app + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_slots_async(resource_group_name, name, custom_headers = nil) + def list_perf_mon_counters_async(resource_group_name, name, filter = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? @@ -10314,7 +8282,7 @@ def list_slots_async(resource_group_name, name, custom_headers = nil) # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/perfcounters' request_url = @base_url || @client.base_url @@ -10322,6 +8290,7 @@ def list_slots_async(resource_group_name, name, custom_headers = nil) middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + skip_encoding_query_params: {'$filter' => filter}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } @@ -10341,7 +8310,7 @@ def list_slots_async(resource_group_name, name, custom_headers = nil) if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::WebAppCollection.mapper() + result_mapper = Azure::ARM::Web::Models::PerfMonCounterCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -10355,63 +8324,56 @@ def list_slots_async(resource_group_name, name, custom_headers = nil) end # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns the production slot. + # @param name [String] Name of web app # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Site] operation results. + # @return [SitePhpErrorLogFlag] operation results. # - def get_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_site_php_error_log_flag(resource_group_name, name, custom_headers = nil) + response = get_site_php_error_log_flag_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns the production slot. + # @param name [String] Name of web app # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_site_php_error_log_flag_with_http_info(resource_group_name, name, custom_headers = nil) + get_site_php_error_log_flag_async(resource_group_name, name, custom_headers).value! end # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # - # Gets the details of a web, mobile, or API app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns the production slot. + # @param name [String] Name of web app # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_site_php_error_log_flag_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -10421,13 +8383,13 @@ def get_slot_async(resource_group_name, name, slot, custom_headers = nil) # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/phplogging' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -10448,7 +8410,7 @@ def get_slot_async(resource_group_name, name, slot, custom_headers = nil) if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Site.mapper() + result_mapper = Azure::ARM::Web::Models::SitePhpErrorLogFlag.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -10462,153 +8424,160 @@ def get_slot_async(resource_group_name, name, slot, custom_headers = nil) end # - # Creates a new web, mobile, or API app in an existing resource group, or - # updates an existing app. + # Gets the premier add-ons of an app. # - # Creates a new web, mobile, or API app in an existing resource group, or - # updates an existing app. + # Gets the premier add-ons of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Unique name of the app to create or update. To create or - # update a deployment slot, use the {slot} parameter. - # @param site_envelope [Site] A JSON representation of the app properties. See - # example. - # @param slot [String] Name of the deployment slot to create or update. By - # default, this API attempts to create or modify the production slot. - # @param skip_dns_registration [Boolean] If true web app hostname is not - # registered with DNS on creation. This parameter is - # only used for app creation - # @param skip_custom_domain_verification [Boolean] If true, custom (non - # *.azurewebsites.net) domains associated with web app are not verified. - # @param force_dns_registration [Boolean] If true, web app hostname is force - # registered with DNS - # @param ttl_in_seconds [String] Time to live in seconds for web app's default - # domain name + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Site] operation results. + # @return [PremierAddOn] operation results. # - def create_or_update_slot(resource_group_name, name, site_envelope, slot, skip_dns_registration = nil, skip_custom_domain_verification = nil, force_dns_registration = nil, ttl_in_seconds = nil, custom_headers = nil) - response = create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration, skip_custom_domain_verification, force_dns_registration, ttl_in_seconds, custom_headers).value! + def list_premier_add_ons(resource_group_name, name, custom_headers = nil) + response = list_premier_add_ons_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end + # + # Gets the premier add-ons of an app. + # + # Gets the premier add-ons of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Unique name of the app to create or update. To create or - # update a deployment slot, use the {slot} parameter. - # @param site_envelope [Site] A JSON representation of the app properties. See - # example. - # @param slot [String] Name of the deployment slot to create or update. By - # default, this API attempts to create or modify the production slot. - # @param skip_dns_registration [Boolean] If true web app hostname is not - # registered with DNS on creation. This parameter is - # only used for app creation - # @param skip_custom_domain_verification [Boolean] If true, custom (non - # *.azurewebsites.net) domains associated with web app are not verified. - # @param force_dns_registration [Boolean] If true, web app hostname is force - # registered with DNS - # @param ttl_in_seconds [String] Time to live in seconds for web app's default - # domain name + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Concurrent::Promise] promise which provides async access to http - # response. + # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration = nil, skip_custom_domain_verification = nil, force_dns_registration = nil, ttl_in_seconds = nil, custom_headers = nil) - # Send request - promise = begin_create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration, skip_custom_domain_verification, force_dns_registration, ttl_in_seconds, custom_headers) + def list_premier_add_ons_with_http_info(resource_group_name, name, custom_headers = nil) + list_premier_add_ons_async(resource_group_name, name, custom_headers).value! + end + + # + # Gets the premier add-ons of an app. + # + # Gets the premier add-ons of an app. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param [Hash{String => String}] A hash of custom headers that will be added + # to the HTTP request. + # + # @return [Concurrent::Promise] Promise object which holds the HTTP response. + # + def list_premier_add_ons_async(resource_group_name, name, custom_headers = nil) + fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? + fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? + api_version = '2016-08-01' + + + request_headers = {} + + # Set Headers + request_headers['x-ms-client-request-id'] = SecureRandom.uuid + request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons' + + request_url = @base_url || @client.base_url + + options = { + middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + query_params: {'api-version' => api_version}, + headers: request_headers.merge(custom_headers || {}), + base_url: request_url + } + promise = @client.make_request_async(:get, path_template, options) - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::Site.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) + promise = promise.then do |result| + http_response = result.response + status_code = http_response.status + response_content = http_response.body + unless status_code == 200 + error_model = JSON.load(response_content) + fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) + result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end + + result end - promise + promise.execute end # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app to delete. - # @param slot [String] Name of the deployment slot to delete. By default, the - # API deletes the production slot. - # @param delete_metrics [Boolean] If true, web app metrics are also deleted - # @param delete_empty_server_farm [Boolean] Specify true if the App Service - # plan will be empty after app deletion and you want to delete the empty App - # Service plan. By default, the empty App Service plan is not deleted. - # @param skip_dns_registration [Boolean] If true, DNS registration is skipped + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [PremierAddOn] operation results. # - def delete_slot(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) - response = delete_slot_async(resource_group_name, name, slot, delete_metrics, delete_empty_server_farm, skip_dns_registration, custom_headers).value! - nil + def get_premier_add_on(resource_group_name, name, premier_add_on_name, custom_headers = nil) + response = get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! + response.body unless response.nil? end # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app to delete. - # @param slot [String] Name of the deployment slot to delete. By default, the - # API deletes the production slot. - # @param delete_metrics [Boolean] If true, web app metrics are also deleted - # @param delete_empty_server_farm [Boolean] Specify true if the App Service - # plan will be empty after app deletion and you want to delete the empty App - # Service plan. By default, the empty App Service plan is not deleted. - # @param skip_dns_registration [Boolean] If true, DNS registration is skipped + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_slot_with_http_info(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) - delete_slot_async(resource_group_name, name, slot, delete_metrics, delete_empty_server_farm, skip_dns_registration, custom_headers).value! + def get_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, custom_headers = nil) + get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! end # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # - # Deletes a web, mobile, or API app, or one of the deployment slots. + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app to delete. - # @param slot [String] Name of the deployment slot to delete. By default, the - # API deletes the production slot. - # @param delete_metrics [Boolean] If true, web app metrics are also deleted - # @param delete_empty_server_farm [Boolean] Specify true if the App Service - # plan will be empty after app deletion and you want to delete the empty App - # Service plan. By default, the empty App Service plan is not deleted. - # @param skip_dns_registration [Boolean] If true, DNS registration is skipped + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_slot_async(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) + def get_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -10618,29 +8587,39 @@ def delete_slot_async(resource_group_name, name, slot, delete_metrics = nil, del # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'deleteMetrics' => delete_metrics,'deleteEmptyServerFarm' => delete_empty_server_farm,'skipDnsRegistration' => skip_dns_registration,'api-version' => api_version}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, + query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -10649,66 +8628,67 @@ def delete_slot_async(resource_group_name, name, slot, delete_metrics = nil, del end # - # Analyze a custom hostname. + # Updates a named add-on of an app. # - # Analyze a custom hostname. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param host_name [String] Custom hostname + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [CustomHostnameAnalysisResult] operation results. + # @return [PremierAddOn] operation results. # - def analyze_custom_hostname_slot(resource_group_name, name, slot, host_name = nil, custom_headers = nil) - response = analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! + def add_premier_add_on(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) + response = add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers).value! response.body unless response.nil? end # - # Analyze a custom hostname. + # Updates a named add-on of an app. # - # Analyze a custom hostname. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param host_name [String] Custom hostname + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def analyze_custom_hostname_slot_with_http_info(resource_group_name, name, slot, host_name = nil, custom_headers = nil) - analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! + def add_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) + add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers).value! end # - # Analyze a custom hostname. + # Updates a named add-on of an app. # - # Analyze a custom hostname. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param host_name [String] Custom hostname + # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name = nil, custom_headers = nil) + def add_premier_add_on_async(resource_group_name, name, premier_add_on_name, premier_add_on, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? + fail ArgumentError, 'premier_add_on is nil' if premier_add_on.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -10718,18 +8698,27 @@ def analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_nam # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/analyzeCustomHostname' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + request_content = @client.serialize(request_mapper, premier_add_on) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'hostName' => host_name,'api-version' => api_version}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, + query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -10745,7 +8734,7 @@ def analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_nam if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::CustomHostnameAnalysisResult.mapper() + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -10759,75 +8748,59 @@ def analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_nam end # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target - # slot name. See example. - # @param slot [String] Name of the source slot. If a slot is not specified, the - # production slot is used as the source slot. + # @param premier_add_on_name [String] Add-on name. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # - def apply_slot_configuration_slot(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) - response = apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers).value! + def delete_premier_add_on(resource_group_name, name, premier_add_on_name, custom_headers = nil) + response = delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! nil end # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target - # slot name. See example. - # @param slot [String] Name of the source slot. If a slot is not specified, the - # production slot is used as the source slot. + # @param premier_add_on_name [String] Add-on name. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def apply_slot_configuration_slot_with_http_info(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) - apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers).value! + def delete_premier_add_on_with_http_info(resource_group_name, name, premier_add_on_name, custom_headers = nil) + delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers).value! end # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # - # Applies the configuration settings from the target slot onto the current - # slot. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target - # slot name. See example. - # @param slot [String] Name of the source slot. If a slot is not specified, the - # production slot is used as the source slot. + # @param premier_add_on_name [String] Add-on name. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) + def delete_premier_add_on_async(resource_group_name, name, premier_add_on_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot_swap_entity is nil' if slot_swap_entity.nil? - fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -10837,27 +8810,18 @@ def apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_ent # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::CsmSlotEntity.mapper() - request_content = @client.serialize(request_mapper, slot_swap_entity) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/applySlotConfig' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response @@ -10877,70 +8841,66 @@ def apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_ent end # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Backup configuration. You can use the JSON - # response from the POST action as input here. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a backup for the production slot. + # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies + # publishingProfileOptions for publishing profile. For example, use {"format": + # "FileZilla3"} to get a FileZilla publishing profile. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [BackupItem] operation results. + # @return [NOT_IMPLEMENTED] operation results. # - def backup_slot(resource_group_name, name, request, slot, custom_headers = nil) - response = backup_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def list_publishing_profile_xml_with_secrets(resource_group_name, name, publishing_profile_options, custom_headers = nil) + response = list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers).value! response.body unless response.nil? end # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Backup configuration. You can use the JSON - # response from the POST action as input here. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a backup for the production slot. + # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies + # publishingProfileOptions for publishing profile. For example, use {"format": + # "FileZilla3"} to get a FileZilla publishing profile. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def backup_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) - backup_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def list_publishing_profile_xml_with_secrets_with_http_info(resource_group_name, name, publishing_profile_options, custom_headers = nil) + list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers).value! end # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # - # Creates a backup of an app. + # Gets the publishing profile for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Backup configuration. You can use the JSON - # response from the POST action as input here. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a backup for the production slot. + # @param publishing_profile_options [CsmPublishingProfileOptions] Specifies + # publishingProfileOptions for publishing profile. For example, use {"format": + # "FileZilla3"} to get a FileZilla publishing profile. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def backup_slot_async(resource_group_name, name, request, slot, custom_headers = nil) + def list_publishing_profile_xml_with_secrets_async(resource_group_name, name, publishing_profile_options, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'request is nil' if request.nil? - fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'publishing_profile_options is nil' if publishing_profile_options.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -10954,17 +8914,17 @@ def backup_slot_async(resource_group_name, name, request, slot, custom_headers = request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() - request_content = @client.serialize(request_mapper, request) + request_mapper = Azure::ARM::Web::Models::CsmPublishingProfileOptions.mapper() + request_content = @client.serialize(request_mapper, publishing_profile_options) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backup' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/publishxml' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), @@ -10986,7 +8946,13 @@ def backup_slot_async(resource_group_name, name, request, slot, custom_headers = if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'Stream' + } + } result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -11000,63 +8966,113 @@ def backup_slot_async(resource_group_name, name, request, slot, custom_headers = end # - # Gets existing backups of an app. + # Recovers a deleted web app. # - # Gets existing backups of an app. + # Recovers a deleted web app. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of web app + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [RecoverResponse] operation results. + # + def recover(resource_group_name, name, recovery_entity, custom_headers = nil) + response = recover_async(resource_group_name, name, recovery_entity, custom_headers).value! + response.body unless response.nil? + end + + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of web app + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [Concurrent::Promise] promise which provides async access to http + # response. + # + def recover_async(resource_group_name, name, recovery_entity, custom_headers = nil) + # Send request + promise = begin_recover_async(resource_group_name, name, recovery_entity, custom_headers) + + promise = promise.then do |response| + # Defining deserialization method. + deserialize_method = lambda do |parsed_response| + result_mapper = Azure::ARM::Web::Models::RecoverResponse.mapper() + parsed_response = @client.deserialize(result_mapper, parsed_response) + end + + # Waiting for response. + @client.get_long_running_operation_result(response, deserialize_method) + end + + promise + end + + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get backups of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. # - def list_backups_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_backups_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def reset_production_slot_config(resource_group_name, name, custom_headers = nil) + response = reset_production_slot_config_async(resource_group_name, name, custom_headers).value! + nil end # - # Gets existing backups of an app. + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. # - # Gets existing backups of an app. + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get backups of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_backups_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_backups_slot_async(resource_group_name, name, slot, custom_headers).value! + def reset_production_slot_config_with_http_info(resource_group_name, name, custom_headers = nil) + reset_production_slot_config_async(resource_group_name, name, custom_headers).value! end # - # Gets existing backups of an app. + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. # - # Gets existing backups of an app. + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get backups of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_backups_slot_async(resource_group_name, name, slot, custom_headers = nil) + def reset_production_slot_config_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11066,18 +9082,18 @@ def list_backups_slot_async(resource_group_name, name, slot, custom_headers = ni # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/resetSlotConfig' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -11089,16 +9105,6 @@ def list_backups_slot_async(resource_group_name, name, slot, custom_headers = ni end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupItemCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -11107,76 +9113,56 @@ def list_backups_slot_async(resource_group_name, name, slot, custom_headers = ni end # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param request [RestoreRequest] A RestoreRequest object that includes Azure - # storage URL and blog name for discovery of backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will perform discovery for the production slot. + # @param name [String] Name of web app # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RestoreRequest] operation results. + # @return [ResourceHealthMetadata] operation results. # - def discover_restore_slot(resource_group_name, name, request, slot, custom_headers = nil) - response = discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def get_resource_health_metadata(resource_group_name, name, custom_headers = nil) + response = get_resource_health_metadata_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param request [RestoreRequest] A RestoreRequest object that includes Azure - # storage URL and blog name for discovery of backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will perform discovery for the production slot. + # @param name [String] Name of web app # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def discover_restore_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) - discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def get_resource_health_metadata_with_http_info(resource_group_name, name, custom_headers = nil) + get_resource_health_metadata_async(resource_group_name, name, custom_headers).value! end # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Discovers an existing app backup that can be restored from a blob in Azure - # storage. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param request [RestoreRequest] A RestoreRequest object that includes Azure - # storage URL and blog name for discovery of backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will perform discovery for the production slot. + # @param name [String] Name of web app # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers = nil) + def get_resource_health_metadata_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'request is nil' if request.nil? - fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11186,27 +9172,18 @@ def discover_restore_slot_async(resource_group_name, name, request, slot, custom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() - request_content = @client.serialize(request_mapper, request) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/discover' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/resourceHealthMetadata' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -11222,7 +9199,7 @@ def discover_restore_slot_async(resource_group_name, name, request, slot, custom if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() + result_mapper = Azure::ARM::Web::Models::ResourceHealthMetadata.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -11236,67 +9213,73 @@ def discover_restore_slot_async(resource_group_name, name, request, slot, custom end # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a backup of the production slot. + # @param soft_restart [Boolean] Specify true to apply the configuration + # settings and restarts the app only if necessary. By default, the API always + # restarts and reprovisions the app. + # @param synchronous [Boolean] Specify true to block until the app is + # restarted. By default, it is set to false, and the API responds immediately + # (asynchronous). # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [BackupItem] operation results. # - def get_backup_status_slot(resource_group_name, name, backup_id, slot, custom_headers = nil) - response = get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! - response.body unless response.nil? + def restart(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) + response = restart_async(resource_group_name, name, soft_restart, synchronous, custom_headers).value! + nil end # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a backup of the production slot. + # @param soft_restart [Boolean] Specify true to apply the configuration + # settings and restarts the app only if necessary. By default, the API always + # restarts and reprovisions the app. + # @param synchronous [Boolean] Specify true to block until the app is + # restarted. By default, it is set to false, and the API responds immediately + # (asynchronous). # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_backup_status_slot_with_http_info(resource_group_name, name, backup_id, slot, custom_headers = nil) - get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! + def restart_with_http_info(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) + restart_async(resource_group_name, name, soft_restart, synchronous, custom_headers).value! end # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # - # Gets a backup of an app by its ID. + # Restarts an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a backup of the production slot. + # @param soft_restart [Boolean] Specify true to apply the configuration + # settings and restarts the app only if necessary. By default, the API always + # restarts and reprovisions the app. + # @param synchronous [Boolean] Specify true to block until the app is + # restarted. By default, it is set to false, and the API responds immediately + # (asynchronous). # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers = nil) + def restart_async(resource_group_name, name, soft_restart = nil, synchronous = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'backup_id is nil' if backup_id.nil? - fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11306,18 +9289,18 @@ def get_backup_status_slot_async(resource_group_name, name, backup_id, slot, cus # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/restart' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + query_params: {'softRestart' => soft_restart,'synchronous' => synchronous,'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -11329,16 +9312,6 @@ def get_backup_status_slot_async(resource_group_name, name, backup_id, slot, cus end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -11347,66 +9320,56 @@ def get_backup_status_slot_async(resource_group_name, name, backup_id, slot, cus end # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [Array] operation results. # - def delete_backup_slot(resource_group_name, name, backup_id, slot, custom_headers = nil) - response = delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! - nil + def list_slots(resource_group_name, name, custom_headers = nil) + first_page = list_slots_as_lazy(resource_group_name, name, custom_headers) + first_page.get_all_items end # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_backup_slot_with_http_info(resource_group_name, name, backup_id, slot, custom_headers = nil) - delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! + def list_slots_with_http_info(resource_group_name, name, custom_headers = nil) + list_slots_async(resource_group_name, name, custom_headers).value! end # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # - # Deletes a backup of an app by its ID. + # Gets an app's deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a backup of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers = nil) + def list_slots_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'backup_id is nil' if backup_id.nil? - fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11416,29 +9379,39 @@ def delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::WebAppCollection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -11447,88 +9420,62 @@ def delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_ end # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param backup_id [String] Id of backup - # @param request [BackupRequest] Information on backup request - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. By default, this API + # returns the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [BackupItem] operation results. + # @return [Site] operation results. # - def list_backup_status_secrets_slot(resource_group_name, name, backup_id, request, slot, custom_headers = nil) - response = list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! + def get_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param backup_id [String] Id of backup - # @param request [BackupRequest] Information on backup request - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. By default, this API + # returns the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_backup_status_secrets_slot_with_http_info(resource_group_name, name, backup_id, request, slot, custom_headers = nil) - list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! + def get_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # - # Gets status of a web app backup that may be in progress, including secrets - # associated with the backup, such as the Azure Storage SAS URL. Also can be - # used to update the SAS URL for the backup if a new URL is passed in the - # request body. + # Gets the details of a web, mobile, or API app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param backup_id [String] Id of backup - # @param request [BackupRequest] Information on backup request - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. By default, this API + # returns the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + def get_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'backup_id is nil' if backup_id.nil? - fail ArgumentError, 'request is nil' if request.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11539,27 +9486,18 @@ def list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() - request_content = @client.serialize(request_mapper, request) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -11575,7 +9513,7 @@ def list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() + result_mapper = Azure::ARM::Web::Models::Site.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -11589,49 +9527,71 @@ def list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, end # - # Restores a specific backup to another app (or deployment slot, if specified). + # Creates a new web, mobile, or API app in an existing resource group, or + # updates an existing app. # - # Restores a specific backup to another app (or deployment slot, if specified). + # Creates a new web, mobile, or API app in an existing resource group, or + # updates an existing app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param request [RestoreRequest] Information on restore request - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will restore a backup of the production slot. + # @param name [String] Unique name of the app to create or update. To create or + # update a deployment slot, use the {slot} parameter. + # @param site_envelope [Site] A JSON representation of the app properties. See + # example. + # @param slot [String] Name of the deployment slot to create or update. By + # default, this API attempts to create or modify the production slot. + # @param skip_dns_registration [Boolean] If true web app hostname is not + # registered with DNS on creation. This parameter is + # only used for app creation + # @param skip_custom_domain_verification [Boolean] If true, custom (non + # *.azurewebsites.net) domains associated with web app are not verified. + # @param force_dns_registration [Boolean] If true, web app hostname is force + # registered with DNS + # @param ttl_in_seconds [String] Time to live in seconds for web app's default + # domain name # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RestoreResponse] operation results. + # @return [Site] operation results. # - def restore_slot(resource_group_name, name, backup_id, request, slot, custom_headers = nil) - response = restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! + def create_or_update_slot(resource_group_name, name, site_envelope, slot, skip_dns_registration = nil, skip_custom_domain_verification = nil, force_dns_registration = nil, ttl_in_seconds = nil, custom_headers = nil) + response = create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration, skip_custom_domain_verification, force_dns_registration, ttl_in_seconds, custom_headers).value! response.body unless response.nil? end # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param backup_id [String] ID of the backup. - # @param request [RestoreRequest] Information on restore request - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will restore a backup of the production slot. + # @param name [String] Unique name of the app to create or update. To create or + # update a deployment slot, use the {slot} parameter. + # @param site_envelope [Site] A JSON representation of the app properties. See + # example. + # @param slot [String] Name of the deployment slot to create or update. By + # default, this API attempts to create or modify the production slot. + # @param skip_dns_registration [Boolean] If true web app hostname is not + # registered with DNS on creation. This parameter is + # only used for app creation + # @param skip_custom_domain_verification [Boolean] If true, custom (non + # *.azurewebsites.net) domains associated with web app are not verified. + # @param force_dns_registration [Boolean] If true, web app hostname is force + # registered with DNS + # @param ttl_in_seconds [String] Time to live in seconds for web app's default + # domain name # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [Concurrent::Promise] promise which provides async access to http # response. # - def restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + def create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration = nil, skip_custom_domain_verification = nil, force_dns_registration = nil, ttl_in_seconds = nil, custom_headers = nil) # Send request - promise = begin_restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers) + promise = begin_create_or_update_slot_async(resource_group_name, name, site_envelope, slot, skip_dns_registration, skip_custom_domain_verification, force_dns_registration, ttl_in_seconds, custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() + result_mapper = Azure::ARM::Web::Models::Site.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end @@ -11643,60 +9603,74 @@ def restore_slot_async(resource_group_name, name, backup_id, request, slot, cust end # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # @param name [String] Name of the app to delete. + # @param slot [String] Name of the deployment slot to delete. By default, the + # API deletes the production slot. + # @param delete_metrics [Boolean] If true, web app metrics are also deleted + # @param delete_empty_server_farm [Boolean] Specify true if the App Service + # plan will be empty after app deletion and you want to delete the empty App + # Service plan. By default, the empty App Service plan is not deleted. + # @param skip_dns_registration [Boolean] If true, DNS registration is skipped # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. # - def list_configurations_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_configurations_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def delete_slot(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) + response = delete_slot_async(resource_group_name, name, slot, delete_metrics, delete_empty_server_farm, skip_dns_registration, custom_headers).value! + nil end # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # @param name [String] Name of the app to delete. + # @param slot [String] Name of the deployment slot to delete. By default, the + # API deletes the production slot. + # @param delete_metrics [Boolean] If true, web app metrics are also deleted + # @param delete_empty_server_farm [Boolean] Specify true if the App Service + # plan will be empty after app deletion and you want to delete the empty App + # Service plan. By default, the empty App Service plan is not deleted. + # @param skip_dns_registration [Boolean] If true, DNS registration is skipped # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_configurations_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_configurations_slot_async(resource_group_name, name, slot, custom_headers).value! + # + def delete_slot_with_http_info(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) + delete_slot_async(resource_group_name, name, slot, delete_metrics, delete_empty_server_farm, skip_dns_registration, custom_headers).value! end # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # - # List the configurations of an app + # Deletes a web, mobile, or API app, or one of the deployment slots. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # @param name [String] Name of the app to delete. + # @param slot [String] Name of the deployment slot to delete. By default, the + # API deletes the production slot. + # @param delete_metrics [Boolean] If true, web app metrics are also deleted + # @param delete_empty_server_farm [Boolean] Specify true if the App Service + # plan will be empty after app deletion and you want to delete the empty App + # Service plan. By default, the empty App Service plan is not deleted. + # @param skip_dns_registration [Boolean] If true, DNS registration is skipped # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_configurations_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_slot_async(resource_group_name, name, slot, delete_metrics = nil, delete_empty_server_farm = nil, skip_dns_registration = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -11709,39 +9683,29 @@ def list_configurations_slot_async(resource_group_name, name, slot, custom_heade # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + query_params: {'deleteMetrics' => delete_metrics,'deleteEmptyServerFarm' => delete_empty_server_farm,'skipDnsRegistration' => skip_dns_registration,'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteConfigResourceCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -11750,66 +9714,65 @@ def list_configurations_slot_async(resource_group_name, name, slot, custom_heade end # - # Replaces the application settings of an app. + # Analyze a custom hostname. # - # Replaces the application settings of an app. + # Analyze a custom hostname. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param app_settings [StringDictionary] Application settings of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the application settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. + # @param host_name [String] Custom hostname # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [StringDictionary] operation results. + # @return [CustomHostnameAnalysisResult] operation results. # - def update_application_settings_slot(resource_group_name, name, app_settings, slot, custom_headers = nil) - response = update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers).value! + def analyze_custom_hostname_slot(resource_group_name, name, slot, host_name = nil, custom_headers = nil) + response = analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! response.body unless response.nil? end # - # Replaces the application settings of an app. + # Analyze a custom hostname. # - # Replaces the application settings of an app. + # Analyze a custom hostname. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param app_settings [StringDictionary] Application settings of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the application settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. + # @param host_name [String] Custom hostname # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_application_settings_slot_with_http_info(resource_group_name, name, app_settings, slot, custom_headers = nil) - update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers).value! + def analyze_custom_hostname_slot_with_http_info(resource_group_name, name, slot, host_name = nil, custom_headers = nil) + analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! end # - # Replaces the application settings of an app. + # Analyze a custom hostname. # - # Replaces the application settings of an app. + # Analyze a custom hostname. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param app_settings [StringDictionary] Application settings of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the application settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. + # @param host_name [String] Custom hostname # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers = nil) + def analyze_custom_hostname_slot_async(resource_group_name, name, slot, host_name = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'app_settings is nil' if app_settings.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11820,27 +9783,18 @@ def update_application_settings_slot_async(resource_group_name, name, app_settin # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() - request_content = @client.serialize(request_mapper, app_settings) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/analyzeCustomHostname' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, + query_params: {'hostName' => host_name,'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -11856,7 +9810,7 @@ def update_application_settings_slot_async(resource_group_name, name, app_settin if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + result_mapper = Azure::ARM::Web::Models::CustomHostnameAnalysisResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -11870,62 +9824,74 @@ def update_application_settings_slot_async(resource_group_name, name, app_settin end # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the application settings for the production slot. + # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target + # slot name. See example. + # @param slot [String] Name of the source slot. If a slot is not specified, the + # production slot is used as the source slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [StringDictionary] operation results. # - def list_application_settings_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_application_settings_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def apply_slot_configuration_slot(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) + response = apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers).value! + nil end # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the application settings for the production slot. + # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target + # slot name. See example. + # @param slot [String] Name of the source slot. If a slot is not specified, the + # production slot is used as the source slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_application_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_application_settings_slot_async(resource_group_name, name, slot, custom_headers).value! + def apply_slot_configuration_slot_with_http_info(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) + apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers).value! end # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # - # Gets the application settings of an app. + # Applies the configuration settings from the target slot onto the current + # slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the application settings for the production slot. + # @param slot_swap_entity [CsmSlotEntity] JSON object that contains the target + # slot name. See example. + # @param slot [String] Name of the source slot. If a slot is not specified, the + # production slot is used as the source slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_application_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) + def apply_slot_configuration_slot_async(resource_group_name, name, slot_swap_entity, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'slot_swap_entity is nil' if slot_swap_entity.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -11936,7 +9902,15 @@ def list_application_settings_slot_async(resource_group_name, name, slot, custom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings/list' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::CsmSlotEntity.mapper() + request_content = @client.serialize(request_mapper, slot_swap_entity) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/applySlotConfig' request_url = @base_url || @client.base_url @@ -11944,6 +9918,7 @@ def list_application_settings_slot_async(resource_group_name, name, slot, custom middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } @@ -11959,16 +9934,6 @@ def list_application_settings_slot_async(resource_group_name, name, slot, custom end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -11977,69 +9942,69 @@ def list_application_settings_slot_async(resource_group_name, name, slot, custom end # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param site_auth_settings [SiteAuthSettings] Auth settings associated with - # web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param request [BackupRequest] Backup configuration. You can use the JSON + # response from the POST action as input here. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a backup for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteAuthSettings] operation results. + # @return [BackupItem] operation results. # - def update_auth_settings_slot(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) - response = update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers).value! + def backup_slot(resource_group_name, name, request, slot, custom_headers = nil) + response = backup_slot_async(resource_group_name, name, request, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param site_auth_settings [SiteAuthSettings] Auth settings associated with - # web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param request [BackupRequest] Backup configuration. You can use the JSON + # response from the POST action as input here. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a backup for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_auth_settings_slot_with_http_info(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) - update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers).value! + def backup_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) + backup_slot_async(resource_group_name, name, request, slot, custom_headers).value! end # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # - # Updates the Authentication / Authorization settings associated with web app. + # Creates a backup of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param site_auth_settings [SiteAuthSettings] Auth settings associated with - # web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param request [BackupRequest] Backup configuration. You can use the JSON + # response from the POST action as input here. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a backup for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) + def backup_slot_async(resource_group_name, name, request, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'site_auth_settings is nil' if site_auth_settings.nil? + fail ArgumentError, 'request is nil' if request.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12054,11 +10019,11 @@ def update_auth_settings_slot_async(resource_group_name, name, site_auth_setting request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() - request_content = @client.serialize(request_mapper, site_auth_settings) + request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() + request_content = @client.serialize(request_mapper, request) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backup' request_url = @base_url || @client.base_url @@ -12070,7 +10035,7 @@ def update_auth_settings_slot_async(resource_group_name, name, site_auth_setting headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12086,7 +10051,7 @@ def update_auth_settings_slot_async(resource_group_name, name, site_auth_setting if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() + result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12100,60 +10065,60 @@ def update_auth_settings_slot_async(resource_group_name, name, site_auth_setting end # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the settings for the production slot. + # the API will get backups of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteAuthSettings] operation results. + # @return [Array] operation results. # - def get_auth_settings_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def list_backups_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_backups_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the settings for the production slot. + # the API will get backups of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_auth_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_backups_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_backups_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # - # Gets the Authentication/Authorization settings of an app. + # Gets existing backups of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the settings for the production slot. + # the API will get backups of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_backups_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -12166,7 +10131,7 @@ def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups' request_url = @base_url || @client.base_url @@ -12177,7 +10142,7 @@ def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12193,7 +10158,7 @@ def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() + result_mapper = Azure::ARM::Web::Models::BackupItemCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12207,63 +10172,72 @@ def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers end # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Edited backup configuration. + # @param request [RestoreRequest] A RestoreRequest object that includes Azure + # storage URL and blog name for discovery of backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the backup configuration for the production slot. + # the API will perform discovery for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [BackupRequest] operation results. + # @return [RestoreRequest] operation results. # - def update_backup_configuration_slot(resource_group_name, name, request, slot, custom_headers = nil) - response = update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def discover_restore_slot(resource_group_name, name, request, slot, custom_headers = nil) + response = discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Edited backup configuration. + # @param request [RestoreRequest] A RestoreRequest object that includes Azure + # storage URL and blog name for discovery of backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the backup configuration for the production slot. + # the API will perform discovery for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_backup_configuration_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) - update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers).value! + def discover_restore_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) + discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers).value! end # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # - # Updates the backup configuration of an app. + # Discovers an existing app backup that can be restored from a blob in Azure + # storage. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param request [BackupRequest] Edited backup configuration. + # @param request [RestoreRequest] A RestoreRequest object that includes Azure + # storage URL and blog name for discovery of backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the backup configuration for the production slot. + # the API will perform discovery for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers = nil) + def discover_restore_slot_async(resource_group_name, name, request, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'request is nil' if request.nil? @@ -12281,11 +10255,11 @@ def update_backup_configuration_slot_async(resource_group_name, name, request, s request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() + request_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() request_content = @client.serialize(request_mapper, request) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/discover' request_url = @base_url || @client.base_url @@ -12313,7 +10287,7 @@ def update_backup_configuration_slot_async(resource_group_name, name, request, s if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() + result_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12327,61 +10301,66 @@ def update_backup_configuration_slot_async(resource_group_name, name, request, s end # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the backup configuration for the production slot. + # the API will get a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [BackupItem] operation results. # - def delete_backup_configuration_slot(resource_group_name, name, slot, custom_headers = nil) - response = delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! - nil + def get_backup_status_slot(resource_group_name, name, backup_id, slot, custom_headers = nil) + response = get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! + response.body unless response.nil? end # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the backup configuration for the production slot. + # the API will get a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_backup_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_backup_status_slot_with_http_info(resource_group_name, name, backup_id, slot, custom_headers = nil) + get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! end # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # - # Deletes the backup configuration of an app. + # Gets a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the backup configuration for the production slot. + # the API will get a backup of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_backup_status_slot_async(resource_group_name, name, backup_id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'backup_id is nil' if backup_id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12392,18 +10371,18 @@ def delete_backup_configuration_slot_async(resource_group_name, name, slot, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12415,6 +10394,16 @@ def delete_backup_configuration_slot_async(resource_group_name, name, slot, cust end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -12423,62 +10412,65 @@ def delete_backup_configuration_slot_async(resource_group_name, name, slot, cust end # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the backup configuration for the production slot. + # the API will delete a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [BackupRequest] operation results. # - def get_backup_configuration_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def delete_backup_slot(resource_group_name, name, backup_id, slot, custom_headers = nil) + response = delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! + nil end # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the backup configuration for the production slot. + # the API will delete a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_backup_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def delete_backup_slot_with_http_info(resource_group_name, name, backup_id, slot, custom_headers = nil) + delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers).value! end # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # - # Gets the backup configuration of an app. + # Deletes a backup of an app by its ID. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the backup configuration for the production slot. + # the API will delete a backup of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_backup_slot_async(resource_group_name, name, backup_id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'backup_id is nil' if backup_id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12489,39 +10481,29 @@ def get_backup_configuration_slot_async(resource_group_name, name, slot, custom_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -12530,69 +10512,88 @@ def get_backup_configuration_slot_async(resource_group_name, name, slot, custom_ end # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param connection_strings [ConnectionStringDictionary] Connection strings of - # the app or deployment slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the connection settings for the production slot. + # @param name [String] Name of web app + # @param backup_id [String] Id of backup + # @param request [BackupRequest] Information on backup request + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [ConnectionStringDictionary] operation results. + # @return [BackupItem] operation results. # - def update_connection_strings_slot(resource_group_name, name, connection_strings, slot, custom_headers = nil) - response = update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers).value! + def list_backup_status_secrets_slot(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + response = list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! response.body unless response.nil? end # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param connection_strings [ConnectionStringDictionary] Connection strings of - # the app or deployment slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the connection settings for the production slot. + # @param name [String] Name of web app + # @param backup_id [String] Id of backup + # @param request [BackupRequest] Information on backup request + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_connection_strings_slot_with_http_info(resource_group_name, name, connection_strings, slot, custom_headers = nil) - update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers).value! + def list_backup_status_secrets_slot_with_http_info(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! end # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # - # Replaces the connection strings of an app. + # Gets status of a web app backup that may be in progress, including secrets + # associated with the backup, such as the Azure Storage SAS URL. Also can be + # used to update the SAS URL for the backup if a new URL is passed in the + # request body. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param connection_strings [ConnectionStringDictionary] Connection strings of - # the app or deployment slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the connection settings for the production slot. + # @param name [String] Name of web app + # @param backup_id [String] Id of backup + # @param request [BackupRequest] Information on backup request + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers = nil) + def list_backup_status_secrets_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'connection_strings is nil' if connection_strings.nil? + fail ArgumentError, 'backup_id is nil' if backup_id.nil? + fail ArgumentError, 'request is nil' if request.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12606,24 +10607,24 @@ def update_connection_strings_slot_async(resource_group_name, name, connection_s request_headers['Content-Type'] = 'application/json; charset=utf-8' - # Serialize Request - request_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() - request_content = @client.serialize(request_mapper, connection_strings) + # Serialize Request + request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() + request_content = @client.serialize(request_mapper, request) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/backups/{backupId}/list' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12639,7 +10640,7 @@ def update_connection_strings_slot_async(resource_group_name, name, connection_s if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() + result_mapper = Azure::ARM::Web::Models::BackupItem.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12653,60 +10654,114 @@ def update_connection_strings_slot_async(resource_group_name, name, connection_s end # - # Gets the connection strings of an app. + # Restores a specific backup to another app (or deployment slot, if specified). # - # Gets the connection strings of an app. + # Restores a specific backup to another app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. + # @param request [RestoreRequest] Information on restore request # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the connection settings for the production slot. + # the API will restore a backup of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [ConnectionStringDictionary] operation results. + # @return [RestoreResponse] operation results. # - def list_connection_strings_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers).value! + def restore_slot(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + response = restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the connection strings of an app. + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param backup_id [String] ID of the backup. + # @param request [RestoreRequest] Information on restore request + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will restore a backup of the production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. # - # Gets the connection strings of an app. + # @return [Concurrent::Promise] promise which provides async access to http + # response. + # + def restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers = nil) + # Send request + promise = begin_restore_slot_async(resource_group_name, name, backup_id, request, slot, custom_headers) + + promise = promise.then do |response| + # Defining deserialization method. + deserialize_method = lambda do |parsed_response| + result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() + parsed_response = @client.deserialize(result_mapper, parsed_response) + end + + # Waiting for response. + @client.get_long_running_operation_result(response, deserialize_method) + end + + promise + end + + # + # List the configurations of an app + # + # List the configurations of an app # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the connection settings for the production slot. + # the API will return configuration for the production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [Array] operation results. + # + def list_configurations_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_configurations_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items + end + + # + # List the configurations of an app + # + # List the configurations of an app + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_connection_strings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_configurations_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_configurations_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the connection strings of an app. + # List the configurations of an app # - # Gets the connection strings of an app. + # List the configurations of an app # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the connection settings for the production slot. + # the API will return configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_configurations_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -12719,7 +10774,7 @@ def list_connection_strings_slot_async(resource_group_name, name, slot, custom_h # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config' request_url = @base_url || @client.base_url @@ -12730,7 +10785,7 @@ def list_connection_strings_slot_async(resource_group_name, name, slot, custom_h headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12746,7 +10801,7 @@ def list_connection_strings_slot_async(resource_group_name, name, slot, custom_h if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() + result_mapper = Azure::ARM::Web::Models::SiteConfigResourceCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12760,62 +10815,66 @@ def list_connection_strings_slot_async(resource_group_name, name, slot, custom_h end # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param app_settings [StringDictionary] Application settings of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the logging configuration for the production slot. + # the API will update the application settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteLogsConfig] operation results. + # @return [StringDictionary] operation results. # - def get_diagnostic_logs_configuration_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def update_application_settings_slot(resource_group_name, name, app_settings, slot, custom_headers = nil) + response = update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param app_settings [StringDictionary] Application settings of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the logging configuration for the production slot. + # the API will update the application settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_diagnostic_logs_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def update_application_settings_slot_with_http_info(resource_group_name, name, app_settings, slot, custom_headers = nil) + update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers).value! end # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # - # Gets the logging configuration of an app. + # Replaces the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param app_settings [StringDictionary] Application settings of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the logging configuration for the production slot. + # the API will update the application settings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + def update_application_settings_slot_async(resource_group_name, name, app_settings, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'app_settings is nil' if app_settings.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12826,7 +10885,15 @@ def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + request_content = @client.serialize(request_mapper, app_settings) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings' request_url = @base_url || @client.base_url @@ -12834,10 +10901,11 @@ def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12853,7 +10921,7 @@ def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() + result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12867,69 +10935,62 @@ def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot end # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that - # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the logging configuration for the production slot. + # the API will get the application settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteLogsConfig] operation results. + # @return [StringDictionary] operation results. # - def update_diagnostic_logs_config_slot(resource_group_name, name, site_logs_config, slot, custom_headers = nil) - response = update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers).value! + def list_application_settings_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_application_settings_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that - # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the logging configuration for the production slot. + # the API will get the application settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_diagnostic_logs_config_slot_with_http_info(resource_group_name, name, site_logs_config, slot, custom_headers = nil) - update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers).value! + def list_application_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_application_settings_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # - # Updates the logging configuration of an app. + # Gets the application settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that - # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the logging configuration for the production slot. + # the API will get the application settings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers = nil) + def list_application_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'site_logs_config is nil' if site_logs_config.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -12940,15 +11001,7 @@ def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_log # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() - request_content = @client.serialize(request_mapper, site_logs_config) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/appsettings/list' request_url = @base_url || @client.base_url @@ -12956,11 +11009,10 @@ def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_log middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -12976,7 +11028,7 @@ def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_log if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() + result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -12990,69 +11042,69 @@ def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_log end # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param metadata [StringDictionary] Edited metadata of the app or deployment - # slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the metadata for the production slot. + # @param name [String] Name of web app + # @param site_auth_settings [SiteAuthSettings] Auth settings associated with + # web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [StringDictionary] operation results. + # @return [SiteAuthSettings] operation results. # - def update_metadata_slot(resource_group_name, name, metadata, slot, custom_headers = nil) - response = update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers).value! + def update_auth_settings_slot(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) + response = update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers).value! response.body unless response.nil? end # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param metadata [StringDictionary] Edited metadata of the app or deployment - # slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the metadata for the production slot. + # @param name [String] Name of web app + # @param site_auth_settings [SiteAuthSettings] Auth settings associated with + # web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_metadata_slot_with_http_info(resource_group_name, name, metadata, slot, custom_headers = nil) - update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers).value! + def update_auth_settings_slot_with_http_info(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) + update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers).value! end # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # - # Replaces the metadata of an app. + # Updates the Authentication / Authorization settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param metadata [StringDictionary] Edited metadata of the app or deployment - # slot. See example. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the metadata for the production slot. + # @param name [String] Name of web app + # @param site_auth_settings [SiteAuthSettings] Auth settings associated with + # web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers = nil) + def update_auth_settings_slot_async(resource_group_name, name, site_auth_settings, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'metadata is nil' if metadata.nil? + fail ArgumentError, 'site_auth_settings is nil' if site_auth_settings.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -13067,11 +11119,11 @@ def update_metadata_slot_async(resource_group_name, name, metadata, slot, custom request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() - request_content = @client.serialize(request_mapper, metadata) + request_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() + request_content = @client.serialize(request_mapper, site_auth_settings) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/metadata' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings' request_url = @base_url || @client.base_url @@ -13099,7 +11151,7 @@ def update_metadata_slot_async(resource_group_name, name, metadata, slot, custom if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + result_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13113,60 +11165,60 @@ def update_metadata_slot_async(resource_group_name, name, metadata, slot, custom end # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the metadata for the production slot. + # the API will get the settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [StringDictionary] operation results. + # @return [SiteAuthSettings] operation results. # - def list_metadata_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_auth_settings_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the metadata for the production slot. + # the API will get the settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_metadata_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_auth_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # - # Gets the metadata of an app. + # Gets the Authentication/Authorization settings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the metadata for the production slot. + # the API will get the settings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_metadata_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_auth_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -13179,7 +11231,7 @@ def list_metadata_slot_async(resource_group_name, name, slot, custom_headers = n # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/metadata/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/authsettings/list' request_url = @base_url || @client.base_url @@ -13206,7 +11258,7 @@ def list_metadata_slot_async(resource_group_name, name, slot, custom_headers = n if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + result_mapper = Azure::ARM::Web::Models::SiteAuthSettings.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13220,116 +11272,66 @@ def list_metadata_slot_async(resource_group_name, name, slot, custom_headers = n end # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the publishing credentials for the production slot. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [User] operation results. + # Updates the backup configuration of an app. # - def list_publishing_credentials_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? - end - + # Updates the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param request [BackupRequest] Edited backup configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the publishing credentials for the production slot. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers = nil) - # Send request - promise = begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::User.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Updates the Push settings associated with web app. - # - # Updates the Push settings associated with web app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param push_settings [PushSettings] Push settings associated with web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # the API will update the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PushSettings] operation results. + # @return [BackupRequest] operation results. # - def update_site_push_settings_slot(resource_group_name, name, push_settings, slot, custom_headers = nil) - response = update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers).value! + def update_backup_configuration_slot(resource_group_name, name, request, slot, custom_headers = nil) + response = update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the Push settings associated with web app. + # Updates the backup configuration of an app. # - # Updates the Push settings associated with web app. + # Updates the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param push_settings [PushSettings] Push settings associated with web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param request [BackupRequest] Edited backup configuration. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will update the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_site_push_settings_slot_with_http_info(resource_group_name, name, push_settings, slot, custom_headers = nil) - update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers).value! + def update_backup_configuration_slot_with_http_info(resource_group_name, name, request, slot, custom_headers = nil) + update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers).value! end # - # Updates the Push settings associated with web app. + # Updates the backup configuration of an app. # - # Updates the Push settings associated with web app. + # Updates the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param push_settings [PushSettings] Push settings associated with web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param request [BackupRequest] Edited backup configuration. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will update the backup configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers = nil) + def update_backup_configuration_slot_async(resource_group_name, name, request, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'push_settings is nil' if push_settings.nil? + fail ArgumentError, 'request is nil' if request.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -13344,11 +11346,11 @@ def update_site_push_settings_slot_async(resource_group_name, name, push_setting request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::PushSettings.mapper() - request_content = @client.serialize(request_mapper, push_settings) + request_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() + request_content = @client.serialize(request_mapper, request) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/pushsettings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup' request_url = @base_url || @client.base_url @@ -13376,7 +11378,7 @@ def update_site_push_settings_slot_async(resource_group_name, name, push_setting if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PushSettings.mapper() + result_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13390,60 +11392,59 @@ def update_site_push_settings_slot_async(resource_group_name, name, push_setting end # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PushSettings] operation results. # - def list_site_push_settings_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def delete_backup_configuration_slot(resource_group_name, name, slot, custom_headers = nil) + response = delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + nil end # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_site_push_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers).value! + def delete_backup_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # - # Gets the Push settings associated with web app. + # Deletes the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the backup configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -13456,7 +11457,7 @@ def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_h # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/pushsettings/list' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup' request_url = @base_url || @client.base_url @@ -13467,7 +11468,7 @@ def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_h headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response @@ -13479,16 +11480,6 @@ def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_h end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PushSettings.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -13497,66 +11488,60 @@ def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_h end # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteConfigResource] operation results. + # @return [BackupRequest] operation results. # - def get_configuration_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_backup_configuration_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the backup configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_backup_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # - # Gets the configuration of an app, such as platform version and bitness, - # default documents, virtual applications, Always On, etc. + # Gets the backup configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the backup configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_backup_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -13569,7 +11554,7 @@ def get_configuration_slot_async(resource_group_name, name, slot, custom_headers # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/backup/list' request_url = @base_url || @client.base_url @@ -13580,7 +11565,7 @@ def get_configuration_slot_async(resource_group_name, name, slot, custom_headers headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -13596,7 +11581,7 @@ def get_configuration_slot_async(resource_group_name, name, slot, custom_headers if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result_mapper = Azure::ARM::Web::Models::BackupRequest.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13610,69 +11595,69 @@ def get_configuration_slot_async(resource_group_name, name, slot, custom_headers end # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. + # @param connection_strings [ConnectionStringDictionary] Connection strings of + # the app or deployment slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will update the connection settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteConfigResource] operation results. + # @return [ConnectionStringDictionary] operation results. # - def create_or_update_configuration_slot(resource_group_name, name, site_config, slot, custom_headers = nil) - response = create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! + def update_connection_strings_slot(resource_group_name, name, connection_strings, slot, custom_headers = nil) + response = update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. + # @param connection_strings [ConnectionStringDictionary] Connection strings of + # the app or deployment slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will update the connection settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_configuration_slot_with_http_info(resource_group_name, name, site_config, slot, custom_headers = nil) - create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! + def update_connection_strings_slot_with_http_info(resource_group_name, name, connection_strings, slot, custom_headers = nil) + update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers).value! end # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # - # Updates the configuration of an app. + # Replaces the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. + # @param connection_strings [ConnectionStringDictionary] Connection strings of + # the app or deployment slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will update the connection settings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers = nil) + def update_connection_strings_slot_async(resource_group_name, name, connection_strings, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'site_config is nil' if site_config.nil? + fail ArgumentError, 'connection_strings is nil' if connection_strings.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -13687,11 +11672,11 @@ def create_or_update_configuration_slot_async(resource_group_name, name, site_co request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() - request_content = @client.serialize(request_mapper, site_config) + request_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() + request_content = @client.serialize(request_mapper, connection_strings) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings' request_url = @base_url || @client.base_url @@ -13719,7 +11704,7 @@ def create_or_update_configuration_slot_async(resource_group_name, name, site_co if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13733,69 +11718,62 @@ def create_or_update_configuration_slot_async(resource_group_name, name, site_co end # - # Updates the configuration of an app. + # Gets the connection strings of an app. # - # Updates the configuration of an app. + # Gets the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will get the connection settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteConfigResource] operation results. + # @return [ConnectionStringDictionary] operation results. # - def update_configuration_slot(resource_group_name, name, site_config, slot, custom_headers = nil) - response = update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! + def list_connection_strings_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Updates the configuration of an app. + # Gets the connection strings of an app. # - # Updates the configuration of an app. + # Gets the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will get the connection settings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_configuration_slot_with_http_info(resource_group_name, name, site_config, slot, custom_headers = nil) - update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! + def list_connection_strings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Updates the configuration of an app. + # Gets the connection strings of an app. # - # Updates the configuration of an app. + # Gets the connection strings of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param site_config [SiteConfigResource] JSON representation of a SiteConfig - # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update configuration for the production slot. + # the API will get the connection settings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers = nil) + def list_connection_strings_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'site_config is nil' if site_config.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -13806,15 +11784,7 @@ def update_configuration_slot_async(resource_group_name, name, site_config, slot # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() - request_content = @client.serialize(request_mapper, site_config) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/connectionstrings/list' request_url = @base_url || @client.base_url @@ -13822,11 +11792,10 @@ def update_configuration_slot_async(resource_group_name, name, site_config, slot middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -13842,7 +11811,7 @@ def update_configuration_slot_async(resource_group_name, name, site_config, slot if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result_mapper = Azure::ARM::Web::Models::ConnectionStringDictionary.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13856,66 +11825,60 @@ def update_configuration_slot_async(resource_group_name, name, site_config, slot end # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the logging configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [SiteLogsConfig] operation results. # - def list_configuration_snapshot_info_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_diagnostic_logs_configuration_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the logging configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_configuration_snapshot_info_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_diagnostic_logs_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # - # Gets a list of web app configuration snapshots identifiers. Each element of - # the list contains a timestamp and the ID of the snapshot. + # Gets the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will get the logging configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_diagnostic_logs_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -13928,7 +11891,7 @@ def list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs' request_url = @base_url || @client.base_url @@ -13955,21 +11918,7 @@ def list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'Sequence', - element: { - required: false, - serialized_name: 'SiteConfigurationSnapshotInfoElementType', - type: { - name: 'Composite', - class_name: 'SiteConfigurationSnapshotInfo' - } - } - } - } + result_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -13983,66 +11932,69 @@ def list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, end # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that + # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the logging configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteConfigResource] operation results. + # @return [SiteLogsConfig] operation results. # - def get_configuration_snapshot_slot(resource_group_name, name, snapshot_id, slot, custom_headers = nil) - response = get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! + def update_diagnostic_logs_config_slot(resource_group_name, name, site_logs_config, slot, custom_headers = nil) + response = update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers).value! response.body unless response.nil? end # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that + # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the logging configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_configuration_snapshot_slot_with_http_info(resource_group_name, name, snapshot_id, slot, custom_headers = nil) - get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! + def update_diagnostic_logs_config_slot_with_http_info(resource_group_name, name, site_logs_config, slot, custom_headers = nil) + update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers).value! end # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # - # Gets a snapshot of the configuration of an app at a previous point in time. + # Updates the logging configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param site_logs_config [SiteLogsConfig] A SiteLogsConfig JSON object that + # contains the logging configuration to change in the "properties" property. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the logging configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + def update_diagnostic_logs_config_slot_async(resource_group_name, name, site_logs_config, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'snapshot_id is nil' if snapshot_id.nil? + fail ArgumentError, 'site_logs_config is nil' if site_logs_config.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14053,18 +12005,27 @@ def get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() + request_content = @client.serialize(request_mapper, site_logs_config) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/logs' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'snapshotId' => snapshot_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14080,7 +12041,7 @@ def get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result_mapper = Azure::ARM::Web::Models::SiteLogsConfig.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14094,65 +12055,69 @@ def get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id end # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param metadata [StringDictionary] Edited metadata of the app or deployment + # slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the metadata for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [StringDictionary] operation results. # - def recover_site_configuration_snapshot_slot(resource_group_name, name, snapshot_id, slot, custom_headers = nil) - response = recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! - nil + def update_metadata_slot(resource_group_name, name, metadata, slot, custom_headers = nil) + response = update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers).value! + response.body unless response.nil? end # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param metadata [StringDictionary] Edited metadata of the app or deployment + # slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the metadata for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def recover_site_configuration_snapshot_slot_with_http_info(resource_group_name, name, snapshot_id, slot, custom_headers = nil) - recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! + def update_metadata_slot_with_http_info(resource_group_name, name, metadata, slot, custom_headers = nil) + update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers).value! end # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # - # Reverts the configuration of an app to a previous snapshot. + # Replaces the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param snapshot_id [String] The ID of the snapshot to read. + # @param metadata [StringDictionary] Edited metadata of the app or deployment + # slot. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will return configuration for the production slot. + # the API will update the metadata for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + def update_metadata_slot_async(resource_group_name, name, metadata, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'snapshot_id is nil' if snapshot_id.nil? + fail ArgumentError, 'metadata is nil' if metadata.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14160,32 +12125,51 @@ def recover_site_configuration_snapshot_slot_async(resource_group_name, name, sn request_headers = {} - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}/recover' + # Set Headers + request_headers['x-ms-client-request-id'] = SecureRandom.uuid + request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + request_content = @client.serialize(request_mapper, metadata) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/metadata' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'snapshotId' => snapshot_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -14194,66 +12178,60 @@ def recover_site_configuration_snapshot_slot_async(resource_group_name, name, sn end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. + # the API will get the metadata for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [StringDictionary] operation results. # - def list_deployments_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_deployments_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def list_metadata_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. + # the API will get the metadata for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_deployments_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_deployments_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_metadata_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets the metadata of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. + # the API will get the metadata for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_deployments_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_metadata_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -14266,7 +12244,7 @@ def list_deployments_slot_async(resource_group_name, name, slot, custom_headers # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/metadata/list' request_url = @base_url || @client.base_url @@ -14277,7 +12255,7 @@ def list_deployments_slot_async(resource_group_name, name, slot, custom_headers headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14293,7 +12271,7 @@ def list_deployments_slot_async(resource_group_name, name, slot, custom_headers if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() + result_mapper = Azure::ARM::Web::Models::StringDictionary.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14307,72 +12285,116 @@ def list_deployments_slot_async(resource_group_name, name, slot, custom_headers end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets the Git/FTP publishing credentials of an app. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. + # the API will get the publishing credentials for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [User] operation results. # - def get_deployment_slot(resource_group_name, name, id, slot, custom_headers = nil) - response = get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! + def list_publishing_credentials_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end - # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. - # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. + # the API will get the publishing credentials for the production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [Concurrent::Promise] promise which provides async access to http + # response. + # + def list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers = nil) + # Send request + promise = begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers) + + promise = promise.then do |response| + # Defining deserialization method. + deserialize_method = lambda do |parsed_response| + result_mapper = Azure::ARM::Web::Models::User.mapper() + parsed_response = @client.deserialize(result_mapper, parsed_response) + end + + # Waiting for response. + @client.get_long_running_operation_result(response, deserialize_method) + end + + promise + end + + # + # Updates the Push settings associated with web app. + # + # Updates the Push settings associated with web app. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of web app + # @param push_settings [PushSettings] Push settings associated with web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [PushSettings] operation results. + # + def update_site_push_settings_slot(resource_group_name, name, push_settings, slot, custom_headers = nil) + response = update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers).value! + response.body unless response.nil? + end + + # + # Updates the Push settings associated with web app. + # + # Updates the Push settings associated with web app. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of web app + # @param push_settings [PushSettings] Push settings associated with web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_deployment_slot_with_http_info(resource_group_name, name, id, slot, custom_headers = nil) - get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! + def update_site_push_settings_slot_with_http_info(resource_group_name, name, push_settings, slot, custom_headers = nil) + update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers).value! end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Updates the Push settings associated with web app. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Updates the Push settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param id [String] Deployment ID. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. + # @param name [String] Name of web app + # @param push_settings [PushSettings] Push settings associated with web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers = nil) + def update_site_push_settings_slot_async(resource_group_name, name, push_settings, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'push_settings is nil' if push_settings.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14383,18 +12405,27 @@ def get_deployment_slot_async(resource_group_name, name, id, slot, custom_header # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::PushSettings.mapper() + request_content = @client.serialize(request_mapper, push_settings) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/pushsettings' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14410,7 +12441,7 @@ def get_deployment_slot_async(resource_group_name, name, id, slot, custom_header if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::PushSettings.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14424,77 +12455,63 @@ def get_deployment_slot_async(resource_group_name, name, id, slot, custom_header end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param deployment [Deployment] Deployment details. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [PushSettings] operation results. # - def create_deployment_slot(resource_group_name, name, id, slot, deployment, custom_headers = nil) - response = create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers).value! + def list_site_push_settings_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param deployment [Deployment] Deployment details. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_deployment_slot_with_http_info(resource_group_name, name, id, slot, deployment, custom_headers = nil) - create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers).value! + def list_site_push_settings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Gets the Push settings associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param deployment [Deployment] Deployment details. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers = nil) + def list_site_push_settings_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14504,27 +12521,18 @@ def create_deployment_slot_async(resource_group_name, name, id, slot, deployment # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::Deployment.mapper() - request_content = @client.serialize(request_mapper, deployment) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/pushsettings/list' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14540,7 +12548,7 @@ def create_deployment_slot_async(resource_group_name, name, id, slot, deployment if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::PushSettings.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14554,71 +12562,68 @@ def create_deployment_slot_async(resource_group_name, name, id, slot, deployment end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [SiteConfigResource] operation results. # - def delete_deployment_slot(resource_group_name, name, id, slot, custom_headers = nil) - response = delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! - nil + def get_configuration_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_deployment_slot_with_http_info(resource_group_name, name, id, slot, custom_headers = nil) - delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! + def get_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Gets the configuration of an app, such as platform version and bitness, + # default documents, virtual applications, Always On, etc. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. + # the API will return configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers = nil) + def get_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14629,29 +12634,39 @@ def delete_deployment_slot_async(resource_group_name, name, id, slot, custom_hea # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -14660,62 +12675,69 @@ def delete_deployment_slot_async(resource_group_name, name, id, slot, custom_hea end # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [SiteConfigResource] operation results. # - def list_domain_ownership_identifiers_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_domain_ownership_identifiers_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def create_or_update_configuration_slot(resource_group_name, name, site_config, slot, custom_headers = nil) + response = create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! + response.body unless response.nil? end # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_domain_ownership_identifiers_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot, custom_headers).value! + def create_or_update_configuration_slot_with_http_info(resource_group_name, name, site_config, slot, custom_headers = nil) + create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! end # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # - # Lists ownership identifiers for domain associated with web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot, custom_headers = nil) + def create_or_update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'site_config is nil' if site_config.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14726,7 +12748,15 @@ def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + request_content = @client.serialize(request_mapper, site_config) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' request_url = @base_url || @client.base_url @@ -14734,10 +12764,11 @@ def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14753,7 +12784,7 @@ def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::IdentifierCollection.mapper() + result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14767,69 +12798,69 @@ def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot end # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Identifier] operation results. + # @return [SiteConfigResource] operation results. # - def get_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) - response = get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! + def update_configuration_slot(resource_group_name, name, site_config, slot, custom_headers = nil) + response = update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! response.body unless response.nil? end # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) - get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! + def update_configuration_slot_with_http_info(resource_group_name, name, site_config, slot, custom_headers = nil) + update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers).value! end # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # - # Get domain ownership identifier for web app. + # Updates the configuration of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param site_config [SiteConfigResource] JSON representation of a SiteConfig + # object. See example. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will update configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + def update_configuration_slot_async(resource_group_name, name, site_config, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? + fail ArgumentError, 'site_config is nil' if site_config.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14840,18 +12871,27 @@ def get_domain_ownership_identifier_slot_async(resource_group_name, name, domain # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + request_content = @client.serialize(request_mapper, site_config) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response @@ -14867,7 +12907,7 @@ def get_domain_ownership_identifier_slot_async(resource_group_name, name, domain if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Identifier.mapper() + result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -14881,82 +12921,68 @@ def get_domain_ownership_identifier_slot_async(resource_group_name, name, domain end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Identifier] operation results. + # @return [Array] operation results. # - def create_or_update_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) - response = create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! + def list_configuration_snapshot_info_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) - create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! + def list_configuration_snapshot_info_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Gets a list of web app configuration snapshots identifiers. Each element of + # the list contains a timestamp and the ID of the snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + def list_configuration_snapshot_info_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? - fail ArgumentError, 'domain_ownership_identifier is nil' if domain_ownership_identifier.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -14967,27 +12993,18 @@ def create_or_update_domain_ownership_identifier_slot_async(resource_group_name, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::Identifier.mapper() - request_content = @client.serialize(request_mapper, domain_ownership_identifier) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -15003,7 +13020,21 @@ def create_or_update_domain_ownership_identifier_slot_async(resource_group_name, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Identifier.mapper() + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'Sequence', + element: { + required: false, + serialized_name: 'SiteConfigurationSnapshotInfoElementType', + type: { + name: 'Composite', + class_name: 'SiteConfigurationSnapshotInfo' + } + } + } + } result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15017,68 +13048,66 @@ def create_or_update_domain_ownership_identifier_slot_async(resource_group_name, end # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [SiteConfigResource] operation results. # - def delete_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) - response = delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! - nil + def get_configuration_snapshot_slot(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + response = get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! + response.body unless response.nil? end # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) - delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! + def get_configuration_snapshot_slot_with_http_info(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! end # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # - # Deletes a domain ownership identifier for a web app. + # Gets a snapshot of the configuration of an app at a previous point in time. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + def get_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? + fail ArgumentError, 'snapshot_id is nil' if snapshot_id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15089,29 +13118,39 @@ def delete_domain_ownership_identifier_slot_async(resource_group_name, name, dom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'snapshotId' => snapshot_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::SiteConfigResource.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -15120,82 +13159,65 @@ def delete_domain_ownership_identifier_slot_async(resource_group_name, name, dom end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Identifier] operation results. # - def update_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) - response = update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! - response.body unless response.nil? + def recover_site_configuration_snapshot_slot(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + response = recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! + nil end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) - update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! + def recover_site_configuration_snapshot_slot_with_http_info(resource_group_name, name, snapshot_id, slot, custom_headers = nil) + recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers).value! end # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # - # Creates a domain ownership identifier for web app, or updates an existing - # ownership identifier. + # Reverts the configuration of an app to a previous snapshot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param domain_ownership_identifier_name [String] Name of domain ownership - # identifier. - # @param domain_ownership_identifier [Identifier] A JSON representation of the - # domain ownership properties. + # @param snapshot_id [String] The ID of the snapshot to read. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. + # the API will return configuration for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + def recover_site_configuration_snapshot_slot_async(resource_group_name, name, snapshot_id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? - fail ArgumentError, 'domain_ownership_identifier is nil' if domain_ownership_identifier.nil? + fail ArgumentError, 'snapshot_id is nil' if snapshot_id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15206,48 +13228,29 @@ def update_domain_ownership_identifier_slot_async(resource_group_name, name, dom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::Identifier.mapper() - request_content = @client.serialize(request_mapper, domain_ownership_identifier) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/web/snapshots/{snapshotId}/recover' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'snapshotId' => snapshot_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Identifier.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -15256,60 +13259,66 @@ def update_domain_ownership_identifier_slot_async(resource_group_name, name, dom end # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [Array] operation results. # - def get_msdeploy_status_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def list_deployments_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_deployments_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_msdeploy_status_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_deployments_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_deployments_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Invoke the MSDeploy web app extension as pass-through API + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_deployments_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -15322,7 +13331,7 @@ def get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_heade # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments' request_url = @base_url || @client.base_url @@ -15349,7 +13358,7 @@ def get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_heade if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15363,114 +13372,72 @@ def get_msdeploy_status_slot_async(resource_group_name, name, slot, custom_heade end # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MSDeployStatus] operation results. - # - def create_msdeploy_operation_slot(resource_group_name, name, slot, msdeploy, custom_headers = nil) - response = create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers).value! - response.body unless response.nil? - end - - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers = nil) - # Send request - promise = begin_create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets a deployment for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployLog] operation results. + # @return [Deployment] operation results. # - def get_msdeploy_log_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_deployment_slot(resource_group_name, name, id, slot, custom_headers = nil) + response = get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets a deployment for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_msdeploy_log_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_deployment_slot_with_http_info(resource_group_name, name, id, slot, custom_headers = nil) + get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets a deployment for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_deployment_slot_async(resource_group_name, name, id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15481,13 +13448,13 @@ def get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy/log' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -15508,7 +13475,7 @@ def get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployLog.mapper() + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15522,63 +13489,77 @@ def get_msdeploy_log_slot_async(resource_group_name, name, slot, custom_headers end # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API creates a deployment for the production slot. + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [String] operation results. + # @return [Deployment] operation results. # - def get_functions_admin_token_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_functions_admin_token_slot_async(resource_group_name, name, slot, custom_headers).value! + def create_deployment_slot(resource_group_name, name, id, slot, deployment, custom_headers = nil) + response = create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers).value! response.body unless response.nil? end # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API creates a deployment for the production slot. + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_functions_admin_token_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_functions_admin_token_slot_async(resource_group_name, name, slot, custom_headers).value! + def create_deployment_slot_with_http_info(resource_group_name, name, id, slot, deployment, custom_headers = nil) + create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers).value! end # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Fetch a short lived token that can be exchanged for a master key. + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API creates a deployment for the production slot. + # @param deployment [Deployment] Deployment details. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_functions_admin_token_slot_async(resource_group_name, name, slot, custom_headers = nil) + def create_deployment_slot_async(resource_group_name, name, id, slot, deployment, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15588,18 +13569,27 @@ def get_functions_admin_token_slot_async(resource_group_name, name, slot, custom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/functions/admin/token' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::Deployment.mapper() + request_content = @client.serialize(request_mapper, deployment) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -15615,13 +13605,7 @@ def get_functions_admin_token_slot_async(resource_group_name, name, slot, custom if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15635,62 +13619,71 @@ def get_functions_admin_token_slot_async(resource_group_name, name, slot, custom end # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API deletes a deployment for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. # - def list_host_name_bindings_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_host_name_bindings_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def delete_deployment_slot(resource_group_name, name, id, slot, custom_headers = nil) + response = delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! + nil end # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API deletes a deployment for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_host_name_bindings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_headers).value! + def delete_deployment_slot_with_http_info(resource_group_name, name, id, slot, custom_headers = nil) + delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers).value! end # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Get hostname bindings for an app or a deployment slot. + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API deletes a deployment for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_deployment_slot_async(resource_group_name, name, id, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15701,39 +13694,29 @@ def list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_h # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBindingCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -15742,67 +13725,63 @@ def list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_h end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HostNameBinding] operation results. + # @return [Array] operation results. # - def get_host_name_binding_slot(resource_group_name, name, slot, host_name, custom_headers = nil) - response = get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! - response.body unless response.nil? + def list_domain_ownership_identifiers_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_domain_ownership_identifiers_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_host_name_binding_slot_with_http_info(resource_group_name, name, slot, host_name, custom_headers = nil) - get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! + def list_domain_ownership_identifiers_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # - # Get the named hostname binding for an app (or deployment slot, if specified). + # Lists ownership identifiers for domain associated with web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. + # the API will delete the binding for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers = nil) + def list_domain_ownership_identifiers_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15812,13 +13791,13 @@ def get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -15839,7 +13818,7 @@ def get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + result_mapper = Azure::ARM::Web::Models::IdentifierCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15853,73 +13832,69 @@ def get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, end # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HostNameBinding] operation results. + # @return [Identifier] operation results. # - def create_or_update_host_name_binding_slot(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) - response = create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers).value! + def get_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + response = get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! response.body unless response.nil? end # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_host_name_binding_slot_with_http_info(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) - create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers).value! + def get_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! end # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # - # Creates a hostname binding for an app. + # Get domain ownership identifier for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param host_name [String] Hostname in the hostname binding. - # @param host_name_binding [HostNameBinding] Binding details. This is the JSON - # representation of a HostNameBinding object. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will delete the binding for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) + def get_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? - fail ArgumentError, 'host_name_binding is nil' if host_name_binding.nil? + fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -15928,29 +13903,20 @@ def create_or_update_host_name_binding_slot_async(resource_group_name, name, hos request_headers = {} # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() - request_content = @client.serialize(request_mapper, host_name_binding) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' + request_headers['x-ms-client-request-id'] = SecureRandom.uuid + request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -15966,7 +13932,7 @@ def create_or_update_host_name_binding_slot_async(resource_group_name, name, hos if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + result_mapper = Azure::ARM::Web::Models::Identifier.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -15980,66 +13946,83 @@ def create_or_update_host_name_binding_slot_async(resource_group_name, name, hos end # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, # the API will delete the binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [Identifier] operation results. # - def delete_host_name_binding_slot(resource_group_name, name, slot, host_name, custom_headers = nil) - response = delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! - nil + def create_or_update_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + response = create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! + response.body unless response.nil? end # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, # the API will delete the binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_host_name_binding_slot_with_http_info(resource_group_name, name, slot, host_name, custom_headers = nil) - delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! + def create_or_update_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! end # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Deletes a hostname binding for an app. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. # @param slot [String] Name of the deployment slot. If a slot is not specified, # the API will delete the binding for the production slot. - # @param host_name [String] Hostname in the hostname binding. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers = nil) + def create_or_update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? + fail ArgumentError, 'domain_ownership_identifier is nil' if domain_ownership_identifier.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16049,29 +14032,48 @@ def delete_host_name_binding_slot_async(resource_group_name, name, slot, host_na # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::Identifier.mapper() + request_content = @client.serialize(request_mapper, domain_ownership_identifier) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::Identifier.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -16080,67 +14082,68 @@ def delete_host_name_binding_slot_async(resource_group_name, name, slot, host_na end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. # - def get_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - response = get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! - response.body unless response.nil? + def delete_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + response = delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! + nil end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! + def delete_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) + delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers).value! end # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # - # Retrieves a specific Service Bus Hybrid Connection used by this Web App. + # Deletes a domain ownership identifier for a web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + def delete_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16151,39 +14154,29 @@ def get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -16192,74 +14185,82 @@ def get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. + # @return [Identifier] operation results. # - def create_or_update_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) - response = create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! + def update_domain_ownership_identifier_slot(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + response = update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! response.body unless response.nil? end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) - create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! + def update_domain_ownership_identifier_slot_with_http_info(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) + update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers).value! end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # - # Creates a new Hybrid Connection using a Service Bus relay. + # Creates a domain ownership identifier for web app, or updates an existing + # ownership identifier. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param domain_ownership_identifier_name [String] Name of domain ownership + # identifier. + # @param domain_ownership_identifier [Identifier] A JSON representation of the + # domain ownership properties. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + def update_domain_ownership_identifier_slot_async(resource_group_name, name, domain_ownership_identifier_name, domain_ownership_identifier, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? + fail ArgumentError, 'domain_ownership_identifier_name is nil' if domain_ownership_identifier_name.nil? + fail ArgumentError, 'domain_ownership_identifier is nil' if domain_ownership_identifier.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16274,23 +14275,23 @@ def create_or_update_hybrid_connection_slot_async(resource_group_name, name, nam request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) + request_mapper = Azure::ARM::Web::Models::Identifier.mapper() + request_content = @client.serialize(request_mapper, domain_ownership_identifier) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/domainOwnershipIdentifiers/{domainOwnershipIdentifierName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'domainOwnershipIdentifierName' => domain_ownership_identifier_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response @@ -16306,7 +14307,7 @@ def create_or_update_hybrid_connection_slot_async(resource_group_name, name, nam if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result_mapper = Azure::ARM::Web::Models::Identifier.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -16320,66 +14321,62 @@ def create_or_update_hybrid_connection_slot_async(resource_group_name, name, nam end # - # Removes a Hybrid Connection from this site. - # - # Removes a Hybrid Connection from this site. + # Get hostname bindings for an app or a deployment slot. # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # Get hostname bindings for an app or a deployment slot. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets hostname bindings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [Array] operation results. # - def delete_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - response = delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! - nil + def list_host_name_bindings_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_host_name_bindings_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Removes a Hybrid Connection from this site. + # Get hostname bindings for an app or a deployment slot. # - # Removes a Hybrid Connection from this site. + # Get hostname bindings for an app or a deployment slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets hostname bindings for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! + def list_host_name_bindings_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Removes a Hybrid Connection from this site. + # Get hostname bindings for an app or a deployment slot. # - # Removes a Hybrid Connection from this site. + # Get hostname bindings for an app or a deployment slot. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets hostname bindings for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + def list_host_name_bindings_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16390,29 +14387,39 @@ def delete_hybrid_connection_slot_async(resource_group_name, name, namespace_nam # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::HostNameBindingCollection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -16421,75 +14428,67 @@ def delete_hybrid_connection_slot_async(resource_group_name, name, namespace_nam end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API the named binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. + # @return [HostNameBinding] operation results. # - def update_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) - response = update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! + def get_host_name_binding_slot(resource_group_name, name, slot, host_name, custom_headers = nil) + response = get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! response.body unless response.nil? end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API the named binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) - update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! + def get_host_name_binding_slot_with_http_info(resource_group_name, name, slot, host_name, custom_headers = nil) + get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! end # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # - # Creates a new Hybrid Connection using a Service Bus relay. + # Get the named hostname binding for an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param connection_envelope [HybridConnection] The details of the hybrid - # connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API the named binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + def get_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16499,27 +14498,18 @@ def update_hybrid_connection_slot_async(resource_group_name, name, namespace_nam # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -16535,7 +14525,7 @@ def update_hybrid_connection_slot_async(resource_group_name, name, namespace_nam if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -16549,67 +14539,73 @@ def update_hybrid_connection_slot_async(resource_group_name, name, namespace_nam end # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnectionKey] operation results. + # @return [HostNameBinding] operation results. # - def list_hybrid_connection_keys_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - response = list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! + def create_or_update_host_name_binding_slot(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) + response = create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a binding for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_hybrid_connection_keys_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) - list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! + def create_or_update_host_name_binding_slot_with_http_info(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) + create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers).value! end # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # - # Gets the send key name and value for a Hybrid Connection. + # Creates a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param namespace_name [String] The namespace for this hybrid connection - # @param relay_name [String] The relay name for this hybrid connection - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param host_name [String] Hostname in the hostname binding. + # @param host_name_binding [HostNameBinding] Binding details. This is the JSON + # representation of a HostNameBinding object. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create a binding for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + def create_or_update_host_name_binding_slot_async(resource_group_name, name, host_name, host_name_binding, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? - fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? + fail ArgumentError, 'host_name_binding is nil' if host_name_binding.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16620,18 +14616,27 @@ def list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}/listKeys' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() + request_content = @client.serialize(request_mapper, host_name_binding) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'hostName' => host_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -16647,7 +14652,7 @@ def list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_ if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnectionKey.mapper() + result_mapper = Azure::ARM::Web::Models::HostNameBinding.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -16661,60 +14666,66 @@ def list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_ end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [HybridConnection] operation results. # - def list_hybrid_connections_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def delete_host_name_binding_slot(resource_group_name, name, slot, host_name, custom_headers = nil) + response = delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! + nil end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_hybrid_connections_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers).value! + def delete_host_name_binding_slot_with_http_info(resource_group_name, name, slot, host_name, custom_headers = nil) + delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers).value! end # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # - # Retrieves all Service Bus Hybrid Connections used by this Web App. + # Deletes a hostname binding for an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app - # @param slot [String] The name of the slot for the web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will delete the binding for the production slot. + # @param host_name [String] Hostname in the hostname binding. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_host_name_binding_slot_async(resource_group_name, name, slot, host_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'host_name is nil' if host_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16724,39 +14735,29 @@ def list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_h # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionRelays' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hostNameBindings/{hostName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'hostName' => host_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -16765,68 +14766,67 @@ def list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_h end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get hybrid connections for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. + # @return [HybridConnection] operation results. # - def list_relay_service_connections_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + response = get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get hybrid connections for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_relay_service_connections_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! end # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # - # Gets hybrid connections configured for an app (or deployment slot, if - # specified). + # Retrieves a specific Service Bus Hybrid Connection used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get hybrid connections for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16837,13 +14837,13 @@ def list_relay_service_connections_slot_async(resource_group_name, name, slot, c # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -16864,7 +14864,7 @@ def list_relay_service_connections_slot_async(resource_group_name, name, slot, c if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -16878,66 +14878,74 @@ def list_relay_service_connections_slot_async(resource_group_name, name, slot, c end # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. + # @return [HybridConnection] operation results. # - def get_relay_service_connection_slot(resource_group_name, name, entity_name, slot, custom_headers = nil) - response = get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! + def create_or_update_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + response = create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! response.body unless response.nil? end # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, slot, custom_headers = nil) - get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! + def create_or_update_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! end # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Gets a hybrid connection configuration by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers = nil) + def create_or_update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -16948,18 +14956,27 @@ def get_relay_service_connection_slot_async(resource_group_name, name, entity_na # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -16975,7 +14992,7 @@ def get_relay_service_connection_slot_async(resource_group_name, name, entity_na if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -16989,79 +15006,66 @@ def get_relay_service_connection_slot_async(resource_group_name, name, entity_na end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. # - def create_or_update_relay_service_connection_slot(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) - response = create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! - response.body unless response.nil? + def delete_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + response = delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! + nil end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) - create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! + def delete_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Removes a Hybrid Connection from this site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + def delete_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17072,48 +15076,29 @@ def create_or_update_relay_service_connection_slot_async(resource_group_name, na # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -17122,65 +15107,74 @@ def create_or_update_relay_service_connection_slot_async(resource_group_name, na end # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [HybridConnection] operation results. # - def delete_relay_service_connection_slot(resource_group_name, name, entity_name, slot, custom_headers = nil) - response = delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! - nil + def update_hybrid_connection_slot(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + response = update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! + response.body unless response.nil? end # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, slot, custom_headers = nil) - delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! + def update_hybrid_connection_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) + update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers).value! end # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # - # Deletes a relay service connection by its name. + # Creates a new Hybrid Connection using a Service Bus relay. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param connection_envelope [HybridConnection] The details of the hybrid + # connection + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers = nil) + def update_hybrid_connection_slot_async(resource_group_name, name, namespace_name, relay_name, connection_envelope, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17191,29 +15185,48 @@ def delete_relay_service_connection_slot_async(resource_group_name, name, entity # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -17222,79 +15235,67 @@ def delete_relay_service_connection_slot_async(resource_group_name, name, entity end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [RelayServiceConnectionEntity] operation results. + # @return [HybridConnectionKey] operation results. # - def update_relay_service_connection_slot(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) - response = update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! + def list_hybrid_connection_keys_slot(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + response = list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! response.body unless response.nil? end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def update_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) - update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! + def list_hybrid_connection_keys_slot_with_http_info(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) + list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers).value! end # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # - # Creates a new hybrid connection configuration (PUT), or updates an existing - # one (PATCH). + # Gets the send key name and value for a Hybrid Connection. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param entity_name [String] Name of the hybrid connection configuration. - # @param connection_envelope [RelayServiceConnectionEntity] Details of the - # hybrid connection configuration. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create or update a hybrid connection for the production slot. + # @param name [String] The name of the web app + # @param namespace_name [String] The namespace for this hybrid connection + # @param relay_name [String] The relay name for this hybrid connection + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + def list_hybrid_connection_keys_slot_async(resource_group_name, name, namespace_name, relay_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'entity_name is nil' if entity_name.nil? - fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? + fail ArgumentError, 'namespace_name is nil' if namespace_name.nil? + fail ArgumentError, 'relay_name is nil' if relay_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17305,27 +15306,18 @@ def update_relay_service_connection_slot_async(resource_group_name, name, entity # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() - request_content = @client.serialize(request_mapper, connection_envelope) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionNamespaces/{namespaceName}/relays/{relayName}/listKeys' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'namespaceName' => namespace_name,'relayName' => relay_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:patch, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -17341,7 +15333,7 @@ def update_relay_service_connection_slot_async(resource_group_name, name, entity if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnectionKey.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -17355,60 +15347,57 @@ def update_relay_service_connection_slot_async(resource_group_name, name, entity end # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets the production slot instances. + # @param name [String] The name of the web app + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [HybridConnection] operation results. # - def list_instance_identifiers_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_instance_identifiers_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def list_hybrid_connections_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets the production slot instances. + # @param name [String] The name of the web app + # @param slot [String] The name of the slot for the web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_instance_identifiers_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_instance_identifiers_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_hybrid_connections_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # - # Gets all scale-out instances of an app. + # Retrieves all Service Bus Hybrid Connections used by this Web App. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets the production slot instances. + # @param name [String] The name of the web app + # @param slot [String] The name of the slot for the web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_instance_identifiers_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_hybrid_connections_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -17421,7 +15410,7 @@ def list_instance_identifiers_slot_async(resource_group_name, name, slot, custom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridConnectionRelays' request_url = @base_url || @client.base_url @@ -17448,7 +15437,7 @@ def list_instance_identifiers_slot_async(resource_group_name, name, slot, custom if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::WebAppInstanceCollection.mapper() + result_mapper = Azure::ARM::Web::Models::HybridConnection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -17462,79 +15451,69 @@ def list_instance_identifiers_slot_async(resource_group_name, name, slot, custom end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get hybrid connections for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def list_instance_deployments_slot(resource_group_name, name, slot, instance_id, custom_headers = nil) - first_page = list_instance_deployments_slot_as_lazy(resource_group_name, name, slot, instance_id, custom_headers) - first_page.get_all_items + def list_relay_service_connections_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get hybrid connections for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_instance_deployments_slot_with_http_info(resource_group_name, name, slot, instance_id, custom_headers = nil) - list_instance_deployments_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! + def list_relay_service_connections_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # - # List deployments for an app, or a deployment slot, or for an instance of a - # scaled-out app. + # Gets hybrid connections configured for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API returns deployments for the production slot. - # @param instance_id [String] The ID of a specific scaled-out instance. This is - # the value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get hybrid connections for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_instance_deployments_slot_async(resource_group_name, name, slot, instance_id, custom_headers = nil) + def list_relay_service_connections_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17544,13 +15523,13 @@ def list_instance_deployments_slot_async(resource_group_name, name, slot, instan # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -17571,7 +15550,7 @@ def list_instance_deployments_slot_async(resource_group_name, name, slot, instan if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -17585,83 +15564,67 @@ def list_instance_deployments_slot_async(resource_group_name, name, slot, instan end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def get_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, custom_headers = nil) - response = get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + def get_relay_service_connection_slot(resource_group_name, name, entity_name, slot, custom_headers = nil) + response = get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! response.body unless response.nil? end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, custom_headers = nil) - get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + def get_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, slot, custom_headers = nil) + get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! end # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # - # Get a deployment by its ID for an app, a specific deployment slot, and/or a - # specific scaled-out instance. + # Gets a hybrid connection configuration by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will get a hybrid connection for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + def get_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17671,13 +15634,13 @@ def get_instance_deployment_slot_async(resource_group_name, name, id, slot, inst # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -17698,7 +15661,7 @@ def get_instance_deployment_slot_async(resource_group_name, name, id, slot, inst if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -17712,87 +15675,80 @@ def get_instance_deployment_slot_async(resource_group_name, name, id, slot, inst end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. + # the API will create or update a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Deployment] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def create_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) - response = create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers).value! + def create_or_update_relay_service_connection_slot(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + response = create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! response.body unless response.nil? end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. + # the API will create or update a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) - create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers).value! + def create_or_update_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! end # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Create a deployment for an app, a specific deployment slot, and/or a specific - # scaled-out instance. + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] ID of an existing deployment. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API creates a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" - # @param deployment [Deployment] Deployment details. + # the API will create or update a hybrid connection for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) + def create_or_update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? - fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17806,17 +15762,17 @@ def create_instance_deployment_slot_async(resource_group_name, name, id, slot, i request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::Deployment.mapper() - request_content = @client.serialize(request_mapper, deployment) + request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), @@ -17838,7 +15794,7 @@ def create_instance_deployment_slot_async(resource_group_name, name, id, slot, i if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::Deployment.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -17852,82 +15808,66 @@ def create_instance_deployment_slot_async(resource_group_name, name, id, slot, i end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will delete a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # - def delete_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, custom_headers = nil) - response = delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + def delete_relay_service_connection_slot(resource_group_name, name, entity_name, slot, custom_headers = nil) + response = delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! nil end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will delete a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, custom_headers = nil) - delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + def delete_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, slot, custom_headers = nil) + delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers).value! end # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # - # Delete a deployment by its ID for an app, a specific deployment slot, and/or - # a specific scaled-out instance. + # Deletes a relay service connection by its name. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param id [String] Deployment ID. + # @param entity_name [String] Name of the hybrid connection configuration. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API deletes a deployment for the production slot. - # @param instance_id [String] ID of a specific scaled-out instance. This is the - # value of the name property in the JSON response from "GET - # api/sites/{siteName}/instances" + # the API will delete a hybrid connection for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + def delete_relay_service_connection_slot_async(resource_group_name, name, entity_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'id is nil' if id.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -17937,13 +15877,13 @@ def delete_instance_deployment_slot_async(resource_group_name, name, id, slot, i # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -17954,7 +15894,7 @@ def delete_instance_deployment_slot_async(resource_group_name, name, id, slot, i http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -17968,67 +15908,80 @@ def delete_instance_deployment_slot_async(resource_group_name, name, id, slot, i end # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create or update a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [RelayServiceConnectionEntity] operation results. # - def get_instance_ms_deploy_status_slot(resource_group_name, name, slot, instance_id, custom_headers = nil) - response = get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! + def update_relay_service_connection_slot(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + response = update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create or update a hybrid connection for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_instance_ms_deploy_status_slot_with_http_info(resource_group_name, name, slot, instance_id, custom_headers = nil) - get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! + def update_relay_service_connection_slot_with_http_info(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) + update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers).value! end # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # - # Invoke the MSDeploy web app extension as pass-through API + # Creates a new hybrid connection configuration (PUT), or updates an existing + # one (PATCH). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param entity_name [String] Name of the hybrid connection configuration. + # @param connection_envelope [RelayServiceConnectionEntity] Details of the + # hybrid connection configuration. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will create or update a hybrid connection for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, instance_id, custom_headers = nil) + def update_relay_service_connection_slot_async(resource_group_name, name, entity_name, connection_envelope, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'entity_name is nil' if entity_name.nil? + fail ArgumentError, 'connection_envelope is nil' if connection_envelope.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18038,18 +15991,27 @@ def get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, in # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() + request_content = @client.serialize(request_mapper, connection_envelope) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/hybridconnection/{entityName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'entityName' => entity_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:patch, path_template, options) promise = promise.then do |result| http_response = result.response @@ -18065,7 +16027,7 @@ def get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, in if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::RelayServiceConnectionEntity.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18079,121 +16041,63 @@ def get_instance_ms_deploy_status_slot_async(resource_group_name, name, slot, in end # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MSDeployStatus] operation results. - # - def create_instance_msdeploy_operation_slot(resource_group_name, name, slot, instance_id, msdeploy, custom_headers = nil) - response = create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers).value! - response.body unless response.nil? - end - - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [Concurrent::Promise] promise which provides async access to http - # response. - # - def create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers = nil) - # Send request - promise = begin_create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers) - - promise = promise.then do |response| - # Defining deserialization method. - deserialize_method = lambda do |parsed_response| - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() - parsed_response = @client.deserialize(result_mapper, parsed_response) - end - - # Waiting for response. - @client.get_long_running_operation_result(response, deserialize_method) - end - - promise - end - - # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets the production slot instances. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployLog] operation results. + # @return [Array] operation results. # - def get_instance_msdeploy_log_slot(resource_group_name, name, slot, instance_id, custom_headers = nil) - response = get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! - response.body unless response.nil? + def list_instance_identifiers_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_instance_identifiers_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets the production slot instances. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_instance_msdeploy_log_slot_with_http_info(resource_group_name, name, slot, instance_id, custom_headers = nil) - get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! + def list_instance_identifiers_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_instance_identifiers_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # - # Invoke the MSDeploy Log web app extension as pass-through API + # Gets all scale-out instances of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API gets the production slot instances. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instance_id, custom_headers = nil) + def list_instance_identifiers_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18203,13 +16107,13 @@ def get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instan # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy/log' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -18230,7 +16134,7 @@ def get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instan if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployLog.mapper() + result_mapper = Azure::ARM::Web::Models::WebAppInstanceCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18244,63 +16148,79 @@ def get_instance_msdeploy_log_slot_async(resource_group_name, name, slot, instan end # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns information on the production slot. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SiteCloneability] operation results. + # @return [Array] operation results. # - def is_cloneable_slot(resource_group_name, name, slot, custom_headers = nil) - response = is_cloneable_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def list_instance_deployments_slot(resource_group_name, name, slot, instance_id, custom_headers = nil) + first_page = list_instance_deployments_slot_as_lazy(resource_group_name, name, slot, instance_id, custom_headers) + first_page.get_all_items end # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns information on the production slot. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def is_cloneable_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - is_cloneable_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_instance_deployments_slot_with_http_info(resource_group_name, name, slot, instance_id, custom_headers = nil) + list_instance_deployments_slot_async(resource_group_name, name, slot, instance_id, custom_headers).value! end # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # - # Shows whether an app can be cloned to another resource group or subscription. + # List deployments for an app, or a deployment slot, or for an instance of a + # scaled-out app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. By default, this API - # returns information on the production slot. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API returns deployments for the production slot. + # @param instance_id [String] The ID of a specific scaled-out instance. This is + # the value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def is_cloneable_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_instance_deployments_slot_async(resource_group_name, name, slot, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18310,18 +16230,18 @@ def is_cloneable_slot_async(resource_group_name, name, slot, custom_headers = ni # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/iscloneable' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -18337,7 +16257,7 @@ def is_cloneable_slot_async(resource_group_name, name, slot, custom_headers = ni if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SiteCloneability.mapper() + result_mapper = Azure::ARM::Web::Models::DeploymentCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18351,63 +16271,83 @@ def is_cloneable_slot_async(resource_group_name, name, slot, custom_headers = ni end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metric definitions of the production slot. + # the API gets a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [Deployment] operation results. # - def list_metric_definitions_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_metric_definitions_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def get_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + response = get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + response.body unless response.nil? end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metric definitions of the production slot. + # the API gets a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_metric_definitions_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_metric_definitions_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! end # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # - # Gets all metric definitions of an app (or deployment slot, if specified). + # Get a deployment by its ID for an app, a specific deployment slot, and/or a + # specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] Deployment ID. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metric definitions of the production slot. + # the API gets a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_metric_definitions_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18417,13 +16357,13 @@ def list_metric_definitions_slot_async(resource_group_name, name, slot, custom_h # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/metricdefinitions' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -18444,7 +16384,7 @@ def list_metric_definitions_slot_async(resource_group_name, name, slot, custom_h if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ResourceMetricDefinitionCollection.mapper() + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18458,81 +16398,87 @@ def list_metric_definitions_slot_async(resource_group_name, name, slot, custom_h end # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metrics of the production slot. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. + # the API creates a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [Deployment] operation results. # - def list_metrics_slot(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) - first_page = list_metrics_slot_as_lazy(resource_group_name, name, slot, details, filter, custom_headers) - first_page.get_all_items + def create_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) + response = create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers).value! + response.body unless response.nil? end # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metrics of the production slot. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. + # the API creates a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_metrics_slot_with_http_info(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) - list_metrics_slot_async(resource_group_name, name, slot, details, filter, custom_headers).value! + def create_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) + create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers).value! end # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # - # Gets performance metrics of an app (or deployment slot, if specified). + # Create a deployment for an app, a specific deployment slot, and/or a specific + # scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param id [String] ID of an existing deployment. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get metrics of the production slot. - # @param details [Boolean] Specify "true" to include metric details in the - # response. It is "false" by default. - # @param filter [String] Return only metrics specified in the filter (using - # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq - # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq - # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. + # the API creates a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" + # @param deployment [Deployment] Deployment details. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_metrics_slot_async(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) + def create_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, deployment, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? + fail ArgumentError, 'deployment is nil' if deployment.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18542,19 +16488,27 @@ def list_metrics_slot_async(resource_group_name, name, slot, details = nil, filt # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/metrics' + + request_headers['Content-Type'] = 'application/json; charset=utf-8' + + # Serialize Request + request_mapper = Azure::ARM::Web::Models::Deployment.mapper() + request_content = @client.serialize(request_mapper, deployment) + request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil + + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'details' => details,'api-version' => api_version}, - skip_encoding_query_params: {'$filter' => filter}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + query_params: {'api-version' => api_version}, + body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:put, path_template, options) promise = promise.then do |result| http_response = result.response @@ -18570,7 +16524,7 @@ def list_metrics_slot_async(resource_group_name, name, slot, details = nil, filt if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::ResourceMetricCollection.mapper() + result_mapper = Azure::ARM::Web::Models::Deployment.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18584,66 +16538,82 @@ def list_metrics_slot_async(resource_group_name, name, slot, details = nil, filt end # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of the deployment slot + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API deletes a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MigrateMySqlStatus] operation results. # - def get_migrate_my_sql_status_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def delete_instance_deployment_slot(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + response = delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! + nil end # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of the deployment slot + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API deletes a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_migrate_my_sql_status_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers).value! + def delete_instance_deployment_slot_with_http_info(resource_group_name, name, id, slot, instance_id, custom_headers = nil) + delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers).value! end # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # - # Returns the status of MySql in app migration, if one is active, and whether - # or not MySql in app is enabled + # Delete a deployment by its ID for an app, a specific deployment slot, and/or + # a specific scaled-out instance. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of the deployment slot + # @param name [String] Name of the app. + # @param id [String] Deployment ID. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API deletes a deployment for the production slot. + # @param instance_id [String] ID of a specific scaled-out instance. This is the + # value of the name property in the JSON response from "GET + # api/sites/{siteName}/instances" # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers = nil) + def delete_instance_deployment_slot_async(resource_group_name, name, id, slot, instance_id, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'id is nil' if id.nil? fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, 'instance_id is nil' if instance_id.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18653,39 +16623,29 @@ def get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/migratemysql/status' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/deployments/{id}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'id' => id,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:delete, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MigrateMySqlStatus.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -18694,69 +16654,62 @@ def get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom end # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get network features for the production slot. + # @param slot [String] Name of the deployment slot. By default, this API + # returns information on the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [NetworkFeatures] operation results. + # @return [SiteCloneability] operation results. # - def list_network_features_slot(resource_group_name, name, view, slot, custom_headers = nil) - response = list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers).value! + def is_cloneable_slot(resource_group_name, name, slot, custom_headers = nil) + response = is_cloneable_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get network features for the production slot. + # @param slot [String] Name of the deployment slot. By default, this API + # returns information on the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_network_features_slot_with_http_info(resource_group_name, name, view, slot, custom_headers = nil) - list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers).value! + def is_cloneable_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + is_cloneable_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # - # Gets all network features used by the app (or deployment slot, if specified). + # Shows whether an app can be cloned to another resource group or subscription. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param view [String] The type of view. This can either be "summary" or - # "detailed". - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get network features for the production slot. + # @param slot [String] Name of the deployment slot. By default, this API + # returns information on the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers = nil) + def is_cloneable_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'view is nil' if view.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -18767,24 +16720,24 @@ def list_network_features_slot_async(resource_group_name, name, view, slot, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkFeatures/{view}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/iscloneable' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'view' => view,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 404 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -18794,7 +16747,7 @@ def list_network_features_slot_async(resource_group_name, name, view, slot, cust if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::NetworkFeatures.mapper() + result_mapper = Azure::ARM::Web::Models::SiteCloneability.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18808,72 +16761,60 @@ def list_network_features_slot_async(resource_group_name, name, view, slot, cust end # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metric definitions of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [String] operation results. + # @return [Array] operation results. # - def start_web_site_network_trace_slot(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) - response = start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! - response.body unless response.nil? + def list_metric_definitions_slot(resource_group_name, name, slot, custom_headers = nil) + first_page = list_metric_definitions_slot_as_lazy(resource_group_name, name, slot, custom_headers) + first_page.get_all_items end # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metric definitions of the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def start_web_site_network_trace_slot_with_http_info(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) - start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! + def list_metric_definitions_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_metric_definitions_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # - # Start capturing network packets for the site. + # Gets all metric definitions of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. - # @param duration_in_seconds [Integer] The duration to keep capturing in - # seconds. - # @param max_frame_length [Integer] The maximum frame length in bytes - # (Optional). - # @param sas_url [String] The Blob URL to store capture file. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metric definitions of the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) + def list_metric_definitions_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -18886,18 +16827,18 @@ def start_web_site_network_trace_slot_async(resource_group_name, name, slot, dur # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/start' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/metricdefinitions' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'durationInSeconds' => duration_in_seconds,'maxFrameLength' => max_frame_length,'sasUrl' => sas_url,'api-version' => api_version}, + query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -18909,17 +16850,11 @@ def start_web_site_network_trace_slot_async(resource_group_name, name, slot, dur end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::ResourceMetricDefinitionCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -18933,57 +16868,78 @@ def start_web_site_network_trace_slot_async(resource_group_name, name, slot, dur end # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metrics of the production slot. + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [String] operation results. + # @return [Array] operation results. # - def stop_web_site_network_trace_slot(resource_group_name, name, slot, custom_headers = nil) - response = stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? + def list_metrics_slot(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) + first_page = list_metrics_slot_as_lazy(resource_group_name, name, slot, details, filter, custom_headers) + first_page.get_all_items end # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metrics of the production slot. + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def stop_web_site_network_trace_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_metrics_slot_with_http_info(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) + list_metrics_slot_async(resource_group_name, name, slot, details, filter, custom_headers).value! end # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # - # Stop ongoing capturing network packets for the site. + # Gets performance metrics of an app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] The name of the web app. - # @param slot [String] The name of the slot for this web app. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get metrics of the production slot. + # @param details [Boolean] Specify "true" to include metric details in the + # response. It is "false" by default. + # @param filter [String] Return only metrics specified in the filter (using + # OData syntax). For example: $filter=(name.value eq 'Metric1' or name.value eq + # 'Metric2') and startTime eq '2014-01-01T00:00:00Z' and endTime eq + # '2014-12-31T23:59:59Z' and timeGrain eq duration'[Hour|Minute|Day]'. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_metrics_slot_async(resource_group_name, name, slot, details = nil, filter = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -18996,18 +16952,19 @@ def stop_web_site_network_trace_slot_async(resource_group_name, name, slot, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/stop' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/metrics' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + query_params: {'details' => details,'api-version' => api_version}, + skip_encoding_query_params: {'$filter' => filter}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -19023,13 +16980,7 @@ def stop_web_site_network_trace_slot_async(resource_group_name, name, slot, cust if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = { - required: false, - serialized_name: 'parsed_response', - type: { - name: 'String' - } - } + result_mapper = Azure::ARM::Web::Models::ResourceMetricCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19043,65 +16994,63 @@ def stop_web_site_network_trace_slot_async(resource_group_name, name, slot, cust end # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API generate a new publishing password for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of the deployment slot # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [MigrateMySqlStatus] operation results. # - def generate_new_site_publishing_password_slot(resource_group_name, name, slot, custom_headers = nil) - response = generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers).value! - nil + def get_migrate_my_sql_status_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API generate a new publishing password for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of the deployment slot # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def generate_new_site_publishing_password_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_migrate_my_sql_status_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # - # Generates a new publishing password for an app (or deployment slot, if - # specified). + # Returns the status of MySql in app migration, if one is active, and whether + # or not MySql in app is enabled # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API generate a new publishing password for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of the deployment slot # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_migrate_my_sql_status_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -19114,7 +17063,7 @@ def generate_new_site_publishing_password_slot_async(resource_group_name, name, # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/newpassword' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/migratemysql/status' request_url = @base_url || @client.base_url @@ -19125,18 +17074,28 @@ def generate_new_site_publishing_password_slot_async(resource_group_name, name, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::MigrateMySqlStatus.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -19145,74 +17104,69 @@ def generate_new_site_publishing_password_slot_async(resource_group_name, name, end # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. + # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get network features for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [NetworkFeatures] operation results. # - def list_perf_mon_counters_slot(resource_group_name, name, slot, filter = nil, custom_headers = nil) - first_page = list_perf_mon_counters_slot_as_lazy(resource_group_name, name, slot, filter, custom_headers) - first_page.get_all_items + def list_network_features_slot(resource_group_name, name, view, slot, custom_headers = nil) + response = list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers).value! + response.body unless response.nil? end # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. + # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get network features for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_perf_mon_counters_slot_with_http_info(resource_group_name, name, slot, filter = nil, custom_headers = nil) - list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter, custom_headers).value! + def list_network_features_slot_with_http_info(resource_group_name, name, view, slot, custom_headers = nil) + list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers).value! end # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # - # Gets perfmon counters for web app. + # Gets all network features used by the app (or deployment slot, if specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param filter [String] Return only usages/metrics specified in the filter. - # Filter conforms to odata syntax. Example: $filter=(startTime eq - # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq - # duration'[Hour|Minute|Day]'. + # @param name [String] Name of the app. + # @param view [String] The type of view. This can either be "summary" or + # "detailed". + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get network features for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = nil, custom_headers = nil) + def list_network_features_slot_async(resource_group_name, name, view, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'view is nil' if view.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -19223,15 +17177,14 @@ def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/perfcounters' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkFeatures/{view}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'view' => view,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - skip_encoding_query_params: {'$filter' => filter}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } @@ -19241,7 +17194,7 @@ def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 200 || status_code == 404 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -19251,7 +17204,7 @@ def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PerfMonCounterCollection.mapper() + result_mapper = Azure::ARM::Web::Models::NetworkFeatures.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19265,60 +17218,72 @@ def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = end # - # Gets web app's event logs. + # Start capturing network packets for the site. # - # Gets web app's event logs. + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [SitePhpErrorLogFlag] operation results. + # @return [String] operation results. # - def get_site_php_error_log_flag_slot(resource_group_name, name, slot, custom_headers = nil) - response = get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers).value! + def start_web_site_network_trace_slot(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) + response = start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! response.body unless response.nil? end # - # Gets web app's event logs. + # Start capturing network packets for the site. # - # Gets web app's event logs. + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def get_site_php_error_log_flag_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers).value! + # + def start_web_site_network_trace_slot_with_http_info(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) + start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds, max_frame_length, sas_url, custom_headers).value! end # - # Gets web app's event logs. + # Start capturing network packets for the site. # - # Gets web app's event logs. + # Start capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. + # @param duration_in_seconds [Integer] The duration to keep capturing in + # seconds. + # @param max_frame_length [Integer] The maximum frame length in bytes + # (Optional). + # @param sas_url [String] The Blob URL to store capture file. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers = nil) + def start_web_site_network_trace_slot_async(resource_group_name, name, slot, duration_in_seconds = nil, max_frame_length = nil, sas_url = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -19331,18 +17296,18 @@ def get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, cust # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/phplogging' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/start' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, + query_params: {'durationInSeconds' => duration_in_seconds,'maxFrameLength' => max_frame_length,'sasUrl' => sas_url,'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -19358,7 +17323,13 @@ def get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, cust if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::SitePhpErrorLogFlag.mapper() + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'String' + } + } result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19372,60 +17343,57 @@ def get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, cust end # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the premier add-ons for the production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PremierAddOn] operation results. + # @return [String] operation results. # - def list_premier_add_ons_slot(resource_group_name, name, slot, custom_headers = nil) - response = list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers).value! + def stop_web_site_network_trace_slot(resource_group_name, name, slot, custom_headers = nil) + response = stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the premier add-ons for the production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_premier_add_ons_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers).value! + def stop_web_site_network_trace_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # - # Gets the premier add-ons of an app. + # Stop ongoing capturing network packets for the site. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the premier add-ons for the production slot. + # @param name [String] The name of the web app. + # @param slot [String] The name of the slot for this web app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers = nil) + def stop_web_site_network_trace_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -19438,7 +17406,7 @@ def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_head # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/networkTrace/stop' request_url = @base_url || @client.base_url @@ -19449,7 +17417,7 @@ def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_head headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response @@ -19465,7 +17433,13 @@ def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_head if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + result_mapper = { + required: false, + serialized_name: 'parsed_response', + type: { + name: 'String' + } + } result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19479,66 +17453,67 @@ def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_head end # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the named add-on for the production slot. + # the API generate a new publishing password for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PremierAddOn] operation results. # - def get_premier_add_on_slot(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) - response = get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! - response.body unless response.nil? + def generate_new_site_publishing_password_slot(resource_group_name, name, slot, custom_headers = nil) + response = generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers).value! + nil end # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the named add-on for the production slot. + # the API generate a new publishing password for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) - get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! + def generate_new_site_publishing_password_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # - # Gets a named add-on of an app. + # Generates a new publishing password for an app (or deployment slot, if + # specified). # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the named add-on for the production slot. + # the API generate a new publishing password for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + def generate_new_site_publishing_password_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -19549,39 +17524,29 @@ def get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/newpassword' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:get, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end result end @@ -19590,73 +17555,74 @@ def get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name end # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. **** CURRENTLY UNUSED ***** + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PremierAddOn] operation results. + # @return [Array] operation results. # - def add_premier_add_on_slot(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) - response = add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers).value! - response.body unless response.nil? + def list_perf_mon_counters_slot(resource_group_name, name, slot, filter = nil, custom_headers = nil) + first_page = list_perf_mon_counters_slot_as_lazy(resource_group_name, name, slot, filter, custom_headers) + first_page.get_all_items end # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. **** CURRENTLY UNUSED ***** + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def add_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) - add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers).value! + def list_perf_mon_counters_slot_with_http_info(resource_group_name, name, slot, filter = nil, custom_headers = nil) + list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter, custom_headers).value! end # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # - # Updates a named add-on of an app. + # Gets perfmon counters for web app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param premier_add_on [PremierAddOn] A JSON representation of the edited - # premier add-on. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will update the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. **** CURRENTLY UNUSED ***** + # @param filter [String] Return only usages/metrics specified in the filter. + # Filter conforms to odata syntax. Example: $filter=(startTime eq + # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq + # duration'[Hour|Minute|Day]'. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) + def list_perf_mon_counters_slot_async(resource_group_name, name, slot, filter = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? - fail ArgumentError, 'premier_add_on is nil' if premier_add_on.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -19667,27 +17633,19 @@ def add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() - request_content = @client.serialize(request_mapper, premier_add_on) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/perfcounters' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, + skip_encoding_query_params: {'$filter' => filter}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -19703,7 +17661,7 @@ def add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + result_mapper = Azure::ARM::Web::Models::PerfMonCounterCollection.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19717,65 +17675,62 @@ def add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name end # - # Delete a premier add-on from an app. + # Gets web app's event logs. # - # Delete a premier add-on from an app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [SitePhpErrorLogFlag] operation results. # - def delete_premier_add_on_slot(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) - response = delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! - nil + def get_site_php_error_log_flag_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Delete a premier add-on from an app. + # Gets web app's event logs. # - # Delete a premier add-on from an app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) - delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! + def get_site_php_error_log_flag_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Delete a premier add-on from an app. + # Gets web app's event logs. # - # Delete a premier add-on from an app. + # Gets web app's event logs. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param premier_add_on_name [String] Add-on name. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the named add-on for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + def get_site_php_error_log_flag_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -19786,18 +17741,18 @@ def delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_n # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/phplogging' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:delete, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -19809,6 +17764,16 @@ def delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_n end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::SitePhpErrorLogFlag.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -19817,60 +17782,60 @@ def delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_n end # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API will get the premier add-ons for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [Array] operation results. + # @return [PremierAddOn] operation results. # - def list_public_certificates_slot(resource_group_name, name, slot, custom_headers = nil) - first_page = list_public_certificates_slot_as_lazy(resource_group_name, name, slot, custom_headers) - first_page.get_all_items + def list_premier_add_ons_slot(resource_group_name, name, slot, custom_headers = nil) + response = list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API will get the premier add-ons for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def list_public_certificates_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - list_public_certificates_slot_async(resource_group_name, name, slot, custom_headers).value! + def list_premier_add_ons_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # - # Get public certificates for an app or a deployment slot. + # Gets the premier add-ons of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. + # the API will get the premier add-ons for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def list_public_certificates_slot_async(resource_group_name, name, slot, custom_headers = nil) + def list_premier_add_ons_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -19883,7 +17848,7 @@ def list_public_certificates_slot_async(resource_group_name, name, slot, custom_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons' request_url = @base_url || @client.base_url @@ -19910,7 +17875,7 @@ def list_public_certificates_slot_async(resource_group_name, name, slot, custom_ if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificateCollection.mapper() + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -19924,73 +17889,67 @@ def list_public_certificates_slot_async(resource_group_name, name, slot, custom_ end # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param public_certificate_name [String] Public CertificateName + # the API will get the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PublicCertificate] operation results. + # @return [PremierAddOn] operation results. # - def get_public_certificate_slot(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) - response = get_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers).value! + def get_premier_add_on_slot(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + response = get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! response.body unless response.nil? end # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param public_certificate_name [String] Public CertificateName + # the API will get the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def get_public_certificate_slot_with_http_info(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) - get_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers).value! + def get_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! end # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # - # Get the named public certificate for an app (or deployment slot, if - # specified). + # Gets a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API the named binding for the production slot. - # @param public_certificate_name [String] Public CertificateName + # the API will get the named add-on for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def get_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) + def get_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -20000,13 +17959,13 @@ def get_public_certificate_slot_async(resource_group_name, name, slot, public_ce # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'publicCertificateName' => public_certificate_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -20027,7 +17986,7 @@ def get_public_certificate_slot_async(resource_group_name, name, slot, public_ce if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -20041,73 +18000,73 @@ def get_public_certificate_slot_async(resource_group_name, name, slot, public_ce end # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will update the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [PublicCertificate] operation results. + # @return [PremierAddOn] operation results. # - def create_or_update_public_certificate_slot(resource_group_name, name, public_certificate_name, public_certificate, slot, custom_headers = nil) - response = create_or_update_public_certificate_slot_async(resource_group_name, name, public_certificate_name, public_certificate, slot, custom_headers).value! + def add_premier_add_on_slot(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) + response = add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers).value! response.body unless response.nil? end # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will update the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def create_or_update_public_certificate_slot_with_http_info(resource_group_name, name, public_certificate_name, public_certificate, slot, custom_headers = nil) - create_or_update_public_certificate_slot_async(resource_group_name, name, public_certificate_name, public_certificate, slot, custom_headers).value! + def add_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) + add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers).value! end # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # - # Creates a hostname binding for an app. + # Updates a named add-on of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. - # @param public_certificate_name [String] Public certificate name. - # @param public_certificate [PublicCertificate] Public certificate details. - # This is the JSON representation of a PublicCertificate object. + # @param premier_add_on_name [String] Add-on name. + # @param premier_add_on [PremierAddOn] A JSON representation of the edited + # premier add-on. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will create a binding for the production slot. + # the API will update the named add-on for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def create_or_update_public_certificate_slot_async(resource_group_name, name, public_certificate_name, public_certificate, slot, custom_headers = nil) + def add_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, premier_add_on, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? - fail ArgumentError, 'public_certificate is nil' if public_certificate.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? + fail ArgumentError, 'premier_add_on is nil' if premier_add_on.nil? fail ArgumentError, 'slot is nil' if slot.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -20122,17 +18081,17 @@ def create_or_update_public_certificate_slot_async(resource_group_name, name, pu request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() - request_content = @client.serialize(request_mapper, public_certificate) + request_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() + request_content = @client.serialize(request_mapper, premier_add_on) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'publicCertificateName' => public_certificate_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), @@ -20154,7 +18113,7 @@ def create_or_update_public_certificate_slot_async(resource_group_name, name, pu if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificate.mapper() + result_mapper = Azure::ARM::Web::Models::PremierAddOn.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -20168,66 +18127,66 @@ def create_or_update_public_certificate_slot_async(resource_group_name, name, pu end # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. - # @param public_certificate_name [String] Public Certificate Name. + # the API will delete the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # - def delete_public_certificate_slot(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) - response = delete_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers).value! + def delete_premier_add_on_slot(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + response = delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! nil end # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. - # @param public_certificate_name [String] Public Certificate Name. + # the API will delete the named add-on for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def delete_public_certificate_slot_with_http_info(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) - delete_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers).value! + def delete_premier_add_on_slot_with_http_info(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) + delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers).value! end # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # - # Deletes a hostname binding for an app. + # Delete a premier add-on from an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of the app. + # @param premier_add_on_name [String] Add-on name. # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will delete the binding for the production slot. - # @param public_certificate_name [String] Public Certificate Name. + # the API will delete the named add-on for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def delete_public_certificate_slot_async(resource_group_name, name, slot, public_certificate_name, custom_headers = nil) + def delete_premier_add_on_slot_async(resource_group_name, name, premier_add_on_name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'premier_add_on_name is nil' if premier_add_on_name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'public_certificate_name is nil' if public_certificate_name.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -20237,13 +18196,13 @@ def delete_public_certificate_slot_async(resource_group_name, name, slot, public # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/publicCertificates/{publicCertificateName}' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/premieraddons/{premierAddOnName}' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'publicCertificateName' => public_certificate_name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'premierAddOnName' => premier_add_on_name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url @@ -20254,7 +18213,7 @@ def delete_public_certificate_slot_async(resource_group_name, name, slot, public http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 || status_code == 204 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -20407,9 +18366,9 @@ def list_publishing_profile_xml_with_secrets_slot_async(resource_group_name, nam # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param slot [String] Name of web app slot. If not specified then will default # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that @@ -20426,9 +18385,9 @@ def recover_slot(resource_group_name, name, recovery_entity, slot, custom_header # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param slot [String] Name of web app slot. If not specified then will default # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that @@ -20452,69 +18411,166 @@ def recover_slot_async(resource_group_name, name, recovery_entity, slot, custom_ @client.get_long_running_operation_result(response, deserialize_method) end - promise + promise + end + + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API resets configuration settings for the production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # + def reset_slot_configuration_slot(resource_group_name, name, slot, custom_headers = nil) + response = reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + nil + end + + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API resets configuration settings for the production slot. + # @param custom_headers [Hash{String => String}] A hash of custom headers that + # will be added to the HTTP request. + # + # @return [MsRestAzure::AzureOperationResponse] HTTP response information. + # + def reset_slot_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + end + + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # Resets the configuration settings of the current slot if they were previously + # modified by calling the API with POST. + # + # @param resource_group_name [String] Name of the resource group to which the + # resource belongs. + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API resets configuration settings for the production slot. + # @param [Hash{String => String}] A hash of custom headers that will be added + # to the HTTP request. + # + # @return [Concurrent::Promise] Promise object which holds the HTTP response. + # + def reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? + fail ArgumentError, 'name is nil' if name.nil? + fail ArgumentError, 'slot is nil' if slot.nil? + fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? + api_version = '2016-08-01' + + + request_headers = {} + + # Set Headers + request_headers['x-ms-client-request-id'] = SecureRandom.uuid + request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/resetSlotConfig' + + request_url = @base_url || @client.base_url + + options = { + middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + query_params: {'api-version' => api_version}, + headers: request_headers.merge(custom_headers || {}), + base_url: request_url + } + promise = @client.make_request_async(:post, path_template, options) + + promise = promise.then do |result| + http_response = result.response + status_code = http_response.status + response_content = http_response.body + unless status_code == 200 + error_model = JSON.load(response_content) + fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) + end + + result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + + result + end + + promise.execute end # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API resets configuration settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # + # @return [ResourceHealthMetadata] operation results. # - def reset_slot_configuration_slot(resource_group_name, name, slot, custom_headers = nil) - response = reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! - nil + def get_resource_health_metadata_slot(resource_group_name, name, slot, custom_headers = nil) + response = get_resource_health_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! + response.body unless response.nil? end # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API resets configuration settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def reset_slot_configuration_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers).value! + def get_resource_health_metadata_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + get_resource_health_metadata_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # - # Resets the configuration settings of the current slot if they were previously - # modified by calling the API with POST. + # Gets the category of ResourceHealthMetadata to use for the given site # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API resets configuration settings for the production slot. + # @param name [String] Name of web app + # @param slot [String] Name of web app slot. If not specified then will default + # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_headers = nil) + def get_resource_health_metadata_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? @@ -20527,7 +18583,7 @@ def reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_ # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/resetSlotConfig' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/resourceHealthMetadata' request_url = @base_url || @client.base_url @@ -20538,7 +18594,7 @@ def reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_ headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:post, path_template, options) + promise = @client.make_request_async(:get, path_template, options) promise = promise.then do |result| http_response = result.response @@ -20550,6 +18606,16 @@ def reset_slot_configuration_slot_async(resource_group_name, name, slot, custom_ end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? + # Deserialize Response + if status_code == 200 + begin + parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) + result_mapper = Azure::ARM::Web::Models::ResourceHealthMetadata.mapper() + result.body = @client.deserialize(result_mapper, parsed_response) + rescue Exception => e + fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) + end + end result end @@ -21480,7 +19546,7 @@ def sync_repository_slot_async(resource_group_name, name, slot, custom_headers = http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -23466,7 +21532,7 @@ def sync_repository_async(resource_group_name, name, custom_headers = nil) http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 200 + unless status_code == 204 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end @@ -24840,221 +22906,8 @@ def begin_restore_with_http_info(resource_group_name, name, backup_id, request, def begin_restore_async(resource_group_name, name, backup_id, request, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'backup_id is nil' if backup_id.nil? - fail ArgumentError, 'request is nil' if request.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() - request_content = @client.serialize(request_mapper, request) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}/restore' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [User] operation results. - # - def begin_list_publishing_credentials(resource_group_name, name, custom_headers = nil) - response = begin_list_publishing_credentials_async(resource_group_name, name, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def begin_list_publishing_credentials_with_http_info(resource_group_name, name, custom_headers = nil) - begin_list_publishing_credentials_async(resource_group_name, name, custom_headers).value! - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def begin_list_publishing_credentials_async(resource_group_name, name, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/publishingcredentials/list' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::User.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MSDeployStatus] operation results. - # - def begin_create_msdeploy_operation(resource_group_name, name, msdeploy, custom_headers = nil) - response = begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers).value! - response.body unless response.nil? - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def begin_create_msdeploy_operation_with_http_info(resource_group_name, name, msdeploy, custom_headers = nil) - begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers).value! - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'msdeploy is nil' if msdeploy.nil? + fail ArgumentError, 'backup_id is nil' if backup_id.nil? + fail ArgumentError, 'request is nil' if request.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -25068,39 +22921,39 @@ def begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, c request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::MSDeploy.mapper() - request_content = @client.serialize(request_mapper, msdeploy) + request_mapper = Azure::ARM::Web::Models::RestoreRequest.mapper() + request_content = @client.serialize(request_mapper, request) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/extensions/MSDeploy' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/backups/{backupId}/restore' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 201 || status_code == 409 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response - if status_code == 201 + if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -25114,64 +22967,56 @@ def begin_create_msdeploy_operation_async(resource_group_name, name, msdeploy, c end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [User] operation results. # - def begin_create_instance_msdeploy_operation(resource_group_name, name, instance_id, msdeploy, custom_headers = nil) - response = begin_create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers).value! + def begin_list_publishing_credentials(resource_group_name, name, custom_headers = nil) + response = begin_list_publishing_credentials_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def begin_create_instance_msdeploy_operation_with_http_info(resource_group_name, name, instance_id, msdeploy, custom_headers = nil) - begin_create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers).value! + def begin_list_publishing_credentials_with_http_info(resource_group_name, name, custom_headers = nil) + begin_list_publishing_credentials_async(resource_group_name, name, custom_headers).value! end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def begin_create_instance_msdeploy_operation_async(resource_group_name, name, instance_id, msdeploy, custom_headers = nil) + def begin_list_publishing_credentials_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? - fail ArgumentError, 'msdeploy is nil' if msdeploy.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -25181,43 +23026,34 @@ def begin_create_instance_msdeploy_operation_async(resource_group_name, name, in # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::MSDeploy.mapper() - request_content = @client.serialize(request_mapper, msdeploy) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/instances/{instanceId}/extensions/MSDeploy' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/config/publishingcredentials/list' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 201 || status_code == 409 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response - if status_code == 201 + if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::User.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -25471,9 +23307,9 @@ def begin_migrate_my_sql_async(resource_group_name, name, migration_request_enve # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # @@ -25492,9 +23328,9 @@ def begin_recover(resource_group_name, name, recovery_entity, custom_headers = n # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # @@ -25512,9 +23348,9 @@ def begin_recover_with_http_info(resource_group_name, name, recovery_entity, cus # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # @@ -25537,7 +23373,7 @@ def begin_recover_async(resource_group_name, name, recovery_entity, custom_heade request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::SnapshotRecoveryRequest.mapper() + request_mapper = Azure::ARM::Web::Models::CsmSiteRecoveryEntity.mapper() request_content = @client.serialize(request_mapper, recovery_entity) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil @@ -25840,256 +23676,29 @@ def begin_restore_slot_async(resource_group_name, name, backup_id, request, slot options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the publishing credentials for the production slot. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [User] operation results. - # - def begin_list_publishing_credentials_slot(resource_group_name, name, slot, custom_headers = nil) - response = begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! - response.body unless response.nil? - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the publishing credentials for the production slot. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def begin_list_publishing_credentials_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) - begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! - end - - # - # Gets the Git/FTP publishing credentials of an app. - # - # Gets the Git/FTP publishing credentials of an app. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API will get the publishing credentials for the production slot. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/publishingcredentials/list' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, - query_params: {'api-version' => api_version}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::User.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MSDeployStatus] operation results. - # - def begin_create_msdeploy_operation_slot(resource_group_name, name, slot, msdeploy, custom_headers = nil) - response = begin_create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers).value! - response.body unless response.nil? - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def begin_create_msdeploy_operation_slot_with_http_info(resource_group_name, name, slot, msdeploy, custom_headers = nil) - begin_create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers).value! - end - - # - # Invoke the MSDeploy web app extension as pass-through API - # - # Invoke the MSDeploy web app extension as pass-through API - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param msdeploy [MSDeploy] Details of MSDeploy operation - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def begin_create_msdeploy_operation_slot_async(resource_group_name, name, slot, msdeploy, custom_headers = nil) - fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? - fail ArgumentError, 'name is nil' if name.nil? - fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'msdeploy is nil' if msdeploy.nil? - fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? - api_version = '2016-08-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::MSDeploy.mapper() - request_content = @client.serialize(request_mapper, msdeploy) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/extensions/MSDeploy' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'backupId' => backup_id,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 201 || status_code == 409 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response - if status_code == 201 + if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::RestoreResponse.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -26103,71 +23712,63 @@ def begin_create_msdeploy_operation_slot_async(resource_group_name, name, slot, end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get the publishing credentials for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # - # @return [MSDeployStatus] operation results. + # @return [User] operation results. # - def begin_create_instance_msdeploy_operation_slot(resource_group_name, name, slot, instance_id, msdeploy, custom_headers = nil) - response = begin_create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers).value! + def begin_list_publishing_credentials_slot(resource_group_name, name, slot, custom_headers = nil) + response = begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! response.body unless response.nil? end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get the publishing credentials for the production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that # will be added to the HTTP request. # # @return [MsRestAzure::AzureOperationResponse] HTTP response information. # - def begin_create_instance_msdeploy_operation_slot_with_http_info(resource_group_name, name, slot, instance_id, msdeploy, custom_headers = nil) - begin_create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers).value! + def begin_list_publishing_credentials_slot_with_http_info(resource_group_name, name, slot, custom_headers = nil) + begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers).value! end # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # - # Invoke the MSDeploy web app extension as pass-through API + # Gets the Git/FTP publishing credentials of an app. # # @param resource_group_name [String] Name of the resource group to which the # resource belongs. - # @param name [String] Name of web app - # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. - # @param instance_id [String] Id of web app instance - # @param msdeploy [MSDeploy] Details of MSDeploy operation + # @param name [String] Name of the app. + # @param slot [String] Name of the deployment slot. If a slot is not specified, + # the API will get the publishing credentials for the production slot. # @param [Hash{String => String}] A hash of custom headers that will be added # to the HTTP request. # # @return [Concurrent::Promise] Promise object which holds the HTTP response. # - def begin_create_instance_msdeploy_operation_slot_async(resource_group_name, name, slot, instance_id, msdeploy, custom_headers = nil) + def begin_list_publishing_credentials_slot_async(resource_group_name, name, slot, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'slot is nil' if slot.nil? - fail ArgumentError, 'instance_id is nil' if instance_id.nil? - fail ArgumentError, 'msdeploy is nil' if msdeploy.nil? fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil? api_version = '2016-08-01' @@ -26177,43 +23778,34 @@ def begin_create_instance_msdeploy_operation_slot_async(resource_group_name, nam # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::MSDeploy.mapper() - request_content = @client.serialize(request_mapper, msdeploy) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/instances/{instanceId}/extensions/MSDeploy' + path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Web/sites/{name}/slots/{slot}/config/publishingcredentials/list' request_url = @base_url || @client.base_url options = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'instanceId' => instance_id,'subscriptionId' => @client.subscription_id}, + path_params: {'resourceGroupName' => resource_group_name,'name' => name,'slot' => slot,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => api_version}, - body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } - promise = @client.make_request_async(:put, path_template, options) + promise = @client.make_request_async(:post, path_template, options) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body - unless status_code == 201 || status_code == 409 + unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response - if status_code == 201 + if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::MSDeployStatus.mapper() + result_mapper = Azure::ARM::Web::Models::User.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) @@ -26234,9 +23826,9 @@ def begin_create_instance_msdeploy_operation_slot_async(resource_group_name, nam # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param slot [String] Name of web app slot. If not specified then will default # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that @@ -26257,9 +23849,9 @@ def begin_recover_slot(resource_group_name, name, recovery_entity, slot, custom_ # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param slot [String] Name of web app slot. If not specified then will default # to production slot. # @param custom_headers [Hash{String => String}] A hash of custom headers that @@ -26279,9 +23871,9 @@ def begin_recover_slot_with_http_info(resource_group_name, name, recovery_entity # @param resource_group_name [String] Name of the resource group to which the # resource belongs. # @param name [String] Name of web app - # @param recovery_entity [SnapshotRecoveryRequest] Snapshot data used for web - # app recovery. Snapshot information can be obtained by calling GetDeletedSites - # or GetSiteSnapshots API. + # @param recovery_entity [CsmSiteRecoveryEntity] Snapshot data used for web app + # recovery. Snapshot information can be obtained by calling GetDeletedSites or + # GetSiteSnapshots API. # @param slot [String] Name of web app slot. If not specified then will default # to production slot. # @param [Hash{String => String}] A hash of custom headers that will be added @@ -26307,7 +23899,7 @@ def begin_recover_slot_async(resource_group_name, name, recovery_entity, slot, c request_headers['Content-Type'] = 'application/json; charset=utf-8' # Serialize Request - request_mapper = Azure::ARM::Web::Models::SnapshotRecoveryRequest.mapper() + request_mapper = Azure::ARM::Web::Models::CsmSiteRecoveryEntity.mapper() request_content = @client.serialize(request_mapper, recovery_entity) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil @@ -27956,99 +25548,6 @@ def list_perf_mon_counters_next_async(next_page_link, custom_headers = nil) promise.execute end - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificateCollection] operation results. - # - def list_public_certificates_next(next_page_link, custom_headers = nil) - response = list_public_certificates_next_async(next_page_link, custom_headers).value! - response.body unless response.nil? - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_public_certificates_next_with_http_info(next_page_link, custom_headers = nil) - list_public_certificates_next_async(next_page_link, custom_headers).value! - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_public_certificates_next_async(next_page_link, custom_headers = nil) - fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = '{nextLink}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - skip_encoding_path_params: {'nextLink' => next_page_link}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificateCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - # # Gets an app's deployment slots. # @@ -29084,99 +26583,6 @@ def list_perf_mon_counters_slot_next_async(next_page_link, custom_headers = nil) promise.execute end - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificateCollection] operation results. - # - def list_public_certificates_slot_next(next_page_link, custom_headers = nil) - response = list_public_certificates_slot_next_async(next_page_link, custom_headers).value! - response.body unless response.nil? - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def list_public_certificates_slot_next_with_http_info(next_page_link, custom_headers = nil) - list_public_certificates_slot_next_async(next_page_link, custom_headers).value! - end - - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param next_page_link [String] The NextLink from the previous successful call - # to List operation. - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def list_public_certificates_slot_next_async(next_page_link, custom_headers = nil) - fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? - path_template = '{nextLink}' - - request_url = @base_url || @client.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - skip_encoding_path_params: {'nextLink' => next_page_link}, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = @client.make_request_async(:get, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::PublicCertificateCollection.mapper() - result.body = @client.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - # # Get the difference in configuration settings between two web app slots. # @@ -30063,31 +27469,6 @@ def list_perf_mon_counters_as_lazy(resource_group_name, name, filter = nil, cust end end - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificateCollection] which provide lazy access to pages of - # the response. - # - def list_public_certificates_as_lazy(resource_group_name, name, custom_headers = nil) - response = list_public_certificates_async(resource_group_name, name, custom_headers).value! - unless response.nil? - page = response.body - page.next_method = Proc.new do |next_page_link| - list_public_certificates_next_async(next_page_link, custom_headers) - end - page - end - end - # # Gets an app's deployment slots. # @@ -30378,7 +27759,7 @@ def list_metrics_slot_as_lazy(resource_group_name, name, slot, details = nil, fi # resource belongs. # @param name [String] Name of web app # @param slot [String] Name of web app slot. If not specified then will default - # to production slot. + # to production slot. **** CURRENTLY UNUSED ***** # @param filter [String] Return only usages/metrics specified in the filter. # Filter conforms to odata syntax. Example: $filter=(startTime eq # '2014-01-01T00:00:00Z' and endTime eq '2014-12-31T23:59:59Z' and timeGrain eq @@ -30400,33 +27781,6 @@ def list_perf_mon_counters_slot_as_lazy(resource_group_name, name, slot, filter end end - # - # Get public certificates for an app or a deployment slot. - # - # Get public certificates for an app or a deployment slot. - # - # @param resource_group_name [String] Name of the resource group to which the - # resource belongs. - # @param name [String] Name of the app. - # @param slot [String] Name of the deployment slot. If a slot is not specified, - # the API gets hostname bindings for the production slot. - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [PublicCertificateCollection] which provide lazy access to pages of - # the response. - # - def list_public_certificates_slot_as_lazy(resource_group_name, name, slot, custom_headers = nil) - response = list_public_certificates_slot_async(resource_group_name, name, slot, custom_headers).value! - unless response.nil? - page = response.body - page.next_method = Proc.new do |next_page_link| - list_public_certificates_slot_next_async(next_page_link, custom_headers) - end - page - end - end - # # Get the difference in configuration settings between two web app slots. # diff --git a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_site_management_client.rb b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_site_management_client.rb old mode 100644 new mode 100755 index a65418caca..d2fd780d02 --- a/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_site_management_client.rb +++ b/management/azure_mgmt_web/lib/generated/azure_mgmt_web/web_site_management_client.rb @@ -925,111 +925,6 @@ def list_skus_async(custom_headers = nil) promise.execute end - # - # Verifies if this VNET is compatible with an App Service Environment. - # - # Verifies if this VNET is compatible with an App Service Environment by - # analyzing the Network Security Group rules. - # - # @param parameters [VnetParameters] VNET information - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [VnetValidationFailureDetails] operation results. - # - def verify_hosting_environment_vnet(parameters, custom_headers = nil) - response = verify_hosting_environment_vnet_async(parameters, custom_headers).value! - response.body unless response.nil? - end - - # - # Verifies if this VNET is compatible with an App Service Environment. - # - # Verifies if this VNET is compatible with an App Service Environment by - # analyzing the Network Security Group rules. - # - # @param parameters [VnetParameters] VNET information - # @param custom_headers [Hash{String => String}] A hash of custom headers that - # will be added to the HTTP request. - # - # @return [MsRestAzure::AzureOperationResponse] HTTP response information. - # - def verify_hosting_environment_vnet_with_http_info(parameters, custom_headers = nil) - verify_hosting_environment_vnet_async(parameters, custom_headers).value! - end - - # - # Verifies if this VNET is compatible with an App Service Environment. - # - # Verifies if this VNET is compatible with an App Service Environment by - # analyzing the Network Security Group rules. - # - # @param parameters [VnetParameters] VNET information - # @param [Hash{String => String}] A hash of custom headers that will be added - # to the HTTP request. - # - # @return [Concurrent::Promise] Promise object which holds the HTTP response. - # - def verify_hosting_environment_vnet_async(parameters, custom_headers = nil) - fail ArgumentError, 'parameters is nil' if parameters.nil? - fail ArgumentError, 'subscription_id is nil' if subscription_id.nil? - api_version = '2016-03-01' - - - request_headers = {} - - # Set Headers - request_headers['x-ms-client-request-id'] = SecureRandom.uuid - request_headers['accept-language'] = accept_language unless accept_language.nil? - - request_headers['Content-Type'] = 'application/json; charset=utf-8' - - # Serialize Request - request_mapper = Azure::ARM::Web::Models::VnetParameters.mapper() - request_content = self.serialize(request_mapper, parameters) - request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil - - path_template = 'subscriptions/{subscriptionId}/providers/Microsoft.Web/verifyHostingEnvironmentVnet' - - request_url = @base_url || self.base_url - - options = { - middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], - path_params: {'subscriptionId' => subscription_id}, - query_params: {'api-version' => api_version}, - body: request_content, - headers: request_headers.merge(custom_headers || {}), - base_url: request_url - } - promise = self.make_request_async(:post, path_template, options) - - promise = promise.then do |result| - http_response = result.response - status_code = http_response.status - response_content = http_response.body - unless status_code == 200 - error_model = JSON.load(response_content) - fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) - end - - result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? - # Deserialize Response - if status_code == 200 - begin - parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) - result_mapper = Azure::ARM::Web::Models::VnetValidationFailureDetails.mapper() - result.body = self.deserialize(result_mapper, parsed_response) - rescue Exception => e - fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result) - end - end - - result - end - - promise.execute - end - # # Move resources between resource groups. #