Modifies the configurations of an ApsaraMQ for Kafka instance. ApsaraMQ for Kafka allows you to modify the configurations of an instance, including the access control list (ACL) feature, the Secure Sockets Layer (SSL) feature, the message retention period, and the maximum message size.
Operation description
Permissions
If a RAM user wants to call the UpdateInstanceConfig operation, the RAM user must be granted the required permissions. For more information about how to grant permissions, see RAM policies.
API | Action | Resource |
---|---|---|
UpdateInstanceConfig | alikafka: UpdateInstance | acs:alikafka:::{instanceId} |
Debugging
Authorization information
The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action
policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:
- Operation: the value that you can use in the Action element to specify the operation on a resource.
- Access level: the access level of each operation. The levels are read, write, and list.
- Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
- The required resource types are displayed in bold characters.
- If the permissions cannot be granted at the resource level,
All Resources
is used in the Resource type column of the operation.
- Condition Key: the condition key that is defined by the cloud service.
- Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
alikafka:UpdateInstance | Write |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
Config | string | Yes | The configurations that you want to update for the ApsaraMQ for Kafka instance. The value must be a valid JSON string. | {"kafka.log.retention.hours":"33"} |
RegionId | string | Yes | The region ID of the instance. | cn-hangzhou |
InstanceId | string | Yes | The instance ID. | alikafka_post-cn-v0h1fgs2**** |
Description of the Config parameter
Parameter | Type | Valid value | Default value | Description |
---|---|---|---|---|
enable.vpc_sasl_ssl | String | "true" : enables virtual private cloud (VPC) transmission encryption. "false" : disables VPC transmission encryption. | "false" | Specifies whether to enable VPC transmission encryption. If VPC transmission encryption is enabled, you must also enable the access control list (ACL) feature. |
enable.acl | String | "true" : enables the ACL feature. "false" : disables the ACL feature. | "false" | Specifies whether to enable the ACL feature. |
kafka.log.retention.hours | String | Only integers in the range of 24 to 480 are supported. | "72" | The retention period of messages. Unit: hours. |
kafka.message.max.bytes | String | Only integers in the range of 1048576 to 10485760 are supported. | "1048576" | The maximum size of a message. Unit: bytes. |
Response parameters
Examples
Sample success responses
JSON
format
{
"Code": 200,
"Message": "operation success.",
"RequestId": "4B6D821D-7F67-4CAA-9E13-A5A997C35***",
"Success": true
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | MissingParameter | The %s parameter is required. | - |
400 | Instance.StatusNotRunning | The instance is not running and cannot operate this function. Please try again later. | The instance is not running and cannot operate this function. Please try again later. |
400 | Instance.Change.NotAllowed | This instance does not allow deployment operations. | - |
400 | InvalidParameter.Format | The %s format is invalid. | - |
400 | InvalidParameter.NotSupport | The %s parameter is not supported. | - |
400 | InvalidParameter | The %s parameter is invalid. | - |
400 | InvalidParameter.VersionNotSupport | Current version does not support the %s parameter. | - |
404 | Instance.NotFound | The instance does not exist. Please verify the entry and try again. | The instance does not exist. Please verify the entry and try again. |
500 | InternalError | An internal error occurred. Please try again later. | - |
500 | InternalError | A system exception occurred. Please submit a ticket. | - |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||
---|---|---|---|---|---|---|---|---|---|---|
2024-03-20 | The Error code has changed | see changesets | ||||||||
|