Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations dencom on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How much of a performance hit is an XML-driven WebControl?

Status
Not open for further replies.

afroblanca

Programmer
Jul 15, 2005
67
US
Here's the situation -

I'm writing a custom WebControl that accepts a number of parameters to determine how it behaves. Now, I could take accept these parameters through Properties in the WebControl itself. However, the number and complexity of the parameters would seem to necessitate a structured data format like XML. However, I'm concerned about performance. Assuming that this control lives on the homepage of a website, what kind of a performance hit could I expect if I have the control read its configuration data from an XML file? If the performance hit is significant, what steps can I take to mitigate this? I should mention that I'm not in favor of using any of .NET's server-side caching objects.
 
When you add the webcontrol to your page declare it as shared. It will retain the data so you will only have to load it the first time, and then it can be used for all users, or you could cache the data that you want to put in the contorl so each user's webcontrol will be independet of the other users. This way you will have to hit the file for each user once.

Babloome
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top