HostedProvider Element (ADF)

Contains elements that define one hosted event provider.

语法

<Providers>
    <HostedProvider>

Element Characteristics

Characteristic Description

Data type

None.

Default value

None.

Occurrence

Optional once or more per Providers element.

Updates

Can be added and deleted when updating the application.

Element Relationships

Relationship Elements

Parent element

Providers Element (ADF)

Child elements

ProviderName Element for HostedProvider (ADF)

ClassName Element for HostedProvider (ADF)

AssemblyName Element for HostedProvider (ADF)

SystemName Element for HostedProvider (ADF)

Schedule Element for HostedProvider (ADF)

ProviderTimeout Element (ADF)

Arguments Element for HostedProvider (ADF)

示例

The following example shows the definition of a hosted event provider. The event provider is named StockEP, and is implemented by the StockData.StockProvider class in the StockProvider.dll assembly. The event provider will run on the server specified by the %SYSNAME% parameter.

The event provider will start running at 10:00 PM on the day the instance is started, and will run every five minutes thereafter. If the event provider does not complete in 3 minutes, processing for the current interval is cancelled. The event provider takes a single argument that specifies the URL it uses as the event source.

<HostedProvider>
    <ProviderName>StockEP</ProviderName>
    <ClassName>StockData.StockProvider</ClassName>
    <AssemblyName>
    C:\EventProviders\CustomProviders\StockProvider.dll
    </AssemblyName>
    <SystemName>%SYSNAME%</SystemName>
    <Schedule>
        <StartTime>22:00:00</StartTime>
        <Interval>P0DT00H05M00S</Interval>
     </Schedule>
    <ProviderTimeout>PT3M</ProviderTimeout>
    <Arguments>
        <Argument>
            <Name>URL</Name>
            <Value>www.contoso.com/stockvalues</Value>
        </Argument>
    </Arguments>
</HostedProvider>

请参阅

参考

Application Definition File Reference

其他资源

定义宿主事件提供程序
更新实例和应用程序

帮助和信息

获取 SQL Server 2005 帮助