{
  "repo": "tidbcloud/tidb-cse",
  "binary": "tidb-server",
  "binary_path": "cmd/tidb-server/main.go",
  "surface_kind": "mixed_service",
  "type": "mixed_service",
  "services": [
    {
      "name": "TiDBCSEServer",
      "package": "github.com/pingcap/tidb/cmd/tidb-server",
      "methods": [
        {
          "name": "serveSQLAndStatus",
          "name_key": "Runtime TiDBCSEServer.serveSQLAndStatus",
          "input": "flags + config file + TiKV/PD/keyspace metadata connectivity",
          "output": "MySQL-compatible SQL service plus HTTP status and metrics endpoints",
          "type": "http"
        },
        {
          "name": "serveRPCStatus",
          "name_key": "Runtime TiDBCSEServer.serveRPCStatus",
          "input": "status listener on the TiDB CSE status port",
          "output": "gRPC status services for diagnostics, coprocessor/TiKV compatibility, TopSQL pubsub, and optional AutoID allocation",
          "type": "grpc"
        }
      ]
    }
  ],
  "extensions": {
    "notes": [
      "pkg/server/http_status.go multiplexes HTTP status traffic and gRPC traffic on the status listener.",
      "pkg/server/rpc_server.go registers Diagnostics, Tikv, and TopSQL pubsub; AutoIDAlloc and channelz are added from http_status.go when enabled."
    ]
  }
}
