PostgreSQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsDatabasesPostgreSQL Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 22nd, 2012, 02:06 AM
LuckyURE LuckyURE is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2012
Posts: 1 LuckyURE User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 11 m 31 sec
Reputation Power: 0
Lightbulb ASP.Net Caching & PostgreSQL

Caching information in ASP.Net is very easy and works great. However, one particularly good feature, is the ability to use SQLCacheDependency.

For those of you that don't know what that it, is basically allows me to wire up a broker to the MSSQL server and watch a particular table. So, if nothing has changed in that table then a cache result can be served to the client. As soon as the table changes the broker notifies my ASP.Net application so that it knows the next request should contain fresh data. Neat huh!

Unfortunately it seems that ASP.Net can only use MSSQL for this particular feature. My question is, is there a way to use this feature with PostgreSQL or at least provide a similar methodology to get a similar feature set/result?

Much appreciation to those who take the time on this one in advance.

Reply With Quote
  #2  
Old April 22nd, 2012, 02:15 AM
shammat shammat is offline
Contributing User
Dev Shed Frequenter (2500 - 2999 posts)
 
Join Date: Oct 2003
Location: Germany
Posts: 2,685 shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level)shammat User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 1 Month 3 Weeks 3 Days 19 h 57 m 3 sec
Reputation Power: 284
I know nothing about .Net or that broker.

But if can hook into the way SQLCacheDependency works, you might be able to write your own "listener" using PostgreSQL's "notify" and "listen" feature:

http://www.postgresql.org/docs/current/static/sql-listen.html
http://www.postgresql.org/docs/current/static/sql-notify.html

You would need to write a trigger for each table you want to watch. That trigger would then send a NOTIFY message which your daemon can receive and e.g. invalidate the cache.

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesPostgreSQL Help > ASP.Net Caching & PostgreSQL

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap