Question

I have an asp.net-mvc3 website using nhibernate and SQL server. I have 2 web servers that are loaded balanced. This is a read heavy db (not so concerned with write performance), but as the queries are getting more and more complicated (lots of table joins) its slowing down performance considerably.

Based on comments I read , biggest win would be to put a distributed cache in front. I took a look for free options on windows that support nhibernate and I found NCache Express. I am going to obviously do a bunch of testing and playing around but I wanted to see (before i wasted a lot of time) if this express versions would limit me at all in terms of a workable solutions. I see the version comparisons here and I don't think I see any blockers but wanted to get feedback from anyone that has used NCache Express with nhibernate to see if there any issues.

Also, if there are alternative products suggestions for more efficiently solving this problem that would be great as well.

Was it helpful?

Solution

As mentioned before, you should first optimize your database, but of course you are already doing that.

I also work on a website with 2 servers and in the process of chosing a cache provider I've settled with MemcacheD. It is very robust and it is really simple to setup. NCache Expresse would work fine too, there is no mistery on it, but I recommend going with Memcache because NCache express has the 2 servers limit, so if you ever need to add an aditional node you'll have to change anyway.

Also, if your servers have Windows 2008 you should check Microsoft's AppFabric, it is very good.

OTHER TIPS

Use this to evaluate what features do you require that NCache offers e.g. SQL dependencies and stuff http://www.alachisoft.com/ncache/edition-comparison.html

Other than that i don't think you will required to upgrade

and regarding alternatives, i haven't used many so i cant say anything in this regard :)

PS: Replicated is great for read intensive applications and bad for write intensive.

You could try appfabric as the nhibernate 2nd level cache. You should run it on separate servers to your application nodes though.

Have you tried, Microsoft Velocity ?

http://msdn.microsoft.com/en-us/magazine/dd861287.aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top