Read data everytime from web.config or save it in Cache

Last post 09-26-2007 5:49 AM by PareshDehadray. 0 replies.

Sort Posts:

  • Read data everytime from web.config or save it in Cache

    09-26-2007, 5:49 AM

    Sir,

     

    In my project I have around 20 appsettings which I store in appSettings section in web.config. For reading the values from web.config I use the System.Configuration.ConfigurationManager class.

     

    What is the good practice from following?

     
    1. Every time read value from web.config using  System.Configuration.ConfigurationManager class
     
    1. On Application_Start read the data from web.config and store in HttpContext.Current.Cache and now onwardes read values from Cache.
     

    Are there any performace issues to read every time from web.config?  or both performances are same.

     

    Please suggest the answer.

     

    Thanks in advance

     

    Paresh

     

Page 1 of 1 (1 items)
Microsoft Communities
Page view counter