public interface Fetcher<StartContextT extends FetcherContext.StartContext,PreFetchContextT extends FetcherContext.PreFetchContext,FetchContextT extends FetcherContext.FetchContext,PostContextT extends FetcherContext.PostFetchContext,StopContextT extends FetcherContext.StopContext> extends Component
start() for-each-phase: startFetcher() for-each-fetch-input: fetch() end-for-each-fetch-input end-for-each-phase stop()
Phases allow a Connector to define processing steps. For example, PhaseA might be responsible for fetching content IDs from a large content repository. PhaseB might then handle fetching the actual binary content for the items emitted from PhaseA. By breaking up the overall fetch into multiple Phases, more flexible crawling strategies are possible.
| Modifier and Type | Method and Description |
|---|---|
default FetchResult |
fetch(FetchContextT context)
This is the primary fetch method for a crawler-like connector (for example, a file system or web connector).
|
default PostFetchResult |
postFetch(PostContextT context)
Deprecated.
The node running post fetch might be a different node from pre-fetch
|
default PreFetchResult |
preFetch(PreFetchContextT context)
Deprecated.
use fetch the input with “seed” input instead.
|
default StartResult |
start(StartContextT context) |
default StopResult |
stop(StopContextT context) |
default StartResult start(StartContextT context)
@Deprecated default PreFetchResult preFetch(PreFetchContextT context)
context - the PreFetch contextdefault FetchResult fetch(FetchContextT context)
context - the Fetch context@Deprecated default PostFetchResult postFetch(PostContextT context)
context - the post fetch context.default StopResult stop(StopContextT context)