O
Omega
I'm interested in seeing a bit of discussion about using singletons in
ASP.NET 2.0.
Currently I've designed a singleton that gets a reference to it's
single instance stored inside the ASP.NET application object. This is
done to persist and make available live information across multiple
sessions.
I've read a little bit (almost nothing) about how singletons don't play
nicely in clustered scenarios and would like to hear more on the
subject.
As mentioned above, my class is only a singleton because it's only
reference is stored in the application object. Because of this, I
could just as easily NOT write singleton and simply instantiate the
same object in the same place as where I'm storing the reference
(application handler on application start).
application.
How does clustering really impact a singleton or a single instance of a
class stored in the application object?
ASP.NET 2.0.
Currently I've designed a singleton that gets a reference to it's
single instance stored inside the ASP.NET application object. This is
done to persist and make available live information across multiple
sessions.
I've read a little bit (almost nothing) about how singletons don't play
nicely in clustered scenarios and would like to hear more on the
subject.
As mentioned above, my class is only a singleton because it's only
reference is stored in the application object. Because of this, I
could just as easily NOT write singleton and simply instantiate the
same object in the same place as where I'm storing the reference
(application handler on application start).
makes available a facility to put code that lives throughout theFrom what I can see, the application object is the only place ASP.NET
application.
How does clustering really impact a singleton or a single instance of a
class stored in the application object?