{"record":{"id":"ea67f64ba930629b","repo":"conductor-oss/conductor","slug":"file-not-yet-uploaded-status","errorCode":null,"errorMessage":"File not yet uploaded: {}, status={}","messagePattern":"File not yet uploaded: (.+?), status=(.+?)","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":400,"severity":"error","filePath":"core/src/main/java/org/conductoross/conductor/core/storage/FileStorageServiceImpl.java","lineNumber":124,"sourceCode":"        if (info == null || !info.isExists()) {\n            throw new NonTransientException(\"File not found on storage backend: \" + fileId);\n        }\n\n        fileMetadataDAO.updateUploadComplete(\n                fileId, FileUploadStatus.UPLOADED, info.getContentHash(), info.getContentSize());\n\n        FileUploadCompleteResponse response = new FileUploadCompleteResponse();\n        response.setFileHandleId(FileIdToFileHandleIdConverter.toFileHandleId(fileId));\n        response.setUploadStatus(FileUploadStatus.UPLOADED);\n        response.setContentHash(info.getContentHash());\n        return response;\n    }\n\n    @Override\n    public FileDownloadUrlResponse getDownloadUrl(String workflowId, String fileId) {\n        FileModel model = getFamilyAccessibleFile(workflowId, fileId);\n        if (model.getUploadStatus() != FileUploadStatus.UPLOADED) {\n            throw new IllegalArgumentException(\n                    \"File not yet uploaded: \" + fileId + \", status=\" + model.getUploadStatus());\n        }\n        String downloadUrl =\n                fileStorage.generateDownloadUrl(\n                        model.getStoragePath(), properties.getSignedUrlExpiration());\n        long expiresAt = Instant.now().plus(properties.getSignedUrlExpiration()).toEpochMilli();\n\n        FileDownloadUrlResponse response = new FileDownloadUrlResponse();\n        response.setFileHandleId(FileIdToFileHandleIdConverter.toFileHandleId(fileId));\n        response.setDownloadUrl(downloadUrl);\n        response.setExpiresAt(expiresAt);\n        return response;\n    }\n\n    @Override\n    public void uploadContent(String workflowId, String fileId, InputStream content) {\n        FileModel model = getOwnedFile(workflowId, fileId);\n        if (model.getUploadStatus() != FileUploadStatus.UPLOADING) {","sourceCodeStart":106,"sourceCodeEnd":142,"githubUrl":"https://github.com/conductor-oss/conductor/blob/cf7c3e4a8adfb158be778ab1ec525323c363cd3a/core/src/main/java/org/conductoross/conductor/core/storage/FileStorageServiceImpl.java#L106-L142","documentation":"Thrown by FileStorageServiceImpl.getDownloadUrl when the file's upload status is not UPLOADED (e.g. still UPLOADING). A download URL cannot be issued for content that has not been confirmed uploaded. Raised as IllegalArgumentException (HTTP 400); the status value is appended to aid diagnosis.","triggerScenarios":"Calling getDownloadUrl before confirmUpload has completed; the upload was never confirmed; a failed upload left the record in UPLOADING status.","commonSituations":"Client requesting a download URL mid-upload; skipped the confirm step; upload failed and the record was never advanced to UPLOADED.","solutions":["Complete the upload first: PUT content to the presigned URL, then call confirmUpload.","Inspect the file metadata (getFileMetadata) to check uploadStatus before requesting a download.","Retry the full upload flow if the prior upload failed."],"exampleFix":"// before\nFileDownloadUrlResponse r = fileStorageService.getDownloadUrl(wfId, fileId); // throws, status=UPLOADING\n\n// after - confirm the upload before requesting download\nfileStorageService.confirmUpload(wfId, fileId);\nFileDownloadUrlResponse r = fileStorageService.getDownloadUrl(wfId, fileId);","handlingStrategy":"validation","validationCode":"FileHandle meta = fileStorageService.getFileMetadata(wfId, fileId);\nif (meta.getUploadStatus() == FileUploadStatus.UPLOADED) {\n    fileStorageService.getDownloadUrl(wfId, fileId);\n}","typeGuard":null,"tryCatchPattern":"try {\n    fileStorageService.getDownloadUrl(wfId, fileId);\n} catch (IllegalArgumentException e) {\n    // file not yet uploaded; complete upload first\n}","preventionTips":["Confirm the upload before requesting a download URL","Check uploadStatus via metadata before downloading"],"tags":["file-storage","upload","state","download","conductor","java"],"backgroundTag":null,"analyzedSha":"cf7c3e4a8adfb158be778ab1ec525323c363cd3a","analyzedAt":"2026-08-14T03:33:19.897Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}