{
  "schema_version": 1,
  "suite_id": "securities-big-query-interference",
  "title": "Securities foreground workload with ten report-query RU interference levels",
  "status": "scenario_contract_not_evidence",
  "purpose": "Run exchange-matching or canonical securities traffic while one to ten report-shaped queries execute concurrently, so a single large query and a saturated foreground budget can be evaluated against the TiDB RU limit.",
  "pass_warning": "This file defines runnable inputs only. RU containment, foreground latency impact, and Max RCU enforcement require fresh run receipts plus control-plane RU metrics from the same time window.",
  "foreground_workload": {
    "workload_mix": "exchange_matching",
    "workload_profile": "canonical",
    "recommended_max_rcu": 5000,
    "recommended_foreground_target_rcu": 4000,
    "recommended_foreground_concurrency": 512
  },
  "operation": {
    "id": "securities/tpce/big_query",
    "enabled": true,
    "runtime": {
      "query_ids": [
        "report_01", "report_02", "report_03", "report_04", "report_05",
        "report_06", "report_07", "report_08", "report_09", "report_10"
      ],
      "start_after_foreground_ready_seconds": 60,
      "duration_seconds": 180,
      "query_timeout_seconds": 60
    },
    "execution_contract": "The configured concurrency is the total number of report-query workers. When query_ids has three entries, concurrency=3 binds one worker to each selected report; for concurrency above or below the selected count, dispatch follows the LLD order and reuse rules."
  },
  "scenarios": [
    {"testcase_id": "securities-big-query-c01", "operation_runtime": {"concurrency": 1}},
    {"testcase_id": "securities-big-query-c02", "operation_runtime": {"concurrency": 2}},
    {"testcase_id": "securities-big-query-c03", "operation_runtime": {"concurrency": 3}},
    {"testcase_id": "securities-big-query-c04", "operation_runtime": {"concurrency": 4}},
    {"testcase_id": "securities-big-query-c05", "operation_runtime": {"concurrency": 5}},
    {"testcase_id": "securities-big-query-c06", "operation_runtime": {"concurrency": 6}},
    {"testcase_id": "securities-big-query-c07", "operation_runtime": {"concurrency": 7}},
    {"testcase_id": "securities-big-query-c08", "operation_runtime": {"concurrency": 8}},
    {"testcase_id": "securities-big-query-c09", "operation_runtime": {"concurrency": 9}},
    {"testcase_id": "securities-big-query-c10", "operation_runtime": {"concurrency": 10}}
  ],
  "required_report_fields": [
    "run-receipt.operation_artifact_index_ref",
    "operation-artifacts.entries[].operation_id",
    "operation-artifacts.entries[].status",
    "operation-artifacts.entries[].final_receipt_ref",
    "operations.securities/tpce/big_query.receipt.concurrency",
    "operations.securities/tpce/big_query.receipt.started_query_count",
    "operations.securities/tpce/big_query.receipt.completed_query_count",
    "operations.securities/tpce/big_query.receipt.failed_query_count",
    "operations.securities/tpce/big_query.receipt.canceled_query_count",
    "operations.securities/tpce/big_query.receipt.queries[].total_elapsed_seconds",
    "control_plane.max_rcu",
    "foreground.ru_per_second",
    "foreground.latency_p99",
    "foreground.error_rate"
  ],
  "containment_expectation": "The combined RU rate must stay within the configured Max RCU envelope; a report query must be canceled, throttled, or otherwise prevented from consuming unbounded RU when the foreground load is already near the ceiling."
}
