MuleSoft · File Connector
FILE:FILE_ALREADY_EXISTS
Short answer
FILE:FILE_ALREADY_EXISTS means the target file already exists and the operation is not allowed to overwrite it. Set Overwrite to true, pick a different write mode, or use a unique file name.
VerifiedLast verified
01Error text
Error type: FILE:FILE_ALREADY_EXISTS02Likely causes
- The target file already exists and the overwrite property is set to
false. - For Write, the behavior when the file exists depends on the write mode:
OVERWRITE,APPENDorCREATE_NEW.
03How to fix it
- Decide what should happen when the file exists: replace it, add to it, or fail.
- For Copy, Move and Rename, set Overwrite to
trueto replace the target. - For Write, choose the Write Mode that fits.
OVERWRITEis the default, andCREATE_NEWis the mode that fails when the file exists. - Or build a unique target file name, then handle
FILE:FILE_ALREADY_EXISTSfor the remaining cases.
04Official documentation
→Related errors
- FILE:ILLEGAL_PATHFILE:ILLEGAL_PATH means a File Connector operation was given a path that does not exist while Create parent directories is set to false. Correct the path, or let the operation create the missing directories.
- FILE:ACCESS_DENIEDFILE:ACCESS_DENIED means a File Connector operation tried an action on a file or path that the user running the app is not permitted to perform. Grant that user the permission on the path.
Test every fix in a non-production environment before you apply it to production. See how entries are verified.
More for MuleSoft work:Open MuleSoft jobsMuleSoft rates and salariesHire a senior MuleSoft developer