Class RemoteFileStreamingInboundChannelAdapterSpec<F,S extends RemoteFileStreamingInboundChannelAdapterSpec<F,S,MS>,MS extends AbstractRemoteFileStreamingMessageSource<F>>

java.lang.Object
org.springframework.beans.factory.config.AbstractFactoryBean<T>
org.springframework.integration.dsl.IntegrationComponentSpec<S,H>
org.springframework.integration.dsl.MessageSourceSpec<S,MS>
org.springframework.integration.file.dsl.RemoteFileStreamingInboundChannelAdapterSpec<F,S,MS>
Type Parameters:
F - the target file type.
S - the target RemoteFileStreamingInboundChannelAdapterSpec implementation type.
MS - the target AbstractRemoteFileStreamingMessageSource implementation type.
All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanClassLoaderAware, org.springframework.beans.factory.BeanFactoryAware, org.springframework.beans.factory.DisposableBean, org.springframework.beans.factory.FactoryBean<MS>, org.springframework.beans.factory.InitializingBean, org.springframework.context.Lifecycle, org.springframework.context.Phased, org.springframework.context.SmartLifecycle, org.springframework.integration.dsl.ComponentsRegistration

public abstract class RemoteFileStreamingInboundChannelAdapterSpec<F,S extends RemoteFileStreamingInboundChannelAdapterSpec<F,S,MS>,MS extends AbstractRemoteFileStreamingMessageSource<F>> extends org.springframework.integration.dsl.MessageSourceSpec<S,MS> implements org.springframework.integration.dsl.ComponentsRegistration
A MessageSourceSpec for an AbstractRemoteFileStreamingMessageSource.
Since:
5.0
  • Field Summary

    Fields inherited from class org.springframework.integration.dsl.IntegrationComponentSpec

    PARSER, target

    Fields inherited from class org.springframework.beans.factory.config.AbstractFactoryBean

    logger

    Fields inherited from interface org.springframework.beans.factory.FactoryBean

    OBJECT_TYPE_ATTRIBUTE

    Fields inherited from interface org.springframework.context.SmartLifecycle

    DEFAULT_PHASE
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    Configure a FileListFilter to be applied to the remote files before copying them.
    filterFunction(Function<F,Boolean> filterFunction)
     
    maxFetchSize(int maxFetchSize)
    Specify the maximum number of remote files that will be fetched on each fetch attempt.
    abstract S
    Configure a simple pattern filter (e.g.
    abstract S
    Configure a regex pattern filter (e.g.
    remoteDirectory(String remoteDirectory)
    Specify the full path to the remote directory.
    remoteDirectory(Function<org.springframework.messaging.Message<?>,String> remoteDirectoryFunction)
    Specify a function that is invoked to determine the full path to the remote directory.
    remoteDirectory(org.springframework.expression.Expression remoteDirectoryExpression)
    Specify an expression that evaluates to the full path to the remote directory.
    remoteFileSeparator(String remoteFileSeparator)
    Configure the file name path separator used by the remote system.

    Methods inherited from class org.springframework.integration.dsl.MessageSourceSpec

    messageHeaders

    Methods inherited from class org.springframework.integration.dsl.IntegrationComponentSpec

    _this, createInstance, destroyInstance, doGet, get, getId, getObjectType, getPhase, id, isAutoStartup, isRunning, start, stop, stop

    Methods inherited from class org.springframework.beans.factory.config.AbstractFactoryBean

    afterPropertiesSet, destroy, getBeanFactory, getBeanTypeConverter, getEarlySingletonInterfaces, getObject, isSingleton, setBeanClassLoader, setBeanFactory, setSingleton

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • RemoteFileStreamingInboundChannelAdapterSpec

      public RemoteFileStreamingInboundChannelAdapterSpec()
  • Method Details

    • remoteFileSeparator

      public S remoteFileSeparator(String remoteFileSeparator)
      Configure the file name path separator used by the remote system. Defaults to '/'.
      Parameters:
      remoteFileSeparator - the remoteFileSeparator.
      Returns:
      the spec.
    • remoteDirectory

      public S remoteDirectory(String remoteDirectory)
      Specify the full path to the remote directory.
      Parameters:
      remoteDirectory - the remoteDirectory.
      Returns:
      the spec.
      See Also:
    • remoteDirectory

      public S remoteDirectory(org.springframework.expression.Expression remoteDirectoryExpression)
      Specify an expression that evaluates to the full path to the remote directory.
      Parameters:
      remoteDirectoryExpression - The remote directory expression.
      Returns:
      the spec.
    • remoteDirectory

      public S remoteDirectory(Function<org.springframework.messaging.Message<?>,String> remoteDirectoryFunction)
      Specify a function that is invoked to determine the full path to the remote directory.
      Parameters:
      remoteDirectoryFunction - The remote directory function.
      Returns:
      the spec.
    • filter

      public S filter(FileListFilter<F> filter)
      Configure a FileListFilter to be applied to the remote files before copying them.
      Parameters:
      filter - the filter.
      Returns:
      the spec.
    • filterExpression

      public S filterExpression(String expression)
      Parameters:
      expression - the SpEL expression for files filtering.
      Returns:
      the spec.
      See Also:
    • filterFunction

      public S filterFunction(Function<F,Boolean> filterFunction)
      Parameters:
      filterFunction - the Function for files filtering.
      Returns:
      the spec.
      See Also:
    • maxFetchSize

      public S maxFetchSize(int maxFetchSize)
      Specify the maximum number of remote files that will be fetched on each fetch attempt. A small number is recommended when multiple application instances are running, to avoid one instance from "grabbing" all the files.
      Parameters:
      maxFetchSize - the max fetch size.
      Returns:
      the spec.
      See Also:
      • MessageSourceManagement.setMaxFetchSize(int)
    • getComponentsToRegister

      public Map<Object,String> getComponentsToRegister()
      Specified by:
      getComponentsToRegister in interface org.springframework.integration.dsl.ComponentsRegistration
    • patternFilter

      public abstract S patternFilter(String pattern)
      Configure a simple pattern filter (e.g. '*.txt').
      Parameters:
      pattern - the pattern.
      Returns:
      the spec.
      See Also:
    • regexFilter

      public abstract S regexFilter(String regex)
      Configure a regex pattern filter (e.g. '[0-9].*.txt').
      Parameters:
      regex - the regex.
      Returns:
      the spec.
      See Also: