Todos os produtos
Search
Central de documentação

Resource Orchestration Service:ALIYUN::CMS::SlsGroup

Última atualização: Jun 27, 2026

Cria um grupo de Logstore para métricas de log do Simple Log Service (SLS) no CloudMonitor.

Sintaxe

{
  "Type": "ALIYUN::CMS::SlsGroup",
  "Properties": {
    "SlsGroupDescription": String,
    "SlsGroupConfig": List,
    "SlsGroupName": String
  }
}

Propriedades

Propriedade

Tipo

Obrigatória

Editável

Descrição

Restrição

SlsGroupConfig

List

Sim

Não

Configurações do grupo de Logstore.

Limite de 25 configurações.

Para mais informações, consulte Propriedades de SlsGroupConfig.

SlsGroupName

String

Sim

Não

Nome do grupo de Logstore.

Nenhuma.

SlsGroupDescription

String

Não

Sim

Descrição do grupo de Logstore.

Nenhuma.

Sintaxe de SlsGroupConfig

"SlsGroupConfig": [
  {
    "SlsProject": String,
    "SlsRegion": String,
    "SlsUserId": String,
    "SlsLogstore": String
  }
]

Propriedades de SlsGroupConfig

Propriedade

Tipo

Obrigatória

Editável

Descrição

Restrição

SlsLogstore

String

Sim

Não

O Logstore.

Nenhuma.

SlsProject

String

Sim

Não

Projeto do Simple Log Service.

Nenhuma.

SlsRegion

String

Sim

Não

ID da região.

Nenhuma.

SlsUserId

String

Não

Sim

ID do membro.

Se você usar ALIYUN::CMS::SlsGroup com a conta de gerenciamento de um diretório de recursos, poderá conectar os serviços da Alibaba Cloud ativados para um membro do diretório ao Hybrid Cloud Monitoring. Esse recurso permite o monitoramento entre contas dos serviços da Alibaba Cloud em contas corporativas.

Valores de retorno

Fn::GetAtt

  • SlsGroupDescription: descrição do grupo de Logstore.

  • SlsGroupConfig: configurações do grupo de Logstore.

  • CreateTime: hora de criação do grupo de Logstore.

  • SlsGroupName: nome do grupo de Logstore.

Exemplos

Formato YAML

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  SlsGroupConfig:
    AssociationPropertyMetadata:
      Parameters:
        SlsProject:
          Type: String
          Description:
            en: The Simple Log Service project.
          Required: true
        SlsRegion:
          Type: String
          Description:
            en: The region ID.
          Required: true
        SlsUserId:
          Type: String
          Description:
            en: The member ID. If you call this operation by using the management account of a resource directory, you can connect the Alibaba Cloud services that are activated for all members in the resource directory to Hybrid Cloud Monitoring. You can use the resource directory to monitor Alibaba Cloud services across enterprise accounts.Note If a member uses CloudMonitor for the first time, you must make sure that the service-linked role AliyunServiceRoleForCloudMonitor is attached to the member. For more information, see Manage the service-linked role for CloudMonitor.
          Required: false
        SlsLogstore:
          Type: String
          Description:
            en: The Logstore.
          Required: true
    AssociationProperty: List[Parameters]
    Type: Json
    Description:
      en: 'The configurations of the Logstore group.Valid values of N: 1 to 25.'
    Required: true
  SlsGroupName:
    Type: String
    Description:
      en: The name of the Logstore group.The name must be 2 to 32 characters in length and can contain uppercase letters, lowercase letters, digits, and underscores (_). The name must start with a letter.
    Required: true
Resources:
  ExtensionResource:
    Type: ALIYUN::CMS::SlsGroup
    Properties:
      SlsGroupConfig:
        Ref: SlsGroupConfig
      SlsGroupName:
        Ref: SlsGroupName
Outputs:
  SlsGroupDescription:
    Description: The description of the Logstore group.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - SlsGroupDescription
  SlsGroupConfig:
    Description: The configurations of the Logstore group.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - SlsGroupConfig
  CreateTime:
    Description: The creation time of the Logstore group.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CreateTime
  SlsGroupName:
    Description: The name of the Logstore group.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - SlsGroupName

Formato JSON

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "SlsGroupConfig": {
      "AssociationPropertyMetadata": {
        "Parameters": {
          "SlsProject": {
            "Type": "String",
            "Description": {
              "en": "The Simple Log Service project."
            },
            "Required": true
          },
          "SlsRegion": {
            "Type": "String",
            "Description": {
              "en": "The region ID."
            },
            "Required": true
          },
          "SlsUserId": {
            "Type": "String",
            "Description": {
              "en": "The member ID. If you call this operation by using the management account of a resource directory, you can connect the Alibaba Cloud services that are activated for all members in the resource directory to Hybrid Cloud Monitoring. You can use the resource directory to monitor Alibaba Cloud services across enterprise accounts.Note If a member uses CloudMonitor for the first time, you must make sure that the service-linked role AliyunServiceRoleForCloudMonitor is attached to the member. For more information, see Manage the service-linked role for CloudMonitor."
            },
            "Required": false
          },
          "SlsLogstore": {
            "Type": "String",
            "Description": {
              "en": "The Logstore."
            },
            "Required": true
          }
        }
      },
      "AssociationProperty": "List[Parameters]",
      "Type": "Json",
      "Description": {
        "en": "The configurations of the Logstore group.Valid values of N: 1 to 25."
      },
      "Required": true
    },
    "SlsGroupName": {
      "Type": "String",
      "Description": {
        "en": "The name of the Logstore group.The name must be 2 to 32 characters in length and can contain uppercase letters, lowercase letters, digits, and underscores (_). The name must start with a letter."
      },
      "Required": true
    }
  },
  "Resources": {
    "ExtensionResource": {
      "Type": "ALIYUN::CMS::SlsGroup",
      "Properties": {
        "SlsGroupConfig": {
          "Ref": "SlsGroupConfig"
        },
        "SlsGroupName": {
          "Ref": "SlsGroupName"
        }
      }
    }
  },
  "Outputs": {
    "SlsGroupDescription": {
      "Description": "The description of the Logstore group.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "SlsGroupDescription"
        ]
      }
    },
    "SlsGroupConfig": {
      "Description": "The configurations of the Logstore group.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "SlsGroupConfig"
        ]
      }
    },
    "CreateTime": {
      "Description": "The creation time of the Logstore group.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CreateTime"
        ]
      }
    },
    "SlsGroupName": {
      "Description": "The name of the Logstore group.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "SlsGroupName"
        ]
      }
    }
  }
}