idCounter: 1884
workflow_id: 150119
nodes:
  - id: __START__
    type: start
    data:
      name: __START__
      inputs:
        - id: '1'
          name: cluster_version
          kind: value
          value: v8.5.4
          type: String
          description: The name of the testbed
          required: true
        - id: '41'
          name: tidbcloud_org_id
          kind: value
          value: '1369847559691397265'
          type: String
          description: ''
          required: true
        - id: '54'
          name: tidbcloud_project_id
          kind: value
          value: '1369847559694040707'
          type: String
          description: ''
          required: true
      outputs:
        - name: cluster_version
          type: String
          description: The name of the testbed
          id: '1791'
        - name: tidbcloud_org_id
          type: String
          description: ''
          id: '1792'
        - name: tidbcloud_project_id
          type: String
          description: ''
          id: '1793'
      spec: {}
    position:
      x: 12
      'y': 79
    measured:
      width: 800
      height: 492
    selected: false
  - id: '10'
    type: testbed_create
    position:
      x: 1086.62248113445
      'y': 17.075503773109972
    data:
      name: tidbcloud_cluster_create
      inputs:
        - id: '1855'
          name: cluster_version
          kind: reference
          value: ''
          type: String
          description: ''
          required: false
          fromOutput:
            node: __START__
            parameter: cluster_version
        - id: '7143'
          name: org_id
          kind: reference
          value: ''
          type: String
          description: ''
          required: false
          fromOutput:
            node: __START__
            parameter: tidbcloud_org_id
        - id: '7144'
          name: project_id
          kind: reference
          value: ''
          type: String
          description: ''
          required: false
          fromOutput:
            node: __START__
            parameter: tidbcloud_project_id
      outputs:
        - name: testbed
          type: Object
          subType: Testbed
          description: Handler of the testbed
          objectSchema:
            type: Object
            description: Handler of the testbed
            properties:
              testbed_name:
                type: String
                description: Name of the testbed
              testbed_items:
                type: Object
                description: Items of the testbed
              resourcepool_name:
                type: String
                description: Resource pool name
          id: '1847'
        - name: testbed.testbed_name
          type: String
          description: Name of the testbed
          id: '1848'
        - name: testbed.testbed_items
          type: Object
          description: Items of the testbed
          id: '1849'
        - name: testbed.resourcepool_name
          type: String
          description: Resource pool name
          id: '1850'
        - name: tc
          type: Object
          subType: TIDBCLOUD_CLUSTER
          description: Handler of the tc
          objectSchema:
            type: Object
            description: Handler of the tc
            properties:
              private_endpoint:
                type: String
                description: Private endpoint
              prometheus_url:
                type: String
                description: Prometheus URL
          id: '1851'
        - name: tc.private_endpoint
          type: String
          description: Private endpoint
          id: '1852'
        - name: tc.prometheus_url
          type: String
          description: Prometheus URL
          id: '1853'
      spec:
        generateName: testbed
        resourcePool: azure-east-us-2
        reclaimPolicy:
          lease: 240h
          gcStrategy:
            onFailure:
              reserveEnv:
                durationOnWorkingHour: 1h
            onSuccess:
              reserveEnv:
                durationOnWorkingHour: 0h
        items:
          - id: '1797'
            name: tc
            type: TIDBCLOUD_CLUSTER
            spec: |-
              accountEmail: testinfra@pingcap.com
              clusterConfig:
                backup:
                  config: {}
                pd:
                  config: {}
                restore:
                  config: {}
                tidb:
                  config: null
                tikv:
                  config: {}
                version: {{.inputs.cluster_version}}
              connect: privatelink
              orgID: "{{.inputs.org_id}}"
              password: "12345678"
              projectID: "{{.inputs.project_id}}"
              provider: azure
              tidb:
                nodeProfileName: 2 vCPU, 8 GiB
                replicas: 1
              tikv:
                nodeProfileName: 2 vCPU, 8 GiB
                replicas: 3
                storageSizeGi: 1500
                storageType: basic
        testPlanTags:
          - service:benchbot
      fastFail: false
    measured:
      width: 695
      height: 628
    selected: false
    dragging: false
  - id: '35'
    type: ti_workload_call
    position:
      x: 2105
      'y': 112.5
    data:
      name: tpcc_5k_prepare
      inputs:
        - id: '36'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          subType: TIDBCLOUD_CLUSTER
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
        - id: '1196'
          name: cluster_version
          kind: reference
          value: ''
          type: String
          description: ''
          required: false
          fromOutput:
            node: __START__
            parameter: cluster_version
      outputs:
        - name: exec_id
          type: String
          description: TiWorkload Execution ID
          id: '1857'
        - name: exec_status
          type: String
          description: TiWorkload Execution Status
          id: '1858'
        - name: exec_tasks
          type: Object
          description: Tasks of the TiWorkload Execution
          id: '1859'
      spec:
        tiworkload_host: https://tiworkload.pingcap.net
        workload_name: ch
        prepare: |-
          params:
            storage_url: |-
              https://testinfraeastus2.blob.core.windows.net/qa-workload-datasets-eastus2/benchmark/ch/br/ch-5k-tiflash
            s3_endpoint: |-
              https://testinfraeastus2.blob.core.windows.net
            # db_name: Set name to restore TARGET DB / Empty to restore FULL CLUSTER .
            db_name: "tpcc5000"
            # br_options: You can set extra options like '--checksum-concurrency 128 --ddl-batch-size=32 --kespace=kespace-a --pitr-concurrency=128'
            br_options: '--check-requirements=false'
            # br_version: BR Version is recommended to be the same as the TiDB cluster version
            br_version: {{.inputs.cluster_version}}
            # br_base_image: BR Base Image is the image name used by Testbed to deploy BR. Leave empty to use the default image.
            br_base_image: ''
            # prepare_method: br_restore/sql_generate/import
            prepare_method: "br_restore"
            # supported_methods: br_restore,sql_generate,import
        db_port: 4000
        pd_port: 2379
        user_id: 240023
        cluster_type: tidbcloud_cluster
      fastFail: true
    measured:
      width: 703
      height: 466
    selected: false
    dragging: false
  - id: '87'
    type: ti_workload_call
    position:
      x: 1696.6457832349533
      'y': 747.7114603194193
    data:
      name: tpcc_5k_100th_2hrs
      inputs:
        - id: '614'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          subType: TIDBCLOUD_CLUSTER
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
      outputs:
        - name: exec_id
          type: String
          description: TiWorkload Execution ID
          id: '1863'
        - name: exec_status
          type: String
          description: TiWorkload Execution Status
          id: '1864'
        - name: exec_tasks
          type: Object
          description: Tasks of the TiWorkload Execution
          id: '1865'
      spec:
        tiworkload_host: https://tiworkload.pingcap.net
        workload_name: tpcc
        db_port: 4000
        pd_port: 2379
        user_id: 240023
        cluster_type: tidbcloud_cluster
        db_host: tc-tidb
        pd_host: tc-pd
        workload: |
          params:
            client_cnt: 1
            client_resource: |-
              { "cpu": "15", "memory": "26Gi" }
            db_name: tpcc5000
            thread: 100
            duration: 120
            tpc_options: |-
              --ignore-error
            warehouses: 5000
      fastFail: true
    measured:
      width: 701
      height: 425
    selected: false
    dragging: false
  - id: '148'
    type: cluster_checker
    position:
      x: 8552.686085083751
      'y': 1422.7055743275732
    data:
      name: qps_metrics
      inputs:
        - id: '149'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          subType: TIDBCLOUD_CLUSTER
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
      outputs: []
      spec:
        mode: consistently
        fastFail: false
        pollInterval: 30s
        timeout: 240h
        warmupDuration: 30s
        rules:
          - name: Command Per Second
            customPromQLExpr: sum(rate(tidb_server_query_total{}[2m])) by (result)
            arguments: {}
        outputRules: []
      fastFail: false
    measured:
      width: 701
      height: 338
    selected: false
    dragging: false
  - id: '862'
    type: sleep
    position:
      x: -127.09590347106632
      'y': 1189.6661829329087
    data:
      name: sleep_after_prepare
      inputs: []
      outputs: []
      spec:
        duration: 20m
      fastFail: false
    measured:
      width: 600
      height: 108
    selected: false
    dragging: false
  - id: '896'
    type: sleep
    position:
      x: 2650.8907455038525
      'y': 908.2114603194193
    data:
      name: sleep_after_100th
      inputs: []
      outputs: []
      spec:
        duration: 10m
      fastFail: false
    measured:
      width: 600
      height: 108
    selected: false
    dragging: false
  - id: '897'
    type: ti_workload_call
    position:
      x: 3601.6457832349543
      'y': 748.3624678656392
    data:
      name: tpcc_5k_200th_2hrs
      inputs:
        - id: '898'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          optionalSubType:
            - TIDB_CLUSTER
            - TIDBCLOUD_CLUSTER
            - TIDBCLOUD_NEXTGEN_CLUSTER
            - TIDBCLOUD_SERVERLESS
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
          subType: TIDBCLOUD_CLUSTER
      outputs:
        - name: exec_id
          type: String
          description: TiWorkload Execution ID
          id: '1869'
        - name: exec_status
          type: String
          description: TiWorkload Execution Status
          id: '1870'
        - name: exec_tasks
          type: Object
          description: Tasks of the TiWorkload Execution
          id: '1871'
      spec:
        tiworkload_host: https://tiworkload.pingcap.net
        workload_name: tpcc
        workload: |-
          params:
            client_cnt: 1
            client_resource: |-
              { "cpu": "15", "memory": "26Gi" }
            db_name: tpcc5000
            thread: 200
            duration: 120
            tpc_options: |-
              --ignore-error
            warehouses: 5000
        db_port: 4000
        pd_port: 2379
        user_id: 240023
        cluster_type: tidbcloud_cluster
      fastFail: true
    measured:
      width: 701
      height: 425
    selected: false
    dragging: false
  - id: '923'
    type: sleep
    position:
      x: 4653.684385108923
      'y': 913.2869640925292
    data:
      name: sleep_after_200th
      inputs: []
      outputs: []
      spec:
        duration: 10m
      fastFail: false
    measured:
      width: 600
      height: 108
    selected: false
    dragging: false
  - id: '924'
    type: sleep
    position:
      x: 6544.816941705572
      'y': 938.6644829580791
    data:
      name: sleep_after_400th
      inputs: []
      outputs: []
      spec:
        duration: 10m
      fastFail: false
    measured:
      width: 600
      height: 108
    selected: false
    dragging: false
  - id: '937'
    type: ti_workload_call
    position:
      x: 5609.514926613133
      'y': 743.2869640925292
    data:
      name: tpcc_5k_400th_2hrs
      inputs:
        - id: '938'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          optionalSubType:
            - TIDB_CLUSTER
            - TIDBCLOUD_CLUSTER
            - TIDBCLOUD_NEXTGEN_CLUSTER
            - TIDBCLOUD_SERVERLESS
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
          subType: TIDBCLOUD_CLUSTER
      outputs:
        - name: exec_id
          type: String
          description: TiWorkload Execution ID
          id: '1875'
        - name: exec_status
          type: String
          description: TiWorkload Execution Status
          id: '1876'
        - name: exec_tasks
          type: Object
          description: Tasks of the TiWorkload Execution
          id: '1877'
      spec:
        tiworkload_host: https://tiworkload.pingcap.net
        workload_name: tpcc
        workload: |-
          params:
            client_cnt: 1
            client_resource: |-
              { "cpu": "15", "memory": "26Gi" }
            db_name: tpcc5000
            thread: 400
            duration: 120
            tpc_options: |-
              --ignore-error
            warehouses: 5000
        db_port: 4000
        pd_port: 2379
        user_id: 240023
        cluster_type: tidbcloud_cluster
      fastFail: false
    measured:
      width: 701
      height: 425
    selected: false
    dragging: false
  - id: '963'
    type: ti_workload_call
    position:
      x: 7623.728449707698
      'y': 799.117505596739
    data:
      name: tpcc_5k_800th_2hrs
      inputs:
        - id: '964'
          name: tidb_cluster
          kind: reference
          value: ''
          type: Object
          optionalSubType:
            - TIDB_CLUSTER
            - TIDBCLOUD_CLUSTER
            - TIDBCLOUD_NEXTGEN_CLUSTER
            - TIDBCLOUD_SERVERLESS
          description: Handler to the tidb cluster
          required: true
          fromOutput:
            node: tidbcloud_cluster_create
            parameter: tc
          subType: TIDBCLOUD_CLUSTER
      outputs:
        - name: exec_id
          type: String
          description: TiWorkload Execution ID
          id: '1881'
        - name: exec_status
          type: String
          description: TiWorkload Execution Status
          id: '1882'
        - name: exec_tasks
          type: Object
          description: Tasks of the TiWorkload Execution
          id: '1883'
      spec:
        tiworkload_host: https://tiworkload.pingcap.net
        workload_name: tpcc
        workload: |-
          params:
            client_cnt: 1
            client_resource: |-
              { "cpu": "15", "memory": "26Gi" }
            db_name: tpcc5000
            thread: 800
            duration: 120
            tpc_options: |-
              --ignore-error
            warehouses: 5000
        db_port: 4000
        pd_port: 2379
        user_id: 240023
        cluster_type: tidbcloud_cluster
      fastFail: true
    measured:
      width: 701
      height: 425
    selected: false
    dragging: false
edges:
  - source: __START__
    sourceHandle: a
    target: '10'
    targetHandle: w1
    id: __START__-10-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
    selected: false
  - id: 10-35-w1
    source: '10'
    sourceHandle: source
    target: '35'
    type: custom
    targetHandle: w1
    data:
      type: OnCondition
      onConditions:
        - OnSuccess
      name: w1
  - source: '963'
    sourceHandle: source
    target: '148'
    targetHandle: cancel
    id: 963-148-cancel
    type: custom
    data:
      name: cancel
      type: Cancel
      onConditions: []
  - source: '35'
    sourceHandle: source
    target: '862'
    targetHandle: w1
    id: 35-862-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '862'
    sourceHandle: source
    target: '87'
    targetHandle: w1
    id: 862-87-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '87'
    sourceHandle: source
    target: '896'
    targetHandle: w1
    id: 87-896-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '896'
    sourceHandle: source
    target: '897'
    targetHandle: w1
    id: 896-897-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '897'
    sourceHandle: source
    target: '923'
    targetHandle: w1
    id: 897-923-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '923'
    sourceHandle: source
    target: '937'
    targetHandle: w1
    id: 923-937-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '937'
    sourceHandle: source
    target: '924'
    targetHandle: w1
    id: 937-924-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '924'
    sourceHandle: source
    target: '963'
    targetHandle: w1
    id: 924-963-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
  - source: '862'
    sourceHandle: source
    target: '148'
    targetHandle: w1
    id: 862-148-w1
    type: custom
    data:
      name: w1
      type: OnCondition
      onConditions:
        - OnSuccess
startNodeParams:
  - id: '1'
    name: cluster_version
    value: v8.5.4
    type: String
    description: The name of the testbed
    required: true
  - id: '41'
    name: tidbcloud_org_id
    value: '1369847559691397265'
    type: String
    description: ''
    required: true
  - id: '54'
    name: tidbcloud_project_id
    value: '1369847559694040707'
    type: String
    description: ''
    required: true
