Consulta os gatilhos de uma função do Function Compute.
Sintaxe
{
"Type": "DATASOURCE::FC::Triggers",
"Properties": {
"FunctionName": String,
"ServiceName": String,
"Prefix": String,
"RefreshOptions": String
}
}
Propriedades
|
Propriedade |
Tipo |
Obrigatória |
Editável |
Descrição |
Restrição |
|
FunctionName |
String |
Sim |
Sim |
Nome da função. |
Nenhuma. |
|
ServiceName |
String |
Sim |
Sim |
Nome do serviço. |
Nenhuma. |
|
Prefix |
String |
Não |
Sim |
Prefixo do nome do recurso. |
O nome do recurso deve começar com o valor desta propriedade. Por exemplo, se você defina Prefix como a, os nomes dos recursos retornados terão o prefixo a. |
|
RefreshOptions |
String |
Não |
Sim |
Política de atualização dos recursos da fonte de dados durante a atualização da pilha. |
Valores válidos:
|
Valores de retorno (Fn::GetAtt)
TriggerNames: nomes dos gatilhos.
Triggers: detalhes dos gatilhos.
|
Propriedade |
Tipo |
Descrição |
Restrição |
|
TriggerNames |
List |
Nomes dos gatilhos. |
Nenhuma. |
|
Triggers |
List |
Detalhes dos gatilhos. |
Nenhuma. |
|
TriggerName |
String |
Nome do gatilho. |
Nenhuma. |
|
TriggerId |
String |
ID do gatilho. |
Nenhuma. |
|
TriggerConfig |
String |
Configuração do gatilho. |
Nenhuma. |
|
TriggerType |
String |
Tipo do gatilho. |
Valores válidos:
|
|
Description |
String |
Descrição do gatilho. |
Nenhuma. |
|
InvocationRole |
String |
Função do Resource Access Management (RAM) usada pela fonte de eventos, como o OSS, para invocar a função. |
Para mais informações, consulte Visão geral de gatilhos. |
|
CreatedTime |
String |
Hora de criação do gatilho. |
Nenhuma. |
|
LastModifiedTime |
String |
Hora da última modificação do gatilho. |
Nenhuma. |
|
Qualifier |
String |
Versão do serviço. |
Para mais informações, consulte Gerenciar versões. |
|
SourceArn |
String |
Alibaba Cloud Resource Name (ARN) da source de eventos do gatilho. |
Nenhuma. |
|
DomainName |
String |
Nome de domínio. |
Nenhuma. |
Exemplos
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"FunctionName": {
"Type": "String",
"Description": "Function name."
},
"ServiceName": {
"Type": "String",
"Description": "Service name."
}
},
"Resources": {
"Triggers": {
"Type": "DATASOURCE::FC::Triggers",
"Properties": {
"FunctionName": {
"Ref": "FunctionName"
},
"ServiceName": {
"Ref": "ServiceName"
}
}
}
},
"Outputs": {
"TriggerNames": {
"Description": "The list of trigger names.",
"Value": {
"Fn::GetAtt": [
"Triggers",
"TriggerNames"
]
}
},
"Triggers": {
"Description": "The list of triggers.",
"Value": {
"Fn::GetAtt": [
"Triggers",
"Triggers"
]
}
}
}
}
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
FunctionName:
Type: String
Description: Function name.
ServiceName:
Type: String
Description: Service name.
Resources:
Triggers:
Type: DATASOURCE::FC::Triggers
Properties:
FunctionName:
Ref: FunctionName
ServiceName:
Ref: ServiceName
Outputs:
TriggerNames:
Description: The list of trigger names.
Value:
Fn::GetAtt:
- Triggers
- TriggerNames
Triggers:
Description: The list of triggers.
Value:
Fn::GetAtt:
- Triggers
- Triggers