{"record":{"id":"7e5116c46cac02e2","repo":"goharbor/harbor","slug":"unique-job-error-missing-ok-reply","errorCode":null,"errorMessage":"unique job error: missing 'OK' reply","messagePattern":"unique job error: missing 'OK' reply","errorType":"http","errorClass":null,"httpStatus":500,"severity":"error","filePath":"src/jobservice/worker/cworker/de_duplicator.go","lineNumber":104,"sourceCode":"\targs := []any{\n\t\tuniqueKey,\n\t\t1,\n\t\t\"NX\",\n\t\t\"EX\",\n\t\t86400,\n\t}\n\n\tres, err := redis.String(conn.Do(\"SET\", args...))\n\tif err == redis.ErrNil {\n\t\treturn errs.ConflictError(uniqueKey)\n\t}\n\n\tif err == nil {\n\t\tif strings.ToUpper(res) == \"OK\" {\n\t\t\treturn nil\n\t\t}\n\n\t\treturn errors.New(\"unique job error: missing 'OK' reply\")\n\t}\n\n\treturn err\n}\n\n// DelUniqueSign delete the job unique sign\nfunc (rdd *redisDeDuplicator) DelUniqueSign(jobName string, params job.Parameters) error {\n\tuniqueKey, err := redisKeyUniqueJob(rdd.namespace, jobName, params)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"delete unique job error: %s\", err)\n\t}\n\n\tconn := rdd.pool.Get()\n\tdefer func() {\n\t\t_ = conn.Close()\n\t}()\n\n\tif _, err := conn.Do(\"DEL\", uniqueKey); err != nil {","sourceCodeStart":86,"sourceCodeEnd":122,"githubUrl":"https://github.com/goharbor/harbor/blob/7b2fd08cc568955cca339afeefab27372840d936/src/jobservice/worker/cworker/de_duplicator.go#L86-L122","documentation":"MustUnique received an unexpected reply from the Redis SET key 1 NX EX 86400 call that creates the unique-job sign: the command succeeded (no error, no ErrNil) but the reply string was not 'OK', violating the deduplication protocol.","triggerScenarios":"Thrown at src/jobservice/worker/cworker/de_duplicator.go:104 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Retry the job submission — a transient Redis proxy may have altered the reply","Inspect the Redis server/proxy for protocol-rewriting behavior (e.g. RESP3 or a proxy normalizing replies)"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"7b2fd08cc568955cca339afeefab27372840d936","analyzedAt":"2026-08-16T00:00:10.961Z","contentChangedAt":"2026-08-16T00:00:10.961Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}