0

In an Asp.net2.0 application I have stored the object state in the session. The object state will be changing frequently. The size of the object is also large. Will this lead to "server error" in the application?

And also suggest whether there is any other way to store the state of the object which is large in size.

1
  • And define how many visitors you expect: large object * few visitors = still reasonably memory consumption. Commented Mar 29, 2011 at 15:36

2 Answers 2

1

I would highly recommend that you persist this to your database and pull the parts out that you need, when you need it.

Sign up to request clarification or add additional context in comments.

1 Comment

this seems the most sensible.
0

If the object is application and not user specific then you could store it in the Application State.

Application["ObjectName"] = Object;

3 Comments

@Karthik: Then what about the Cache, persisted with a user specific key?
but the values will be changing frequently as it is a real time application. so, will cache be useful for that?,
@Karthik: You update the cache with the latest instance of an object when you change its state (if its not a reference type) and simply access the cached instance from places that require 'reading' of the object. And how large is large?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.