2016-07-04 4 views
1

Я использую API Azure Insights Rest для экспорта данных мониторинга для нескольких разных ресурсов в моей учетной записи Azure.Какие типы ресурсов поддерживаются API Azure Insights?

Я использую вызов этой конечную точку, чтобы получить данные:

https://management.azure.com/subscriptions/{subscription-id}/resourceGroups/{resource-group-name}/providers/{resource-provider-namespace}/{resource-type}/{resource-name}/metrics 

я получить список всех ресурсов в моих подписках по телефону:

https://management.azure.com/{subscription-id}/resources 

возвращает этот вызов json с большим количеством записей. Каждая запись имеет свойство «type», которое описывает тип ресурса. Например это:

"type": "Microsoft.Compute/virtualMachines" 

Моя проблема заключается в том, что лишь немногие из этих типов поддерживает чтение данных мониторинга с помощью API я использую. Может ли кто-нибудь сказать мне, где получить информацию, какие типы ресурсов поддерживаются API?

ответ

2

Вот ссылка на список поддерживаемых типов ресурсов по ж/все доступные метрики:

https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/monitoring-supported-metrics

Потребовалось время, чтобы отследить - он не показывает в поиске, и я он никогда не видел, чтобы он упоминался на страницах «Мониторинг/Анализ». Не уверен, почему он так похоронен, это огромная помощь и экономия времени.

Примечание. Не знаете, почему список поставщиков был предложен как ответ ранее, но его нужно удалить - это не имеет никакого отношения к заданному вопросу.

+0

Это было бы огромной помощью. Большое спасибо. Жаль, что раньше этого не нашел. : / – Woozar

1

Вы можете использовать PowerShell и Azure-cli, чтобы получить список типов ресурсов с легкостью.

  • PowerShell
    запустить следующую команду:
    Login-AzureRmAccount
    Get-AzureRmResourceProvider -ListAvailable
  • Azure-кли Изменение Azure кли режим arm затем запустить azure provider list

Вот полный список типов ресурсов:

ProviderNamespace      RegistrationState ResourceTypes             
-----------------      ----------------- -------------             
Microsoft.ApiManagement    Registered  {service, validateServiceName, checkServiceNameAvailability... 
Microsoft.AppService     Registered  {apiapps, appIdentities, gateways, deploymenttemplates...}  
Microsoft.Automation     Registered  {automationAccounts, automationAccounts/runbooks, automatio... 
Microsoft.Batch      Registered  {batchAccounts, operations, locations, locations/quotas}  
Microsoft.Cache      Registered  {Redis, locations, locations/operationResults, checkNameAva... 
Microsoft.Cdn       Registered  {profiles, profiles/endpoints, profiles/endpoints/origins, ... 
Microsoft.ClassicCompute    Registered  {domainNames, checkDomainNameAvailability, domainNames/slot... 
Microsoft.ClassicNetwork    Registered  {virtualNetworks, reservedIps, quotas, gatewaySupportedDevi... 
Microsoft.ClassicStorage    Registered  {storageAccounts, quotas, checkStorageAccountAvailability, ... 
Microsoft.CognitiveServices   Registered  {accounts}              
Microsoft.Compute      Registered  {availabilitySets, virtualMachines, virtualMachines/extensi... 
Microsoft.DataFactory     Registered  {dataFactories, dataFactories/diagnosticSettings, dataFacto... 
Microsoft.Devices      Registered  {checkNameAvailability, operations, IotHubs}     
Microsoft.DocumentDB     Registered  {databaseAccounts, databaseAccountNames, operations}   
Microsoft.EventHub      Registered  {namespaces, checkNamespaceAvailability, operations}   
Microsoft.HDInsight     Registered  {clusters, clusters/operationresults, locations}    
microsoft.insights      Registered  {components, webtests, queries, logprofiles...}    
Microsoft.KeyVault      Registered  {vaults, vaults/secrets, operations}       
Microsoft.MachineLearning    Registered  {Workspaces, locations, locations/operations, locations/ope... 
Microsoft.Media      Registered  {mediaservices, operations, checknameavailability}    
Microsoft.MobileEngagement    Registered  {appcollections, appcollections/apps, checkappcollectionnam... 
Microsoft.Network      Registered  {virtualNetworks, publicIPAddresses, networkInterfaces, loa... 
Microsoft.NotificationHubs    Registered  {namespaces, namespaces/notificationHubs, checkNamespaceAva... 
Microsoft.OperationalInsights   Registered  {workspaces, storageInsightConfigs, linkTargets, operations} 
Microsoft.PowerBI      Registered  {workspaceCollections, locations, locations/checkNameAvaila... 
Microsoft.ResourceHealth    Registered  {availabilityStatuses}           
Microsoft.Scheduler     Registered  {jobcollections, operations, operationResults, flows}   
Microsoft.Search      Registered  {searchServices, checkServiceNameAvailability, checkNameAva... 
Microsoft.ServiceBus     Registered  {namespaces, checkNamespaceAvailability, premiumMessagingRe... 
Microsoft.SiteRecovery     Registered  {SiteRecoveryVault}           
Microsoft.Sql       Registered  {operations, locations, locations/capabilities, checkNameAv... 
Microsoft.Storage      Registered  {storageAccounts, operations, usages, checkNameAvailability... 
Microsoft.StreamAnalytics    Registered  {streamingjobs, locations, locations/quotas, streamingjobs/... 
microsoft.visualstudio     Registered  {account, account/project}          
Microsoft.Web       Registered  {sites/extensions, sites/slots/extensions, sites/instances,... 
Sendgrid.Email       Registered  {accounts}              
SuccessBricks.ClearDB     Registered  {databases, clusters}           
Aspera.Transfers      NotRegistered  {services, operations, listCommunicationPreference, updateC... 
Citrix.Cloud       NotRegistered  {accounts, operations, listCommunicationPreference, updateC... 
Conexlink.MyCloudIT     NotRegistered  {accounts, operations, listCommunicationPreference, updateC... 
Hive.Streaming       NotRegistered  {services, operations, listCommunicationPreference, updateC... 
Lombiq.DotNest       NotRegistered  {sites, operations, listCommunicationPreference, updateComm... 
Microsoft.ADHybridHealthService  Registered  {services, addsservices, configuration, operations...}   
Microsoft.Authorization    Registered  {roleAssignments, roleDefinitions, classicAdministrators, p... 
Microsoft.BingMaps      NotRegistered  {mapApis, operations, listCommunicationPreference, updateCo... 
Microsoft.BizTalkServices    NotRegistered  {BizTalk}              
Microsoft.CertificateRegistration  NotRegistered  {certificateOrders, certificateOrders/certificates, validat... 
Microsoft.ClassicInfrastructureMigrate NotRegistered  {classicInfrastructureResources}        
Microsoft.ContainerService    NotRegistered  {containerServices, locations, locations/operations, operat... 
Microsoft.ContentModerator    NotRegistered  {applications, operations, listCommunicationPreference, upd... 
Microsoft.DataCatalog     NotRegistered  {catalogs, checkNameAvailability, operations, locations...} 
Microsoft.DataLakeAnalytics   NotRegistered  {operations}             
Microsoft.DataLakeStore    NotRegistered  {operations}             
Microsoft.DevTestLab     NotRegistered  {labs, labs/virtualMachines, operations, locations...}   
Microsoft.DomainRegistration   NotRegistered  {domains, domains/domainOwnershipIdentifiers, topLevelDomai... 
Microsoft.DynamicsLcs     NotRegistered  {lcsprojects, lcsprojects/connectors, lcsprojects/clouddepl... 
Microsoft.Features      Registered  {features, providers, operations}        
Microsoft.Logic      NotRegistered  {workflows, locations/workflows, locations, operations...}  
Microsoft.MarketplaceOrdering   NotRegistered  {agreements, operations}          
Microsoft.OperationsManagement   NotRegistered  {solutions}             
Microsoft.RecoveryServices    NotRegistered  {vaults, operations}           
Microsoft.Resources     Registered  {tenants, locations, providers, checkresourcename...}   
Microsoft.Security      NotRegistered  {securityStatus, securityStatuses, securityStatus/virtualMa... 
Microsoft.ServerManagement    NotRegistered  {operations, gateways, nodes}         
Microsoft.ServiceFabric    NotRegistered  {clusters}              
microsoft.support      Registered  {operations, supporttickets}         
NewRelic.APM       NotRegistered  {accounts}              
Pokitdok.Platform      NotRegistered  {services, operations, listCommunicationPreference, updateC... 
RavenHq.Db        NotRegistered  {databases, operations, listCommunicationPreference, update... 
Raygun.CrashReporting     NotRegistered  {apps, operations, listCommunicationPreference, updateCommu... 
Signiant.Flight      NotRegistered  {accounts, operations, listCommunicationPreference, updateC... 
TrendMicro.DeepSecurity    NotRegistered  {accounts, operations, listCommunicationPreference, updateC... 
U2uconsult.TheIdentityHub    NotRegistered  {services, operations, listCommunicationPreference, updateC... 

Для получения дополнительной информации см. https://azure.microsoft.com/en-us/documentation/articles/resource-manager-supported-services/.

+0

Так что это список всех типов ресурсов? Честно говоря, это не отвечает на мой вопрос, потому что я до сих пор не знаю, какой из этих типов поддерживает вызовы, которые я хочу сделать. Этими вызовами являются: https://management.azure.com/_resource_/metricDefinitions https://management.azure.com/_resource_/metrics – Woozar

+0

Фактически, ссылка, которую я опубликовал, наконец, привела все пары поддерживаемых типов и ресурсов. И столбец ** REST API ** в каждой таблице указывает на подробное использование каждого типа ресурса. –