M
Mark S.
Hello,
The app in question is lives on a Windows 2003 server with .NET 2.0 running
IIS 6. The page of the app in question processes 2000 get requests a second
during peak loads.
The app uses a Static Object. In this object is a generic List<String>. For
every page request this list is looped over only reading not writing each
value.
Question is, would it be a better practices to create an copy of the List
before looping over it?
List<string> myList = MyStaticObject.myList; If this is just a reference? If
so, then it would seem to be less efficient? If that's true, would it be
better to deep clone the list and then loop?
Testing on the dev machine under stress loading hasn't shown any light on
the best practices way to go to reach optimal efficiency.
Thank you in advance for your thoughts.
M
The app in question is lives on a Windows 2003 server with .NET 2.0 running
IIS 6. The page of the app in question processes 2000 get requests a second
during peak loads.
The app uses a Static Object. In this object is a generic List<String>. For
every page request this list is looped over only reading not writing each
value.
Question is, would it be a better practices to create an copy of the List
before looping over it?
List<string> myList = MyStaticObject.myList; If this is just a reference? If
so, then it would seem to be less efficient? If that's true, would it be
better to deep clone the list and then loop?
Testing on the dev machine under stress loading hasn't shown any light on
the best practices way to go to reach optimal efficiency.
Thank you in advance for your thoughts.
M

