locked
Cache for multiple users in same browser session RRS feed

  • Question

  • User1159440550 posted

    I'm not sure if my title correctly explains what I'm looking for but I'm currently working on a project using VS2008 C# with Enterprise Library 4.1 (DB2 back end) and my caching block works fine for one user at a time.  It's come to my attention that there are users who will have IE and use multple tabs and login as different users, etc.  What I've noticed with my current default cache setup is that info with the same cache name is overwritten in memory (as it should be with a single user too).  Is there a way to still keep everything in memory but separate the different cache info with a unique value (like the UserID?).  Create separate instances somehow?  I've read about the isolated storage, but I haven't been able to find a good explanation on how to set this up, or if this will solve my problem.  That, and I'm trying to stay away from the database entirely for the cache.

     Any help or suggestions are welcome!  Thanks for your time!

    Tuesday, May 19, 2009 11:01 AM

All replies

  • User1159440550 posted

    Another site told me to just concatenate the userID to the front of the cache ID.  I thought of this too, but felt that this was more of a hack than good coding.  Seeing I haven't heard any other ideas this will probably be my method. 

    This still doesn't solve the issue of deleting only a specific UserID's items in cache.  Using FLUSH will delete everything.
    Anyone know if there's a way to incorporate enumeration in the enterprise library cache?

     Thanks.

    Thursday, May 21, 2009 4:08 PM