{
  "repo": "tidbcloud/core-svc",
  "binary": "server",
  "binary_path": "svc/cmd/server/main.go",
  "surface_kind": "mixed_service",
  "type": "mixed_service",
  "extensions": {},
  "services": [
    {
      "name": "CoreSvcLifecycle",
      "type": "lifecycle",
      "methods": [
        {
          "name": "BuildRootCommand",
          "name_key": "CoreSvcLifecycle.BuildRootCommand",
          "description": "Build the root Cobra command, register the serve and utility subcommands, and install the persistent config-path flag."
        },
        {
          "name": "ParseFlags",
          "name_key": "CoreSvcLifecycle.ParseFlags",
          "description": "Parse the persistent config-path flag plus the selected subcommand and its arguments."
        },
        {
          "name": "InitConfig",
          "name_key": "CoreSvcLifecycle.InitConfig",
          "description": "Load the core-svc configuration in cobra.OnInitialize before any runtime bootstrap or command execution begins."
        },
        {
          "name": "InitTiInf",
          "name_key": "CoreSvcLifecycle.InitTiInf",
          "description": "Parse the TiInf config and initialize the shared TiInf runtime with gRPC interceptors and panic recovery."
        },
        {
          "name": "RegisterMetricsController",
          "name_key": "CoreSvcLifecycle.RegisterMetricsController",
          "description": "Register the controller-runtime metrics handler on /metrics_controller before the runtime starts."
        },
        {
          "name": "SetupDI",
          "name_key": "CoreSvcLifecycle.SetupDI",
          "description": "Initialize dependency injection bindings for controllers, workers, facades, repositories, and command helpers."
        },
        {
          "name": "WarmupKms",
          "name_key": "CoreSvcLifecycle.WarmupKms",
          "description": "Warm up the AWS KMS helper asynchronously during startup."
        },
        {
          "name": "RegisterCoreService",
          "name_key": "CoreSvcLifecycle.RegisterCoreService",
          "description": "Register CoreService on the shared TiInf gRPC server when CORE_SVC_ROLE enables the API service."
        },
        {
          "name": "RunDBMigrate",
          "name_key": "CoreSvcLifecycle.RunDBMigrate",
          "description": "Run database schema migrations before worker loops start when CORE_SVC_ROLE enables the worker mode."
        },
        {
          "name": "StartCronWorker",
          "name_key": "CoreSvcLifecycle.StartCronWorker",
          "description": "Start the GlobalWorker scheduler when CORE_SVC_ROLE enables the worker mode."
        },
        {
          "name": "StartDBSubscriber",
          "name_key": "CoreSvcLifecycle.StartDBSubscriber",
          "description": "Start the SubscriberMgr background loop when CORE_SVC_ROLE enables the worker mode."
        },
        {
          "name": "RegisterEventbusConsumers",
          "name_key": "CoreSvcLifecycle.RegisterEventbusConsumers",
          "description": "Register eventbus consumers only in worker-capable mode before the eventbus transport starts."
        },
        {
          "name": "StartInfraAPIWatcher",
          "name_key": "CoreSvcLifecycle.StartInfraAPIWatcher",
          "description": "Create the optional infra-api watcher only when worker mode is enabled."
        },
        {
          "name": "StartK8sControllerManager",
          "name_key": "CoreSvcLifecycle.StartK8sControllerManager",
          "description": "Start the controller-runtime manager after DI and service registration are complete."
        },
        {
          "name": "StartEventbus",
          "name_key": "CoreSvcLifecycle.StartEventbus",
          "description": "Run the shared eventbus transport after all producers and consumers are initialized."
        },
        {
          "name": "StartServeRuntime",
          "name_key": "CoreSvcLifecycle.StartServeRuntime",
          "description": "Start the unified TiInf runtime for the serve subcommand and expose the configured gRPC and metrics listeners."
        }
      ]
    },
    {
      "name": "CoreSvcAdminCommands",
      "type": "cli",
      "methods": [
        {
          "name": "MigrateCIDR",
          "name_key": "CoreSvcAdminCommands.MigrateCIDR",
          "description": "Run the migrate-cidr subcommand against the local DI graph."
        },
        {
          "name": "RerunProjectMetering",
          "name_key": "CoreSvcAdminCommands.RerunProjectMetering",
          "description": "Run the rerun-project-metering subcommand for the provided project metering IDs."
        },
        {
          "name": "RepairServerlessDelegateUser",
          "name_key": "CoreSvcAdminCommands.RepairServerlessDelegateUser",
          "description": "Run the repair-serverless-delegate-user subcommand for the selected clusters."
        },
        {
          "name": "ScaleCluster",
          "name_key": "CoreSvcAdminCommands.ScaleCluster",
          "description": "Run the scale-cluster subcommand for a single cluster with the requested component overrides."
        },
        {
          "name": "PrintErrCode",
          "name_key": "CoreSvcAdminCommands.PrintErrCode",
          "description": "Print all registered biz error codes and exit."
        }
      ]
    },
    {
      "name": "CoreService",
      "package": "core",
      "methods": [
        {
          "name": "SyncInfraProfile",
          "name_key": "CoreService.SyncInfraProfile",
          "input": "SyncInfraProfileReq",
          "output": "SyncInfraProfileResp"
        },
        {
          "name": "CheckSkuSynced",
          "name_key": "CoreService.CheckSkuSynced",
          "input": "CheckSkuSyncedReq",
          "output": "CheckSkuSyncedResp"
        },
        {
          "name": "UpsertProfileByYaml",
          "name_key": "CoreService.UpsertProfileByYaml",
          "input": "UpsertProfileByYamlReq",
          "output": "UpsertProfileByYamlResp"
        },
        {
          "name": "ListNodeProfiles4Tenant",
          "name_key": "CoreService.ListNodeProfiles4Tenant",
          "input": "ListNodeProfiles4TenantReq",
          "output": "ListNodeProfiles4TenantResp"
        },
        {
          "name": "BatchGetTiers",
          "name_key": "CoreService.BatchGetTiers",
          "input": "BatchGetTiersReq",
          "output": "BatchGetTiersResp"
        },
        {
          "name": "ListCloudProviders",
          "name_key": "CoreService.ListCloudProviders",
          "input": "ListCloudProvidersReq",
          "output": "ListCloudProvidersResp"
        },
        {
          "name": "QueryCloudProviders",
          "name_key": "CoreService.QueryCloudProviders",
          "input": "QueryCloudProvidersReq",
          "output": "QueryCloudProvidersResp"
        },
        {
          "name": "ListCloudRegions",
          "name_key": "CoreService.ListCloudRegions",
          "input": "ListCloudRegionsReq",
          "output": "ListCloudRegionsResp"
        },
        {
          "name": "CreateIamRole",
          "name_key": "CoreService.CreateIamRole",
          "input": "CreateIamRoleReq",
          "output": "CreateIamRoleResp"
        },
        {
          "name": "DeleteIamRole",
          "name_key": "CoreService.DeleteIamRole",
          "input": "DeleteIamRoleReq",
          "output": "DeleteIamRoleResp"
        },
        {
          "name": "ListIamRoles",
          "name_key": "CoreService.ListIamRoles",
          "input": "ListIamRolesReq",
          "output": "ListIamRolesResp"
        },
        {
          "name": "CreateAwsCmek",
          "name_key": "CoreService.CreateAwsCmek",
          "input": "CreateAwsCmekReq",
          "output": "CreateAwsCmekResp"
        },
        {
          "name": "GetAwsCmek",
          "name_key": "CoreService.GetAwsCmek",
          "input": "GetAwsCmekReq",
          "output": "GetAwsCmekResp"
        },
        {
          "name": "GetAwsAccount",
          "name_key": "CoreService.GetAwsAccount",
          "input": "GetAwsAccountReq",
          "output": "GetAwsAccountResp"
        },
        {
          "name": "GetClusterName",
          "name_key": "CoreService.GetClusterName",
          "input": "GetClusterNameReq",
          "output": "GetClusterNameResp"
        },
        {
          "name": "ChangeClusterPasswd",
          "name_key": "CoreService.ChangeClusterPasswd",
          "input": "ChangeClusterPasswdReq",
          "output": "ChangeClusterPasswdResp"
        },
        {
          "name": "UpdateClusterTrafficFilter",
          "name_key": "CoreService.UpdateClusterTrafficFilter",
          "input": "UpdateClusterTrafficFilterReq",
          "output": "UpdateClusterTrafficFilterResp"
        },
        {
          "name": "CreateCluster",
          "name_key": "CoreService.CreateCluster",
          "input": "CreateClusterReq",
          "output": "CreateClusterResp"
        },
        {
          "name": "DeleteCluster",
          "name_key": "CoreService.DeleteCluster",
          "input": "DeleteClusterReq",
          "output": "DeleteClusterResp"
        },
        {
          "name": "CreateClusterSnapshot",
          "name_key": "CoreService.CreateClusterSnapshot",
          "input": "CreateClusterSnapshotReq",
          "output": "CreateClusterSnapshotResp"
        },
        {
          "name": "ListClusterSnapshots",
          "name_key": "CoreService.ListClusterSnapshots",
          "input": "ListClusterSnapshotsReq",
          "output": "ListClusterSnapshotsResp"
        },
        {
          "name": "ScaleCluster",
          "name_key": "CoreService.ScaleCluster",
          "input": "ScaleClusterReq",
          "output": "ScaleClusterResp"
        },
        {
          "name": "PauseCluster",
          "name_key": "CoreService.PauseCluster",
          "input": "PauseClusterReq",
          "output": "PauseClusterResp"
        },
        {
          "name": "ResumeCluster",
          "name_key": "CoreService.ResumeCluster",
          "input": "ResumeClusterReq",
          "output": "ResumeClusterResp"
        },
        {
          "name": "ClearCluster",
          "name_key": "CoreService.ClearCluster",
          "input": "ClearClusterReq",
          "output": "ClearClusterResp"
        },
        {
          "name": "SetClusterReadonly",
          "name_key": "CoreService.SetClusterReadonly",
          "input": "SetClusterReadonlyReq",
          "output": "SetClusterReadonlyResp"
        },
        {
          "name": "CalcClusterFee",
          "name_key": "CoreService.CalcClusterFee",
          "input": "CalcClusterFeeReq",
          "output": "CalcClusterFeeResp"
        },
        {
          "name": "ListClusters",
          "name_key": "CoreService.ListClusters",
          "input": "ListClustersReq",
          "output": "ListClustersResp"
        },
        {
          "name": "CountClusters",
          "name_key": "CoreService.CountClusters",
          "input": "CountClustersReq",
          "output": "CountClustersResp"
        },
        {
          "name": "GetClusterConfidentialInfo",
          "name_key": "CoreService.GetClusterConfidentialInfo",
          "input": "GetClusterConfidentialInfoReq",
          "output": "GetClusterConfidentialInfoResp"
        },
        {
          "name": "CreateXAccountDeploy",
          "name_key": "CoreService.CreateXAccountDeploy",
          "input": "CreateXAccountDeployReq",
          "output": "CreateXAccountDeployResp"
        },
        {
          "name": "ListXAccountDeploy",
          "name_key": "CoreService.ListXAccountDeploy",
          "input": "ListXAccountDeployReq",
          "output": "ListXAccountDeployResp"
        },
        {
          "name": "DeleteXAccountDeploy",
          "name_key": "CoreService.DeleteXAccountDeploy",
          "input": "DeleteXAccountDeployReq",
          "output": "DeleteXAccountDeployResp"
        },
        {
          "name": "GetClusterCACertificate",
          "name_key": "CoreService.GetClusterCACertificate",
          "input": "GetClusterCACertificateReq",
          "output": "GetClusterCACertificateResp"
        },
        {
          "name": "CreateClusterJob",
          "name_key": "CoreService.CreateClusterJob",
          "input": "CreateClusterJobReq",
          "output": "CreateClusterJobResp"
        },
        {
          "name": "DeleteClusterJob",
          "name_key": "CoreService.DeleteClusterJob",
          "input": "DeleteClusterJobReq",
          "output": "DeleteClusterJobResp"
        },
        {
          "name": "IsClusterJobRegistered",
          "name_key": "CoreService.IsClusterJobRegistered",
          "input": "IsClusterJobRegisteredReq",
          "output": "IsClusterJobRegisteredResp"
        },
        {
          "name": "ListClusterJobs",
          "name_key": "CoreService.ListClusterJobs",
          "input": "ListClusterJobsReq",
          "output": "ListClusterJobsResp"
        },
        {
          "name": "ListRegionCIDROfProject",
          "name_key": "CoreService.ListRegionCIDROfProject",
          "input": "ListRegionCIDROfProjectReq",
          "output": "ListRegionCIDROfProjectResp"
        },
        {
          "name": "CreateClusterConn",
          "name_key": "CoreService.CreateClusterConn",
          "input": "CreateClusterConnReq",
          "output": "CreateClusterConnResp"
        },
        {
          "name": "CreateNetworkPeer",
          "name_key": "CoreService.CreateNetworkPeer",
          "input": "CreateNetworkPeerReq",
          "output": "CreateNetworkPeerResp"
        },
        {
          "name": "DeleteNetworkPeer",
          "name_key": "CoreService.DeleteNetworkPeer",
          "input": "DeleteNetworkPeerReq",
          "output": "DeleteNetworkPeerResp"
        },
        {
          "name": "ListNetworkPeer",
          "name_key": "CoreService.ListNetworkPeer",
          "input": "ListNetworkPeerReq",
          "output": "ListNetworkPeerResp"
        },
        {
          "name": "CreatePrivateLinkService",
          "name_key": "CoreService.CreatePrivateLinkService",
          "input": "CreatePrivateLinkServiceReq",
          "output": "CreatePrivateLinkServiceResp"
        },
        {
          "name": "DeletePrivateLinkService",
          "name_key": "CoreService.DeletePrivateLinkService",
          "input": "DeletePrivateLinkServiceReq",
          "output": "DeletePrivateLinkServiceResp"
        },
        {
          "name": "GetPrivateLinkService",
          "name_key": "CoreService.GetPrivateLinkService",
          "input": "GetPrivateLinkServiceReq",
          "output": "GetPrivateLinkServiceResp"
        },
        {
          "name": "CreatePrivateLinkEndpoint",
          "name_key": "CoreService.CreatePrivateLinkEndpoint",
          "input": "CreatePrivateLinkEndpointReq",
          "output": "CreatePrivateLinkEndpointResp"
        },
        {
          "name": "DeletePrivateLinkEndpoint",
          "name_key": "CoreService.DeletePrivateLinkEndpoint",
          "input": "DeletePrivateLinkEndpointReq",
          "output": "DeletePrivateLinkEndpointResp"
        },
        {
          "name": "ListPrivateLinkEndpoints",
          "name_key": "CoreService.ListPrivateLinkEndpoints",
          "input": "ListPrivateLinkEndpointsReq",
          "output": "ListPrivateLinkEndpointsResp"
        },
        {
          "name": "CleanClusters",
          "name_key": "CoreService.CleanClusters",
          "input": "CleanClustersReq",
          "output": "CleanClustersResp"
        },
        {
          "name": "CleanProjectResource",
          "name_key": "CoreService.CleanProjectResource",
          "input": "CleanProjectResourceReq",
          "output": "CleanProjectResourceResp"
        },
        {
          "name": "CleanTenantResource",
          "name_key": "CoreService.CleanTenantResource",
          "input": "CleanTenantResourceReq",
          "output": "CleanTenantResourceResp"
        },
        {
          "name": "CreateDBUser",
          "name_key": "CoreService.CreateDBUser",
          "input": "CreateDBUserReq",
          "output": "CreateDBUserResp"
        },
        {
          "name": "UpdateDBUser",
          "name_key": "CoreService.UpdateDBUser",
          "input": "UpdateDBUserReq",
          "output": "UpdateDBUserResp"
        },
        {
          "name": "DeleteDBUser",
          "name_key": "CoreService.DeleteDBUser",
          "input": "DeleteDBUserReq",
          "output": "DeleteDBUserResp"
        },
        {
          "name": "GetDBUser",
          "name_key": "CoreService.GetDBUser",
          "input": "GetDBUserReq",
          "output": "GetDBUserResp"
        },
        {
          "name": "IsDBUserExisting",
          "name_key": "CoreService.IsDBUserExisting",
          "input": "IsDBUserExistingReq",
          "output": "IsDBUserExistingResp"
        },
        {
          "name": "CreateDBRole",
          "name_key": "CoreService.CreateDBRole",
          "input": "CreateDBRoleReq",
          "output": "CreateDBRoleResp"
        },
        {
          "name": "UpdateDBRole",
          "name_key": "CoreService.UpdateDBRole",
          "input": "UpdateDBRoleReq",
          "output": "UpdateDBRoleResp"
        },
        {
          "name": "ListDBUsers",
          "name_key": "CoreService.ListDBUsers",
          "input": "ListDBUsersReq",
          "output": "ListDBUsersResp"
        },
        {
          "name": "SetClusterAuthPubKey",
          "name_key": "CoreService.SetClusterAuthPubKey",
          "input": "SetClusterAuthPubKeyReq",
          "output": "SetClusterAuthPubKeyResp"
        },
        {
          "name": "GetMaintenanceWindowByProjectID",
          "name_key": "CoreService.GetMaintenanceWindowByProjectID",
          "input": "GetMaintenanceWindowByProjectIDReq",
          "output": "GetMaintenanceWindowByProjectIDResp"
        },
        {
          "name": "UpdateMaintenanceWindow",
          "name_key": "CoreService.UpdateMaintenanceWindow",
          "input": "UpdateMaintenanceWindowReq",
          "output": "UpdateMaintenanceWindowResp"
        },
        {
          "name": "CreateMaintenanceTask",
          "name_key": "CoreService.CreateMaintenanceTask",
          "input": "CreateMaintenanceTaskReq",
          "output": "CreateMaintenanceTaskResp"
        },
        {
          "name": "QueryMaintenanceTasks",
          "name_key": "CoreService.QueryMaintenanceTasks",
          "input": "QueryMaintenanceTasksReq",
          "output": "QueryMaintenanceTasksResp"
        },
        {
          "name": "CountMaintenanceTasks",
          "name_key": "CoreService.CountMaintenanceTasks",
          "input": "CountMaintenanceTasksReq",
          "output": "CountMaintenanceTasksResp"
        },
        {
          "name": "DeferMaintenanceTask",
          "name_key": "CoreService.DeferMaintenanceTask",
          "input": "DeferMaintenanceTaskReq",
          "output": "DeferMaintenanceTaskResp"
        },
        {
          "name": "UpdateMaintenanceTaskStatus",
          "name_key": "CoreService.UpdateMaintenanceTaskStatus",
          "input": "UpdateMaintenanceTaskStatusReq",
          "output": "UpdateMaintenanceTaskStatusResp"
        },
        {
          "name": "QueryMaintenanceTaskExecutions",
          "name_key": "CoreService.QueryMaintenanceTaskExecutions",
          "input": "QueryMaintenanceTaskExecutionsReq",
          "output": "QueryMaintenanceTaskExecutionsResp"
        },
        {
          "name": "UpdateMaintenanceTaskExecutionStatus",
          "name_key": "CoreService.UpdateMaintenanceTaskExecutionStatus",
          "input": "UpdateMaintenanceTaskExecutionStatusReq",
          "output": "UpdateMaintenanceTaskExecutionStatusResp"
        },
        {
          "name": "SyncMaintenanceWindow",
          "name_key": "CoreService.SyncMaintenanceWindow",
          "input": "SyncMaintenanceWindowReq",
          "output": "SyncMaintenanceWindowResp"
        },
        {
          "name": "GetClusterTopology",
          "name_key": "CoreService.GetClusterTopology",
          "input": "GetClusterTopologyReq",
          "output": "GetClusterTopologyResp"
        },
        {
          "name": "ExecuteCtlCommand",
          "name_key": "CoreService.ExecuteCtlCommand",
          "input": "ExecuteCtlCommandReq",
          "output": "ExecuteCtlCommandResp"
        },
        {
          "name": "ListTenantQuota",
          "name_key": "CoreService.ListTenantQuota",
          "input": "ListTenantQuotaReq",
          "output": "ListTenantQuotaResp"
        },
        {
          "name": "UpdateTenantQuota",
          "name_key": "CoreService.UpdateTenantQuota",
          "input": "UpdateTenantQuotaReq",
          "output": "UpdateTenantQuotaResp"
        },
        {
          "name": "CreateAccessPoint",
          "name_key": "CoreService.CreateAccessPoint",
          "input": "CreateAccessPointReq",
          "output": "CreateAccessPointResp"
        },
        {
          "name": "UpdateAccessPoint",
          "name_key": "CoreService.UpdateAccessPoint",
          "input": "UpdateAccessPointReq",
          "output": "UpdateAccessPointResp"
        },
        {
          "name": "DeleteAccessPoint",
          "name_key": "CoreService.DeleteAccessPoint",
          "input": "DeleteAccessPointReq",
          "output": "DeleteAccessPointResp"
        },
        {
          "name": "ListAccessPointPrivateLinkEndpoints",
          "name_key": "CoreService.ListAccessPointPrivateLinkEndpoints",
          "input": "ListAccessPointPrivateLinkEndpointsReq",
          "output": "ListAccessPointPrivateLinkEndpointsResp"
        },
        {
          "name": "QueryAccessPoints",
          "name_key": "CoreService.QueryAccessPoints",
          "input": "QueryAccessPointsReq",
          "output": "QueryAccessPointsResp"
        },
        {
          "name": "CreateCidr",
          "name_key": "CoreService.CreateCidr",
          "input": "CreateCidrRequest",
          "output": "CreateCidrResponse"
        },
        {
          "name": "QueryCidrs",
          "name_key": "CoreService.QueryCidrs",
          "input": "QueryCidrsRequest",
          "output": "QueryCidrsResponse"
        },
        {
          "name": "UpdateCidr",
          "name_key": "CoreService.UpdateCidr",
          "input": "UpdateCidrRequest",
          "output": "UpdateCidrResponse"
        },
        {
          "name": "DeleteCidr",
          "name_key": "CoreService.DeleteCidr",
          "input": "DeleteCidrRequest",
          "output": "DeleteCidrResponse"
        },
        {
          "name": "GetDefaultCidr",
          "name_key": "CoreService.GetDefaultCidr",
          "input": "GetDefaultCidrRequest",
          "output": "GetDefaultCidrResponse"
        },
        {
          "name": "SimulatedSelectTierUnit",
          "name_key": "CoreService.SimulatedSelectTierUnit",
          "input": "ScaleClusterReq",
          "output": "SimulatedSelectTierUnitResponse"
        },
        {
          "name": "CountBillableClusters",
          "name_key": "CoreService.CountBillableClusters",
          "input": "CountBillableClustersReq",
          "output": "CountBillableClustersResp"
        }
      ]
    },
    {
      "name": "CoreSvcMetrics",
      "type": "http",
      "methods": [
        {
          "name": "MetricsController",
          "name_key": "HTTP GET /metrics_controller",
          "method": "GET",
          "path": "/metrics_controller",
          "description": "Expose the controller-runtime metrics registry when the TiInf metrics listener is enabled."
        }
      ]
    }
  ]
}
