다음을 통해 공유


SqlCacheDependencyDatabase.PollTime 속성

정의

데이터베이스 테이블에서 변경 내용을 폴링하는 SqlCacheDependency 빈도를 가져오거나 설정합니다.

public:
 property int PollTime { int get(); void set(int value); };
[System.Configuration.ConfigurationProperty("pollTime", DefaultValue=60000)]
public int PollTime { get; set; }
[<System.Configuration.ConfigurationProperty("pollTime", DefaultValue=60000)>]
member this.PollTime : int with get, set
Public Property PollTime As Integer

속성 값

데이터베이스 폴링 시간(밀리초)입니다.

특성

예제

다음 코드 예제에서는 속성을 사용 하는 방법을 보여 있습니다 PollTime .


// Get the current PollTime property value.
Int32 pollTimeValue = sqlCdd.PollTime;

// Set the PollTime property to 1000 milliseconds.
sqlCdd.PollTime = 1000;
' Get the current PollTime property value.
Dim pollTimeValue As Int32 = sqlCdd.PollTime

' Set the PollTime property to 1000 milliseconds.
sqlCdd.PollTime = 1000

설명

PollTime 속성을 사용하면 구성 파일에서 노드 요소의 add 특성에 pollTime 프로그래밍 방식으로 액세스하고 수정할 databases 수 있습니다.

ASP.NET 애플리케이션의 캐시에 저장된 항목과 특정 SQL Server 데이터베이스 테이블 간의 관계를 구성한 후 클래스 인스턴스는 테이블의 SqlCacheDependency 항목이 변경될 때 항목이 캐시에서 자동으로 업데이트되거나 제거되도록 테이블을 모니터링합니다. 모니터링은 에 지정된 빈도로 PollTime발생합니다.

적용 대상

추가 정보