HDFS audit destination file append configuration properties

File append property enables the writer to append data to the most recent log file instead of generating a new log file upon restart.

file.append.enabled
  • Property: xasecure.audit.destination.hdfs.file.append.enabled
  • Default: false
  • Description: When enabled, the writer will attempt to append to the last log file instead of creating a new one on restart.
    xasecure.audit.destination.hdfs.file.append.enabled=true
  • Behavior:
    1. Checks if the file system supports append capability using Hadoop's CommonPathCapabilities.FS_APPEND

    2. If supported and enabled, reopens and appends to existing file

    3. If append fails or is not supported, creates a new file with a numeric suffix

  • File System Compatibility:
    • ✅ HDFS - Fully supported

    • ✅ MapR-FS - Supported

    • ❌ S3 - Not supported (eventually consistent, no atomic append)

    • ❌ Azure Blob Storage (wasb) - Limited support

    • ⚠️ Azure Data Lake Storage (adl/abfs) - Check HDFS version

  • Fallback: If append fails for any reason, the system automatically creates a new file without failing.