Commited Write

Oct 17, 2008 at 4:59 PM
I am wondering how shared cache manages commited writes

I have a dataset which I stick into the cache, it expires after a couple of minutes and lots of client access it.

On it returning nothing from the cache I get a new dataset and stick it into the cache.

With indexus it then locks everything accessing that until the write is complete. The issue with this is, it causes the whole application to hang.

MS Velocity appears to have a commit once write is complete, rather than lock the item until the write is complete.

Is there a way around this issue as its causing me some serious problems when there are nay number of users online
Oct 17, 2008 at 5:18 PM

well I have to say I'm a bit surprised from the behavior you described then until now this were
not a problem / issue at all. Shared Cache is locking down the item but this should not be a reason
why your applications starts to hang. 

are you able to make a small solution with some sample code and send me this?

please send me also a bit more information about your application (URL would be nice, Amount of Servers, Shared Cache Version, usage replicated or distributed etc.) 

p.s. may this is the reason why MS Velocity is that slow :S
Oct 17, 2008 at 9:40 PM
I'll get some sample code and post it here shortly

I think my issue is realted to the fact there are a number of cached datasets on the front page, which from time to time expire at the same time.

The issue is that sometimes there might be several clients attempting to update the same item.

With Velocity, as I see it, becuase it doesnt commit or lock the item until its written to the cluster, it doesnt hang other clients trying to access it.
Whereas with IndexUs becuase there are a number of clients trying to update at the same time, it hangs.

Perhaps there is a better way to do what im trying to do, rather than fill the DS after its been emptied (I have also tried recording the expiry time into a class with the DS as a property of the class and sticking that into the cache and then replacing that item after getting from the cache and comparing its expiry time. That results in slightly better performance)