Try Playground
Show / Hide Table of Contents

Class CacheSyncDependency

A client application can have more than one cache instance initialized. CacheSyncDependency keeps the items present in one cache synchronized with the items present in another cache.

Inheritance
System.Object
CacheSyncDependency
Assembly: Alachisoft.NCache.Client.dll
Syntax
[Serializable]
[Obsolete("This API is deprecated and will be removed in a future release. This feature is being retired and will not be continued in future versions.", false)]
public class CacheSyncDependency : ICompactSerializable, IBinaryProtocolSerializable
Remarks

You can add items with the CacheSyncDependency to your application's cache using the ICache interface and the Insert method.

When you add an item to an application's ICache object with CacheSyncDependency, it monitors the remote cache (the cache you want your local cache to be synchronized with) for changes. As soon as an item is updated in or removed from the remote cache, this change is automatically updated in the local cache if the CacheSyncDependency was provided with the cache items. This helps you keep your local cache synchronized with the remote cache all the time.

Constructors

Name Description
CacheSyncDependency(String, String)

Initializes a new instance of the CacheSyncDependency with the specified parameters. Internally, it tries to initialize the remote cache. If the cache cannot be initialized, it throws the exception describing the cause of failure.

The remote cache must be running as OutProc, even if it is on the same machine. The information to connect to the remote cache instance (like server-name and server-port) is picked from the client.ncconf file.

CacheSyncDependency(String, String, Credentials)

Initializes a new instance of the CacheSyncDependency with the specified parameters. Internally, it tries to initialize the remote cache. If the cache cannot be initialized, it throws the exception describing the cause of failure. The remote cache must be running as OutProc, even if it is on the same machine.

CacheSyncDependency(String, String, ServerInfo)

Initializes a new instance of the CacheSyncDependency with the specified parameters. Internally, it tries to initialize the remote cache. If the cache cannot be initialized, it throws the exception describing the cause of failure. The remote cache must be running as OutProc, even if it is on the same machine.

CacheSyncDependency(String, String, ServerInfo, Credentials)

Initializes a new instance of the CacheSyncDependency with the specified parameters. Internally, it tries to initialize the remote cache. If the cache cannot be initialized, it throws the exception describing the cause of failure. The remote cache must be running as OutProc, even if it is on the same machine.

Properties

Name Description
CacheId

The unique ID of the remote cache.

Credential

Specifies the user credentials for user authorization.

Key

The key of the item in the remote cache with which the local cache item needs to be synchronized.

Port

The server port that is used by the clients to connect to the server.

Server

The name of the server where the remote cache is running.

Methods

Name Description
Deserialize(CompactReader)

Loads the state from the passed reader object.

Serialize(CompactWriter)

Saves the state to the passed reader object.

In This Article
  • Constructors
  • Properties
  • Methods

Contact Us

PHONE

+1 (214) 764-6933   (US)

+44 20 7993 8327   (UK)

 
EMAIL

sales@alachisoft.com

support@alachisoft.com

NCache
  • NCache Enterprise
  • NCache Professional
  • Edition Comparison
  • NCache Architecture
  • Benchmarks
Download
Pricing
Try Playground

Deployments
  • Cloud (SaaS & Software)
  • On-Premises
  • Kubernetes
  • Docker
Technical Use Cases
  • ASP.NET Sessions
  • ASP.NET Core Sessions
  • Pub/Sub Messaging
  • Real-Time ASP.NET SignalR
  • Internet of Things (IoT)
  • NoSQL Database
  • Stream Processing
  • Microservices
Resources
  • Magazine Articles
  • Third-Party Articles
  • Articles
  • Videos
  • Whitepapers
  • Shows
  • Talks
  • Blogs
  • Docs
Customer Case Studies
  • Testimonials
  • Customers
Support
  • Schedule a Demo
  • Forum (Google Groups)
  • Tips
Company
  • Leadership
  • Partners
  • News
  • Events
  • Careers
Contact Us

  • EnglishChinese (Simplified)FrenchGermanItalianJapaneseKoreanPortugueseSpanish

  • Contact Us
  •  
  • Sitemap
  •  
  • Terms of Use
  •  
  • Privacy Policy
� Copyright Alachisoft 2002 - 2025. All rights reserved. NCache is a registered trademark of Diyatech Corp.
Back to top