- Avoid Object Relational Mappers. They create complex queries that hard to optimize.
- Analyze locks. Row level locking is better than table level locking. Use async replication
- Single database choke point? Create parallel databases and let a driver select between them.
- Use metrics. Visualize what's happening to your system using one of the many monitoring packages.
- Lack of Feature Flags. Turn off features via a flag so when a spike hits less important features can be turned off to reduce load.
Wednesday, September 21, 2011
Database scalability tips
Etiketter:
Database,
Scalability
Friday, September 16, 2011
WS consumer performance tips
WS call are always expensive with the overhead each call require. Caching is a way to avoid unneccesary WS calls and improve performance:
The general rules for cacheing are:
• Always cache WS data which is not very dynamic in nature, bu at the same time make sure you don't get functional error by caching data that needs to be fetched fresh.
• Use the ASP.NET cache with a timeout instead of some custom cache like hash table
• Invalidate cache based on business rules or time-out
• Consumers of Web services have the option of calling web services asynchronously or synchronously. Your code should call a Web service asynchronously only when you want to avoid blocking the client while a web service call is in progress. If you are not careful, you can use a greater number of worker and I/O threads cause by asynchronous WS calls, which negatively affects performance. It is also slower to call a service asynchronously; therefore, you should avoid doing so unless your client application needs to do something else while the service is invoked.
© Copyright 2011, Tomas Elfving
Etiketter:
Web service performance
Subscribe to:
Posts (Atom)