Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6732737
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:41:09+00:00 2026-05-26T10:41:09+00:00

This is the order of my code: I make multiple task.factory.startnew(()=> myFunction(myObject, httpSessionState)) I

  • 0

This is the order of my code:

I make multiple

task.factory.startnew(()=> myFunction(myObject, httpSessionState))

I send the System.Web.SessionState.HttpSessionState to myFunction because i dont wait for the tasks to end , so they run in background, and I can’t get session inside myFunction because

 System.Web.HttpContext.Current = null.

myFunction calls webservices and stores their result in the httpSessionState object

then I make several ajax calls to get the session values from the server, until I have all the desired values.

PROBLEM:

I cant explain why users get de-logged from time to time. I assume the session becomes null.
All users get delogged at the same time. All session objects probably become null

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:41:09+00:00Added an answer on May 26, 2026 at 10:41 am

    This usually happens (loosing sessions) when the server process
    w3wp.exe restarts (Asp.net application pool).

    Usually hosting providers have an upper memory limit per application pool that when reached restarts the pool to avoid hogging the server.

    So basically this could mean that your application is eating to much memory (or has memory leaks).

    In your situation, this could mean that the Tasks you spawn are too heavy or leaking, which would indicate that you need to check myFunction().

    If you need to limit the degree of concurrency to fine tune memory usage:
    http://msdn.microsoft.com/en-us/library/ee789351.aspx

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I got this code in order to build an url for the link using
this is some code that SDL requires in visual studios 2005 in order for
This is my code: $query = mysql_query(SELECT * FROM books ORDER BY id) or
I have this code: var totalAmt=0; for (i in orders) { order=orders[i]; if (order.status
Is there anyway this code can be refactored? The only difference is the order
i have this recursive code <ul> <% sql=SELECT * FROM cats ORDER BY orderid
I've installed (in this order): 64bit Windows7, 64bit Visual Studio 2008, Microsoft Free Web
I have multiple views which make the same NSURLRequest/NSURLConnection request . Ideally, in order
I have this code in jquery : $(#order_btn).click(function(){ var totalprice = $(.price_amount).text(); $(#totalprice).val(totalprice); });
I have this code: db = C:\Dokumente und Einstellungen\hom\Anwendungsdaten\BayWotch4\Neuer Ordner\baywotch.db5 TextExportFile = C:\Dokumente und

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.