Class ListSFTP

java.lang.Object
org.apache.nifi.components.AbstractConfigurableComponent
org.apache.nifi.processor.AbstractSessionFactoryProcessor
org.apache.nifi.processor.AbstractProcessor
All Implemented Interfaces:
org.apache.nifi.components.ConfigurableComponent, org.apache.nifi.processor.Processor, org.apache.nifi.processor.VerifiableProcessor

@PrimaryNodeOnly @TriggerSerially @InputRequirement(INPUT_FORBIDDEN) @Tags({"list","sftp","remote","ingest","source","input","files"}) @CapabilityDescription("Performs a listing of the files residing on an SFTP server. For each file that is found on the remote server, a new FlowFile will be created with the filename attribute set to the name of the file on the remote server. This can then be used in conjunction with FetchSFTP in order to fetch those files.") @SeeAlso({FetchSFTP.class,GetSFTP.class,PutSFTP.class}) @WritesAttribute(attribute="sftp.remote.host",description="The hostname of the SFTP Server") @WritesAttribute(attribute="sftp.remote.port",description="The port that was connected to on the SFTP Server") @WritesAttribute(attribute="sftp.listing.user",description="The username of the user that performed the SFTP Listing") @WritesAttribute(attribute="file.owner",description="The numeric owner id of the source file") @WritesAttribute(attribute="file.group",description="The numeric group id of the source file") @WritesAttribute(attribute="file.permissions",description="The read/write/execute permissions of the source file") @WritesAttribute(attribute="file.size",description="The number of bytes in the source file") @WritesAttribute(attribute="file.lastModifiedTime",description="The timestamp of when the file in the filesystem waslast modified as \'yyyy-MM-dd\'T\'HH:mm:ssZ\'") @WritesAttribute(attribute="filename",description="The name of the file on the SFTP Server") @WritesAttribute(attribute="path",description="The fully qualified name of the directory on the SFTP Server from which the file was pulled") @WritesAttribute(attribute="mime.type",description="The MIME Type that is provided by the configured Record Writer") @Stateful(scopes=CLUSTER, description="After performing a listing of files, the timestamp of the newest file is stored. This allows the Processor to list only files that have been added or modified after this date the next time that the Processor is run. State is stored across the cluster so that this Processor can be run on Primary Node only and if a new Primary Node is selected, the new node will not duplicate the data that was listed by the previous Primary Node.") @DefaultSchedule(strategy=TIMER_DRIVEN, period="1 min") public class ListSFTP extends ListFileTransfer
  • Field Details

    • PROPERTY_DESCRIPTORS

      private static final List<org.apache.nifi.components.PropertyDescriptor> PROPERTY_DESCRIPTORS
    • fileFilter

      private volatile Predicate<FileInfo> fileFilter
  • Constructor Details

    • ListSFTP

      public ListSFTP()
  • Method Details