locked
Session conflict on Azure RRS feed

  • Question

  • Hi there,

    I'm desperate here ...

    I have an azure website in which i'm using custom membership and sessions.

    The membership works well, but when my partner and myself are accessing the same page , sometimes it swaps our info which I keep in session variables.

    I've changed my session state from 'In Proc' to 'custom' with using Azure cache co-locate etc.

    The problem still occurs.

    What else can I do?

    HELP PLEASE...

    Tuesday, December 23, 2014 6:47 PM

Answers

  • Hi Sir,

    How did you use the session ? Did you use the Azure RedisSessionStateProvider cache?

    http://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-session-state-caching/

    Also, you could see this post:

    http://stackoverflow.com/questions/13656758/how-does-windows-azure-websites-handle-session

    Regards,

    Will


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, December 24, 2014 2:17 AM
  • Usually using sessions over distributed cache / managed cache service is quite a straight forward thing.

    It would be great if you explain a bit more on what conflict you exactly facing for session objects. how have you used session objects to store your custom data?

    Have you installed Windows Azure cache nuGet? 

    You might want to make sure that the session provider is configured correctly - something like this

    <system.web>
      <sessionState mode="Custom" customProvider="AFCacheSessionStateProvider">
        <providers>
          <add name="AFCacheSessionStateProvider" 
            type="Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider,
                  Microsoft.Web.DistributedCache" 
            cacheName="default" 
            dataCacheClientName="default"/>
        </providers>
      </sessionState>
    </system.web>

    Here is the help article from MSDN which explains usage of managed cache for sessions in really great way

    http://azure.microsoft.com/en-us/documentation/articles/cache-dotnet-how-to-use-service/#store-session


    Bhushan | http://www.passionatetechie.blogspot.com | http://twitter.com/BhushanGawale

    • Marked as answer by Manu Rekhar Monday, December 29, 2014 6:52 AM
    Wednesday, December 24, 2014 7:34 AM

All replies

  • Hi Sir,

    How did you use the session ? Did you use the Azure RedisSessionStateProvider cache?

    http://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-session-state-caching/

    Also, you could see this post:

    http://stackoverflow.com/questions/13656758/how-does-windows-azure-websites-handle-session

    Regards,

    Will


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Wednesday, December 24, 2014 2:17 AM
  • Usually using sessions over distributed cache / managed cache service is quite a straight forward thing.

    It would be great if you explain a bit more on what conflict you exactly facing for session objects. how have you used session objects to store your custom data?

    Have you installed Windows Azure cache nuGet? 

    You might want to make sure that the session provider is configured correctly - something like this

    <system.web>
      <sessionState mode="Custom" customProvider="AFCacheSessionStateProvider">
        <providers>
          <add name="AFCacheSessionStateProvider" 
            type="Microsoft.Web.DistributedCache.DistributedCacheSessionStateStoreProvider,
                  Microsoft.Web.DistributedCache" 
            cacheName="default" 
            dataCacheClientName="default"/>
        </providers>
      </sessionState>
    </system.web>

    Here is the help article from MSDN which explains usage of managed cache for sessions in really great way

    http://azure.microsoft.com/en-us/documentation/articles/cache-dotnet-how-to-use-service/#store-session


    Bhushan | http://www.passionatetechie.blogspot.com | http://twitter.com/BhushanGawale

    • Marked as answer by Manu Rekhar Monday, December 29, 2014 6:52 AM
    Wednesday, December 24, 2014 7:34 AM