Himberjack
Himberjack

Reputation: 5802

how to use a shared cache in asp.net

I have a DLL I developed and 2 web applications uses it. I want this DLL to store data in the cache but I want it to use its own cache and not duplicated it among the 2 web apps...

how can that be done? since HttpContext.current will reference to the current cache application (which in my case is 2).

I do not want duplications.

Thanks

Upvotes: 0

Views: 154

Answers (1)

RickNZ
RickNZ

Reputation: 18652

One way is to wrap your DLL in a Windows Service, and have your ASP.NET applications interact with it using named pipes or something similar.

You could also use web services by exposing your DLL through a website or web application of its own. It could be bound to localhost only, to prevent remote access.

Upvotes: 2

Related Questions