DATASOURCE::ARMS::Prometheis类型用于查询Prometheus实例。
语法
{
  "Type": "DATASOURCE::ARMS::Prometheis",
  "Properties": {
    "ResourceGroupId": String,
    "RefreshOptions": String
  }
}属性
| 属性名称 | 类型 | 必须 | 允许更新 | 描述 | 约束 | 
| ResourceGroupId | String | 否 | 是 | 资源组ID。 | 无 | 
| RefreshOptions | String | 否 | 是 | 当资源栈更新时,数据源资源的刷新策略。 | 有效值: 
 | 
返回值
Fn::GetAtt
- Prometheis:Prometheus实例列表。 
- ClusterIds:Prometheus实例ID列表。 
| 属性名称 | 类型 | 描述 | 约束 | 
| ClusterIds | List | Prometheus实例ID列表。 | 无 | 
| Prometheis | List | Prometheus实例列表。 | 无 | 
| RegionId | String | 地域ID。 | 无 | 
| PaymentType | String | 付费类型。 | 无 | 
| PrometheusName | String | 实例名称。 | 无 | 
| UserId | String | 用户ID。 | 无 | 
| ClusterId | String | Prometheus实例ID。 | 无 | 
| ClusterType | String | Prometheus实例类型。 | 无 | 
| ResourceGroupId | String | Prometheus实例的资源组ID。 | 无 | 
| Tags | List | 标签列表。 | 无 | 
| VSwitchId | String | 交换机ID。 | 无 | 
| GrafanaInstanceId | String | Grafana工作区ID。 | 无 | 
| SecurityGroupId | String | 安全组ID。 | 无 | 
| SubClustersJson | String | globalView实例的子实例JSON串。 | 无 | 
| VpcId | String | VPC ID。 | 无 | 
示例
YAML格式
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  ResourceGroupId:
    Description:
      en: The ID of the resource group.
    Type: String
Resources:
  ExtensionDataSource:
    Properties:
      ResourceGroupId:
        Ref: ResourceGroupId
    Type: DATASOURCE::ARMS::Prometheis
Outputs:
  ClusterIds:
    Description: The list of cluster IDs.
    Value:
      Fn::GetAtt:
      - ExtensionDataSource
      - ClusterIds
  Prometheis:
    Description: The list of Prometheus.
    Value:
      Fn::GetAtt:
      - ExtensionDataSource
      - Prometheis
                        JSON格式
                        {
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "ResourceGroupId": {
      "Type": "String",
      "Description": {
        "en": "The ID of the resource group."
      }
    }
  },
  "Resources": {
    "ExtensionDataSource": {
      "Type": "DATASOURCE::ARMS::Prometheis",
      "Properties": {
        "ResourceGroupId": {
          "Ref": "ResourceGroupId"
        }
      }
    }
  },
  "Outputs": {
    "Prometheis": {
      "Description": "The list of Prometheis.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionDataSource",
          "Prometheis"
        ]
      }
    },
    "ClusterIds": {
      "Description": "The list of cluster IDs.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionDataSource",
          "ClusterIds"
        ]
      }
    }
  }
}
                        该文章对您有帮助吗?