{"record":{"id":"87ee5d4684f6aaec","repo":"goharbor/harbor","slug":"tencent-tcr-newadapter-can-not-get-tcr-instance","errorCode":null,"errorMessage":"[tencent-tcr.newAdapter] Can not get TCR instance info. RequestId=%s","messagePattern":"\\[tencent-tcr\\.newAdapter\\] Can not get TCR instance info\\. RequestId=(.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/pkg/reg/adapter/tencentcr/adapter.go","lineNumber":149,"sourceCode":"\t\treturn\n\t}\n\n\tvar req = tcr.NewDescribeInstancesRequest()\n\treq.AllRegion = common.BoolPtr(true)\n\treq.Filters = []*tcr.Filter{\n\t\t{\n\t\t\tName:   common.StringPtr(\"RegistryName\"),\n\t\t\tValues: []*string{common.StringPtr(strings.ReplaceAll(registryURL.Host, \".tencentcloudcr.com\", \"\"))},\n\t\t},\n\t}\n\tvar resp *tcr.DescribeInstancesResponse\n\tresp, err = client.DescribeInstances(req)\n\tif err != nil {\n\t\tlog.Errorf(\"DescribeInstances error=%s\", err.Error())\n\t\treturn\n\t}\n\tif *resp.Response.TotalCount == 0 {\n\t\terr = fmt.Errorf(\"[tencent-tcr.newAdapter] Can not get TCR instance info. RequestId=%s\", *resp.Response.RequestId)\n\t\treturn\n\t}\n\tvar instanceInfo = resp.Response.Registries[0]\n\tlog.Debugf(\"[tencent-tcr.InstanceInfo] registry.URL=%s, host=%s, PublicDomain=%s, RegionName=%s, RegistryId=%s\",\n\t\tregistry.URL, registryURL.Host, *instanceInfo.PublicDomain, *instanceInfo.RegionName, *instanceInfo.RegistryId)\n\n\t// rebuild TCR SDK client\n\tclient = &tcr.Client{}\n\tclient.Init(*instanceInfo.RegionName).\n\t\tWithCredential(tcrCredential).\n\t\tWithProfile(cfp).\n\t\tWithHttpTransport(rateLimiterTransport)\n\n\tvar credential = NewAuth(instanceInfo.RegistryId, client)\n\tvar transport = commonhttp.GetHTTPTransport(\n\t\tcommonhttp.WithInsecure(registry.Insecure),\n\t\tcommonhttp.WithCACert(registry.CACertificate),\n\t)","sourceCodeStart":131,"sourceCodeEnd":167,"githubUrl":"https://github.com/goharbor/harbor/blob/7b2fd08cc568955cca339afeefab27372840d936/src/pkg/reg/adapter/tencentcr/adapter.go#L131-L167","documentation":"Error \"[tencent-tcr.newAdapter] Can not get TCR instance info. RequestId=%s\" thrown in goharbor/harbor.","triggerScenarios":"Thrown at src/pkg/reg/adapter/tencentcr/adapter.go:149 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"7b2fd08cc568955cca339afeefab27372840d936","analyzedAt":"2026-08-16T00:00:10.961Z","schemaVersion":2},"datasetVersion":"2026-08-16T03:17:38.424Z"}