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

MuleSoft error
Error type: FILE:FILE_ALREADY_EXISTS

02Likely 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, APPEND or CREATE_NEW.

03How to fix it

  1. Decide what should happen when the file exists: replace it, add to it, or fail.
  2. For Copy, Move and Rename, set Overwrite to true to replace the target.
  3. For Write, choose the Write Mode that fits. OVERWRITE is the default, and CREATE_NEW is the mode that fails when the file exists.
  4. Or build a unique target file name, then handle FILE:FILE_ALREADY_EXISTS for the remaining cases.

04Official documentation

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

The iPaaS Brief

Subscribe to The iPaaS Brief.

The iPaaS newsletter for the people who run integrations. From iPaaS Group.

Free. You finish on theipaasbrief.com and confirm by email.