Skip to content

SPSearchCrawlerImpactRule

dscbot edited this page Mar 17, 2023 · 9 revisions

SPSearchCrawlerImpactRule

Parameters

Parameter Attribute DataType Description Allowed Values
ServiceAppName Key String Search Service Application Name
Name Key String The Site for the crawl impact rule
Behavior Read String The Behavior (RequestLimit or WaitTime) for this crawl impact rule
RequestLimit Write UInt32 The RequestLimit setting for the crawl impact rule
WaitTime Write UInt32 The WaitTime setting for the crawl impact rule
Ensure Write String Ensure the crawl rule is Present or Absent Present, Absent

Description

Type: Distributed Requires CredSSP: No

This resource is responsible for managing the search crawl impact rules in the search service application. You can create new rules, change existing rules and remove existing rules.

The default value for the Ensure parameter is Present. When you omit this parameter the crawl rule is created.

Examples

Example 1

This example shows how to create a Crawler Impact Rule with a Request Limit

Configuration Example
{
    param
    (
        [Parameter(Mandatory = $true)]
        [PSCredential]
        $SetupAccount
    )

    Import-DscResource -ModuleName SharePointDsc

    node localhost
    {
        SPSearchCrawlerImpactRule IntranetCrawlerImpactRequestLimitRule
        {
            ServiceAppName       = "Search Service Application"
            Name                 = "https://intranet.sharepoint.contoso.com"
            RequestLimit         = 8
            Ensure               = "Present"
            PsDscRunAsCredential = $SetupAccount
        }
    }
}

Example 2

This example shows how to create a Crawler Impact Rule with a Wait Time

Configuration Example
{
    param
    (
        [Parameter(Mandatory = $true)]
        [PSCredential]
        $SetupAccount
    )

    Import-DscResource -ModuleName SharePointDsc

    node localhost
    {
        SPSearchCrawlerImpactRule IntranetCrawlerImpactWaitTimeRule
        {
            ServiceAppName       = "Search Service Application"
            Name                 = "https://intranet.sharepoint.contoso.com"
            WaitTime             = 60
            Ensure               = "Present"
            PsDscRunAsCredential = $SetupAccount
        }
    }
}
Clone this wiki locally