Creates a function rule.
Debugging
Authorization information
Request syntax
PUT /2021-04-06/services/{serviceName}/functions/{functionName}/on-demand-config
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
serviceName | string | Yes | The name of the service. | demo-service |
functionName | string | Yes | The name of the function. | demo-function |
qualifier | string | Yes | The service alias or latest version. Other versions are not supported. | prod |
body | object | No | The request body. | |
maximumInstanceCount | long | Yes | The maximum number of on-demand instances. For more information, see Configure provisioned instances and auto scaling rules. | 10 |
If-Match | string | No | If the ETag specified in the request matches the ETag value of the object, the object and 200 OK are returned. Otherwise, 412 Precondition Failed is returned. | e19d5cd5af0378da05f63f891c7467af |
X-Fc-Account-Id | string | No | The ID of your Alibaba Cloud account. | 188077086902**** |
X-Fc-Date | string | No | The time when the function is invoked. The value is in the EEE,d MMM yyyy HH:mm:ss GMT format. | Wed, 11 May 2022 09:00:00 GMT |
X-Fc-Trace-Id | string | No | The unique ID of the trace. | r9s89isisi**** |
Response parameters
Examples
Sample success responses
JSON
format
{
"resource": "12345#servierName#qualifier#functionName",
"maximumInstanceCount": 10
}
Error codes
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
2021-06-30 | The internal configuration of the API is changed, but the call is not affected | see changesets | ||||||||||||||
| ||||||||||||||||
2021-06-30 | The request parameters of the API has changed | see changesets | ||||||||||||||
| ||||||||||||||||
2021-06-30 | The request parameters of the API has changed | see changesets | ||||||||||||||
| ||||||||||||||||
2021-06-30 | The request parameters of the API has changed | see changesets | ||||||||||||||
|