Skip to main content

GenericDelayResolver

Apply delay per time schedule.

Notesโ€‹

Applies configurable crawl delays based on time schedules. Supports a default delay, optional time-range-based schedules (by day of week, day of month, or time of day), and an option to ignore the crawl delay specified in robots.txt.

Examplesโ€‹

The following example set the minimum delay between each document download on a given site to 5 seconds, no matter what the crawler robots.txt may say, excepted on weekend, where it is more agressive (1 second).

class: GenericDelayResolver
defaultDelay: 5000
ignoreRobotsCrawlDelay: true
scope: SITE
schedules:
- dayOfWeekRange:
start: SAT
end: SUN
delay: 1000

Usageโ€‹

Full configuration skeleton, with every option and its default
class: GenericDelayResolver
defaultDelay: 0
ignoreRobotsCrawlDelay: false
schedules:
- dayOfMonthRange: {}
dayOfWeekRange: {}
delay: 0
timeRange: {}
scope: CRAWLER

Propertiesโ€‹

PropertyTypeRequiredDefault
defaultDelayintegerNo3000
ignoreRobotsCrawlDelaybooleanNofalse
schedulesDelaySchedule[]No-
scopeenumNoCRAWLER

Property Detailsโ€‹

defaultDelayโ€‹

The default delay in milliseconds.

ignoreRobotsCrawlDelayโ€‹

By default the crawl delay specified in robots.txt takes precedence over custom settings. Check to disable robot delay instructions.

schedulesโ€‹

Have different delays at different time.

scopeโ€‹

The delay scope.

Allowed Valuesโ€‹

  • CRAWLER
  • SITE
  • THREAD