Interface FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder

  • All Superinterfaces:
    org.apache.camel.builder.EndpointProducerBuilder, org.apache.camel.EndpointProducerResolver
    All Known Subinterfaces:
    FileEndpointBuilderFactory.AdvancedFileEndpointBuilder
    Enclosing interface:
    FileEndpointBuilderFactory

    public static interface FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder
    extends org.apache.camel.builder.EndpointProducerBuilder
    Advanced builder for endpoint producers for the File component.
    • Method Detail

      • allowNullBody

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder allowNullBody​(boolean allowNullBody)
        Used to specify if a null body is allowed during file writing. If set to true then an empty file will be created, when set to false, and attempting to send a null body to the file component, a GenericFileWriteException of 'Cannot write null body to file.' will be thrown. If the fileExist option is set to 'Override', then the file will be truncated, and if set to append the file will remain unchanged. The option is a: boolean type. Default: false Group: producer (advanced)
      • allowNullBody

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder allowNullBody​(String allowNullBody)
        Used to specify if a null body is allowed during file writing. If set to true then an empty file will be created, when set to false, and attempting to send a null body to the file component, a GenericFileWriteException of 'Cannot write null body to file.' will be thrown. If the fileExist option is set to 'Override', then the file will be truncated, and if set to append the file will remain unchanged. The option will be converted to a boolean type. Default: false Group: producer (advanced)
      • chmodDirectory

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder chmodDirectory​(String chmodDirectory)
        Specify the directory permissions used when the producer creates missing directories, the chmod value must be between 000 and 777; If there is a leading digit like in 0755 we will ignore it. The option is a: java.lang.String type. Group: producer (advanced)
      • eagerDeleteTargetFile

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder eagerDeleteTargetFile​(boolean eagerDeleteTargetFile)
        Whether or not to eagerly delete any existing target file. This option only applies when you use fileExists=Override and the tempFileName option as well. You can use this to disable (set it to false) deleting the target file before the temp file is written. For example you may write big files and want the target file to exists during the temp file is being written. This ensure the target file is only deleted until the very last moment, just before the temp file is being renamed to the target filename. This option is also used to control whether to delete any existing files when fileExist=Move is enabled, and an existing file exists. If this option copyAndDeleteOnRenameFails false, then an exception will be thrown if an existing file existed, if its true, then the existing file is deleted before the move operation. The option is a: boolean type. Default: true Group: producer (advanced)
      • eagerDeleteTargetFile

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder eagerDeleteTargetFile​(String eagerDeleteTargetFile)
        Whether or not to eagerly delete any existing target file. This option only applies when you use fileExists=Override and the tempFileName option as well. You can use this to disable (set it to false) deleting the target file before the temp file is written. For example you may write big files and want the target file to exists during the temp file is being written. This ensure the target file is only deleted until the very last moment, just before the temp file is being renamed to the target filename. This option is also used to control whether to delete any existing files when fileExist=Move is enabled, and an existing file exists. If this option copyAndDeleteOnRenameFails false, then an exception will be thrown if an existing file existed, if its true, then the existing file is deleted before the move operation. The option will be converted to a boolean type. Default: true Group: producer (advanced)
      • forceWrites

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder forceWrites​(boolean forceWrites)
        Whether to force syncing writes to the file system. You can turn this off if you do not want this level of guarantee, for example if writing to logs / audit logs etc; this would yield better performance. The option is a: boolean type. Default: true Group: producer (advanced)
      • forceWrites

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder forceWrites​(String forceWrites)
        Whether to force syncing writes to the file system. You can turn this off if you do not want this level of guarantee, for example if writing to logs / audit logs etc; this would yield better performance. The option will be converted to a boolean type. Default: true Group: producer (advanced)
      • keepLastModified

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder keepLastModified​(boolean keepLastModified)
        Will keep the last modified timestamp from the source file (if any). Will use the Exchange.FILE_LAST_MODIFIED header to located the timestamp. This header can contain either a java.util.Date or long with the timestamp. If the timestamp exists and the option is enabled it will set this timestamp on the written file. Note: This option only applies to the file producer. You cannot use this option with any of the ftp producers. The option is a: boolean type. Default: false Group: producer (advanced)
      • keepLastModified

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder keepLastModified​(String keepLastModified)
        Will keep the last modified timestamp from the source file (if any). Will use the Exchange.FILE_LAST_MODIFIED header to located the timestamp. This header can contain either a java.util.Date or long with the timestamp. If the timestamp exists and the option is enabled it will set this timestamp on the written file. Note: This option only applies to the file producer. You cannot use this option with any of the ftp producers. The option will be converted to a boolean type. Default: false Group: producer (advanced)
      • moveExistingFileStrategy

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder moveExistingFileStrategy​(Object moveExistingFileStrategy)
        Strategy (Custom Strategy) used to move file with special naming token to use when fileExist=Move is configured. By default, there is an implementation used if no custom strategy is provided. The option is a: org.apache.camel.component.file.strategy.FileMoveExistingStrategy type. Group: producer (advanced)
      • moveExistingFileStrategy

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder moveExistingFileStrategy​(String moveExistingFileStrategy)
        Strategy (Custom Strategy) used to move file with special naming token to use when fileExist=Move is configured. By default, there is an implementation used if no custom strategy is provided. The option will be converted to a org.apache.camel.component.file.strategy.FileMoveExistingStrategy type. Group: producer (advanced)
      • autoCreate

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder autoCreate​(boolean autoCreate)
        Automatically create missing directories in the file's pathname. For the file consumer, that means creating the starting directory. For the file producer, it means the directory the files should be written to. The option is a: boolean type. Default: true Group: advanced
      • autoCreate

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder autoCreate​(String autoCreate)
        Automatically create missing directories in the file's pathname. For the file consumer, that means creating the starting directory. For the file producer, it means the directory the files should be written to. The option will be converted to a boolean type. Default: true Group: advanced
      • copyAndDeleteOnRenameFail

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder copyAndDeleteOnRenameFail​(boolean copyAndDeleteOnRenameFail)
        Whether to fallback and do a copy and delete file, in case the file could not be renamed directly. This option is not available for the FTP component. The option is a: boolean type. Default: true Group: advanced
      • copyAndDeleteOnRenameFail

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder copyAndDeleteOnRenameFail​(String copyAndDeleteOnRenameFail)
        Whether to fallback and do a copy and delete file, in case the file could not be renamed directly. This option is not available for the FTP component. The option will be converted to a boolean type. Default: true Group: advanced
      • renameUsingCopy

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder renameUsingCopy​(boolean renameUsingCopy)
        Perform rename operations using a copy and delete strategy. This is primarily used in environments where the regular rename operation is unreliable (e.g. across different file systems or networks). This option takes precedence over the copyAndDeleteOnRenameFail parameter that will automatically fall back to the copy and delete strategy, but only after additional delays. The option is a: boolean type. Default: false Group: advanced
      • renameUsingCopy

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder renameUsingCopy​(String renameUsingCopy)
        Perform rename operations using a copy and delete strategy. This is primarily used in environments where the regular rename operation is unreliable (e.g. across different file systems or networks). This option takes precedence over the copyAndDeleteOnRenameFail parameter that will automatically fall back to the copy and delete strategy, but only after additional delays. The option will be converted to a boolean type. Default: false Group: advanced
      • synchronous

        default FileEndpointBuilderFactory.AdvancedFileEndpointProducerBuilder synchronous​(boolean synchronous)
        Sets whether synchronous processing should be strictly used, or Camel is allowed to use asynchronous processing (if supported). The option is a: boolean type. Default: false Group: advanced