Class LocalFileTimestampVersionFinder

  • All Implemented Interfaces:
    org.apache.druid.data.SearchableVersionedDataFinder<URI>, org.apache.druid.segment.loading.URIDataPuller

    public class LocalFileTimestampVersionFinder
    extends LocalDataSegmentPuller
    implements org.apache.druid.data.SearchableVersionedDataFinder<URI>
    • Constructor Detail

      • LocalFileTimestampVersionFinder

        public LocalFileTimestampVersionFinder()
    • Method Detail

      • getLatestVersion

        public URI getLatestVersion​(URI uri,
                                    @Nullable
                                    Pattern pattern)
        Matches based on a pattern in the file name. Returns the file with the latest timestamp.
        Specified by:
        getLatestVersion in interface org.apache.druid.data.SearchableVersionedDataFinder<URI>
        Parameters:
        uri - If it is a file, then the parent is searched. If it is a directory, then the directory is searched.
        pattern - The matching filter to down-select the file names in the directory of interest. Passing `null` results in matching any file
        Returns:
        The URI of the most recently modified file which matches the pattern, or `null` if it cannot be found