Todos os produtos
Search
Central de documentação

Database Autonomy Service:DescribeCloudBenchTasks

Última atualização: Jun 28, 2026

Você pode chamar a operação DescribeCloudBenchTasks para consultar tarefas de teste de estresse.

Descrição da operação

O Database Autonomy Service (DAS) fornece um recurso de teste de estresse inteligente que ajuda você a determinar se deve escalar horizontalmente sua instância para lidar com picos de tráfego de serviço. Para mais informações, consulte Teste de estresse inteligente.

Experimente agora

Experimente esta API no OpenAPI Explorer, sem necessidade de assinatura manual. Chamadas bem-sucedidas geram automaticamente código SDK correspondente aos seus parâmetros. Faça o download com segurança de credenciais integrada para uso local.

Testar

Autorização RAM

A tabela abaixo descreve a autorização necessária para chamar esta API. Você pode defini-la em uma política do Resource Access Management (RAM). As colunas da tabela estão detalhadas abaixo:

  • Ação: As ações que podem ser usadas no elemento Action das instruções de política de permissão do RAM para conceder permissões para executar a operação.

  • API: A API que você pode chamar para executar a ação.

  • Nível de acesso: O nível de acesso predefinido concedido para cada API. Valores válidos: create, list, get, update e delete.

  • Tipo de recurso: O tipo de recurso que suporta autorização para executar a ação. Indica se a ação suporta permissão em nível de recurso. O recurso especificado deve ser compatível com a ação. Caso contrário, a política será ineficaz.

    • Para APIs com permissões em nível de recurso, os tipos de recursos obrigatórios são marcados com um asterisco (*). Especifique o Nome de Recurso Alibaba Cloud (ARN) correspondente no elemento Resource da política.

    • Para APIs sem permissões em nível de recurso, é exibido como Todos os Recursos. Use um asterisco (*) no elemento Resource da política.

  • Chave de condição: As chaves de condição definidas pelo serviço. A chave permite controle granular, aplicando-se somente a ações ou a ações associadas a recursos específicos. Além das chaves de condição específicas do serviço, o Alibaba Cloud fornece um conjunto de chaves de condição comuns aplicáveis a todos os serviços compatíveis com RAM.

  • Ação dependente: As ações dependentes necessárias para executar a ação. Para concluir a ação, o usuário RAM ou a função RAM deve ter permissões para executar todas as ações dependentes.

Ação

Nível de acesso

Tipo de recurso

Chave de condição

Ação dependente

hdm:DescribeCloudBenchTasks

get

*All Resource

*

Nenhuma Nenhuma

Parâmetros da solicitação

Parâmetro

Tipo

Obrigatório

Descrição

Exemplo

Status

string

Não

O status da tarefa. Valores válidos:

  • SUCCESS: A tarefa foi concluída com êxito.

  • IGNORED: A tarefa foi ignorada.

  • RUNNING: A tarefa está em execução.

  • EXCEPTION: A tarefa está anormal.

SUCCESS

TaskType

string

Não

O tipo da tarefa de teste de estresse. Valores válidos:

  • pressure test (padrão): Uma tarefa de teste de estresse que reproduz o tráfego capturado da instância de origem na instância de destino na taxa máxima de reprodução suportada pela instância de destino.

  • smart pressure test: Uma tarefa de teste de estresse gerada para realizar testes de estresse contínuos. A tarefa analisa o tráfego capturado de uma instância de origem em um curto período de tempo e gera tráfego semelhante ao tráfego da instância de origem em termos de modelo de negócios e distribuição de tráfego. Isso reduz o tempo necessário para coletar dados da instância de origem e diminui os custos de armazenamento e desempenho.

pressure test

StartTime

string

Não

O início do intervalo de tempo a ser consultado. Esse valor é um timestamp UNIX que representa o número de milissegundos decorridos desde 1º de janeiro de 1970, 00:00:00 UTC.

1596177993000

EndTime

string

Não

O fim do intervalo de tempo a ser consultado. Esse valor é um timestamp UNIX que representa o número de milissegundos decorridos desde 1º de janeiro de 1970, 00:00:00 UTC.

Nota

O horário de término deve ser posterior ao horário de início.

1596177993001

PageNo

string

Não

O número da página. O valor deve ser um número inteiro positivo. Valor padrão: 1.

1

PageSize

string

Não

O número de entradas a serem retornadas por página. O valor deve ser um número inteiro positivo. Valor padrão: 10.

10

Elementos de resposta

Elemento

Tipo

Descrição

Exemplo

object

The response parameters.

Code

string

O código de status HTTP retornado.

200

Message

string

Os dados retornados.

Nota

Se a solicitação for bem-sucedida, Successful será retornado. Se a solicitação falhar, uma mensagem de erro, como um código de erro, será retornada.

Successful

RequestId

string

O ID da solicitação.

B6D17591-B48B-4D31-9CD6-9B9796B2****

Success

string

Indica se a solicitação foi bem-sucedida. Valores válidos:

  • true: A solicitação foi bem-sucedida.

  • false: A solicitação falhou.

true

Data

object

As informações detalhadas, incluindo o número total de entradas retornadas e os códigos de erro.

PageNo

integer

O número da página.

1

PageSize

integer

O número de entradas retornadas por página.

10

Extra

string

O parâmetro reservado.

None

Total

integer

O número total de entradas retornadas.

2

List

object

cloudbenchTasks

array<object>

The detailed information about the stress testing tasks.

object

DtsJobName

string

The name of the DTS task.

RDS间迁移

ErrorMessage

string

The error message returned if the task fails.

DTS-070211: Connect Source DB failed. cause by [com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException:Could not create connection to database server. Attempted reconnect 3 times. Giving up.][com.mysql.jdbc.exceptions.jdbc4.CommunicationsException:Communications link failure\n\nThe last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.][java.net.ConnectException:Connection timed out (Connection timed out)] About more information in [https://yq.aliyun.com/articles/499178].

External

string

The additional information.

Null

BackupType

string

The backup type. Valid values:

  • TIMESTAMP: backup by time.

  • BACKUPID: backup by backup set ID.

TIMESTAMP

UserId

string

The ID of the Alibaba Cloud account.

1091411816252****

DstType

string

The type of the destination instance. Valid values:

  • Instance (default): an instance that is specified by its ID.

  • ConnectionString: an instance that is specified by its endpoint.

Instance

EcsInstanceId

string

The ID of the ECS instance.

i-bp1ecr5go2go1****

DstInstanceUuid

string

The unique ID of the destination instance.

hdm_d887b5ccf99fa0dc9a1e5aaac368****

TaskType

string

The type of the stress testing task. Valid values:

  • pressure test (default): A stress testing task that replays the traffic captured from the source instance on the destination instance at the maximum playback rate that is supported by the destination instance.

  • smart pressure test: A stress testing task that is generated to perform continuous stress testing. The task analyzes the traffic that is captured from a source instance in a short period of time and generates traffic that is similar to the traffic on the source instance in terms of business model and traffic distribution. This reduces the time that is required to collect data from the source instance and lowers the costs of storage and performance.

pressure test

BenchStep

string

The sub-step of the stress testing task. Valid values:

  • NEW: The task is being initialized.

  • WAIT_BUY_ECS: An ECS instance is being purchased.

  • WAIT_START_ECS: The ECS instance is being started.

  • WAIT_INSTALL_JDK: JDK is being installed.

  • WAIT_INSTALL_DBGATEWAY: A DBGateway is being installed.

  • ADD_SECURITY_IPS_STEP: A whitelist is being configured for the security group.

  • ARCHIVE: Full SQL data is being archived.

  • DOWNLOAD: The full SQL file is being downloaded.

  • PROCEED: The full SQL file is being pre-processed.

  • PRE_LOAD: The full SQL file is being preloaded.

  • VALIDATE: The feature is being validated.

  • PRESSURE: Performance is being tested.

PROCEED

Version

string

The version of the stress testing task. Valid values:

  • V2.0

  • V3.0

V3.0

EndState

string

The state of the stress testing task after it is complete. Valid values:

  • WAIT_TARGET: The destination instance for stress testing is being prepared.

  • WAIT_DBGATEWAY: The stress testing deployment is being prepared.

  • WAIT_SQL: Full SQL data is being prepared.

  • WAIT_LOGIC: The traffic playback is being prepared.

Nota

After the stress testing task enters the state specified by the EndState parameter, the task becomes complete.

WAIT_TARGET

SrcInstanceUuid

string

The unique ID of the source instance.

hdm_3063db6792965c080a4bcb6e6304****

ClientType

string

The type of the stress testing client. Valid values:

  • ECS: You must prepare a database gateway.

  • DAS_ECS: DAS automatically purchases and deploys an ECS instance.

ECS

State

string

The state of the stress testing task. Valid values:

  • WAIT_TARGET: The destination instance for stress testing is being prepared.

  • WAIT_DBGATEWAY: The stress testing deployment is being prepared.

  • WAIT_SQL: Full SQL data is being prepared.

  • WAIT_LOGIC: The traffic playback is being prepared.

WAIT_TARGET

DstIp

string

The reserved parameter.

None

SrcPublicIp

string

The reserved parameter.

None

BackupId

string

The backup set ID. You can call the DescribeBackups operation to query the backup list.

229132

SqlCompleteReuse

string

The information about the full SQL statements that are reused.

{"sqlUuid":"task_a37d2f07-45cb-4413-a2a6-c66c68****","metaUuid":"task_211e2561-5c0c-486b-864c-56b511****","sqlFile":"cl-1620057600000-1800626.sc","metaFile":"cl-1620057600000-1800626.meta"}

SmartPressureTime

integer

The duration of the generated stress testing task. Unit: milliseconds.

86400000

ArchiveState

integer

The status of SQL data archiving. Valid values:

  • 0: Not started.

  • 1: Complete.

  • 2: Error.

  • 3: Running.

  • 4: No download required.

1

Status

string

The status of the stress testing task. Valid values:

  • SUCCESS: The task is successful.

  • IGNORED: The task is ignored.

  • RUNNING: The task is running.

  • EXCEPTION: The task is abnormal.

RUNNING

WorkDir

string

The temporary directory generated for stress testing.

/tmp/bench/

ArchiveOssTableName

string

The name of the table to which data is archived in OSS.

custins15546355_161604665****

DtsJobId

string

The ID of the DTS data migration task.

i03e3zty16i****

DtsJobState

integer

The status of the DTS task. Valid values:

  • NOT_STARTED: The task is not started.

  • PRE_CHECKING: The task is in precheck.

  • PRE_CHECK_FAILED: The precheck failed.

  • CHECKING: The task is being checked.

  • MIGRATING: The task is in progress.

  • CATCHED: The destination instance has caught up with the source instance.

  • SUSPENDING: The task is paused.

  • MIGRATION_FAILED: The migration failed.

  • FINISHED: The task is complete.

  • INITIALIZING: The task is in initial synchronization.

  • INITIALIZE_FAILED: The initial synchronization failed.

  • SYNCHRONIZING: The task is in synchronization.

  • MODIFYING: The synchronization object is being changed.

  • SWITCHING: The task is being switched.

  • FAILED: The task failed.

CHECKING

DstPort

integer

The port number of the destination instance.

3306

DtsJobClass

string

The specifications of the DTS task.

Nota

For more information about the specifications and performance of data migration tasks, see Specifications of data migration tasks.

medium

ClientGatewayId

string

The ID of the database gateway for the stress testing client.

58598b2af48a0193dfc16fc6964ef****

Description

string

The description of the stress testing task.

test-das-bench-0501

ErrorCode

string

The error code returned for the internal stress testing task.

10109

TableSchema

string

The names of the tables that are involved in the stress testing.

[{"TABLE_NAME":"customer1","TABLE_SCHEMA":"tpcc"}]

DtsJobStatus

string

The status of the DTS task. Valid values:

  • NOT_STARTED: The task is not started.

  • PRE_CHECKING: The task is in precheck.

  • PRE_CHECK_FAILED: The precheck failed.

  • CHECKING: The task is being checked.

  • MIGRATING: The task is in progress.

  • CATCHED: The destination instance has caught up with the source instance.

  • SUSPENDING: The task is paused.

  • MIGRATION_FAILED: The migration failed.

  • FINISHED: The task is complete.

  • INITIALIZING: The task is in initial synchronization.

  • INITIALIZE_FAILED: The initial synchronization failed.

  • SYNCHRONIZING: The task is in synchronization.

  • MODIFYING: The synchronization object is being changed.

  • SWITCHING: The task is being switched.

  • FAILED: The task failed.

PRE_CHECK_FAILED

SrcInstanceArea

string

The database type of the source instance.

RDS

BenchStepStatus

string

The status of the stress testing sub-step. Valid values:

  • NEW: The task is being initialized.

  • RUNNING: The task is running.

  • FAILED: The task failed.

  • FINISHED: The task is complete.

  • Terminated: The task is terminated.

  • Deleted: The task is deleted.

FINISHED

Source

string

The source of the task. Valid values:

  • DAS

  • OPEN_API

DAS

ArchiveJobId

string

The ID of the data archiving task.

'202105211430070112231480820340758****

Topic

string

The consumer topic in Kafka.

das

RequestDuration

integer

The duration of the stress testing task. Unit: milliseconds.

86400000

TaskId

string

The task ID.

e5cec704-0518-430f-8263-76f4dcds****

Rate

integer

The playback rate of the traffic from the source instance on the destination instance. The playback rate must be a positive integer. Valid values: 0 to 30. Default value: 1.

1

Exemplos

Resposta de sucesso

JSON formato

{
  "Code": "200",
  "Message": "Successful",
  "RequestId": "B6D17591-B48B-4D31-9CD6-9B9796B2****",
  "Success": "true",
  "Data": {
    "PageNo": 1,
    "PageSize": 10,
    "Extra": "None",
    "Total": 2,
    "List": {
      "cloudbenchTasks": [
        {
          "DtsJobName": "RDS间迁移",
          "ErrorMessage": "DTS-070211: Connect Source DB failed. cause by [com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException:Could not create connection to database server. Attempted reconnect 3 times. Giving up.][com.mysql.jdbc.exceptions.jdbc4.CommunicationsException:Communications link failure\\n\\nThe last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.][java.net.ConnectException:Connection timed out (Connection timed out)] About more information in [https://yq.aliyun.com/articles/499178].",
          "External": "Null",
          "BackupType": "TIMESTAMP",
          "UserId": "1091411816252****",
          "DstType": "Instance",
          "EcsInstanceId": "i-bp1ecr5go2go1****",
          "DstInstanceUuid": "hdm_d887b5ccf99fa0dc9a1e5aaac368****",
          "TaskType": "pressure test",
          "BenchStep": "PROCEED",
          "Version": "V3.0",
          "EndState": "WAIT_TARGET",
          "SrcInstanceUuid": "hdm_3063db6792965c080a4bcb6e6304****",
          "ClientType": "ECS",
          "State": "WAIT_TARGET",
          "DstIp": "None",
          "SrcPublicIp": "None",
          "BackupId": "229132",
          "SqlCompleteReuse": "{\"sqlUuid\":\"task_a37d2f07-45cb-4413-a2a6-c66c68****\",\"metaUuid\":\"task_211e2561-5c0c-486b-864c-56b511****\",\"sqlFile\":\"cl-1620057600000-1800626.sc\",\"metaFile\":\"cl-1620057600000-1800626.meta\"}",
          "SmartPressureTime": 86400000,
          "ArchiveState": 1,
          "Status": "RUNNING",
          "WorkDir": "/tmp/bench/",
          "ArchiveOssTableName": "custins15546355_161604665****",
          "DtsJobId": "i03e3zty16i****",
          "DtsJobState": 0,
          "DstPort": 3306,
          "DtsJobClass": "medium",
          "ClientGatewayId": "58598b2af48a0193dfc16fc6964ef****",
          "Description": "test-das-bench-0501",
          "ErrorCode": "10109",
          "TableSchema": "[{\"TABLE_NAME\":\"customer1\",\"TABLE_SCHEMA\":\"tpcc\"}]",
          "DtsJobStatus": "PRE_CHECK_FAILED",
          "SrcInstanceArea": "RDS",
          "BenchStepStatus": "FINISHED",
          "Source": "DAS",
          "ArchiveJobId": "'202105211430070112231480820340758****",
          "Topic": "das",
          "RequestDuration": 86400000,
          "TaskId": "e5cec704-0518-430f-8263-76f4dcds****",
          "Rate": 1
        }
      ]
    }
  }
}

Códigos de erro

Código de status HTTP

Código de erro

Mensagem de erro

Descrição

400 InvalidParams The request parameters are invalid.
403 NoPermission You are not authorized to do this action.

Consulte Códigos de Erro para uma lista completa.

Notas de versão

Consulte Notas de Versão para uma lista completa.