Skip to main content

SegmentCountUrlFilter

Filter by the number of reference segments.

Notes

Filters URLs based on the number of path segments (or duplicate segments) in the reference. URLs exceeding the configured segment count threshold are included or excluded depending on the onMatch setting.

Examples

The above example will reject URLs with more than 5 forward slashes after the domain.

class: SegmentCountUrlFilter
onMatch: EXCLUDE
count: 5

Usage

Full configuration skeleton, with every option and its default
class: SegmentCountUrlFilter
count: 0
duplicate: false
onMatch: INCLUDE
separator: string

Properties

PropertyTypeRequiredDefault
countintegerNo10
duplicatebooleanNofalse
onMatchenumNoINCLUDE
separatorstringNo/

Property Details

count

Minimum number of segments.

duplicate

Use this option to count the number of duplicate segments instead.

onMatch

What to do with a reference once its segment count has been reached.

Allowed Values

  • INCLUDE
  • EXCLUDE

separator

Regular expression matching an alternate segment separator (default is: /)