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

  • SEARCH
  • Home
  • 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 7160737
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T13:26:50+00:00 2026-05-28T13:26:50+00:00

My ASP.NET MVC 3 project slows to a crawl after adding the 51Degrees mobile

  • 0

My ASP.NET MVC 3 project slows to a crawl after adding the 51Degrees mobile detection library. The 51Degrees log file defined by <log logFile="~/bin/App_Data/51Log.txt" logLevel="Info" /> in the <fiftyOne> section reveals that the device library is reloaded for each request, adding a 2-3 seconds delay for each request:

2011-10-22T14:17:34.9863774Z - 8436 - Info - Loaded 14691 devices using 11640 strings in 1882ms
2011-10-22T14:17:50.8442844Z - 8436 - Info - Loaded 14691 devices using 11640 strings in 1820ms
2011-10-22T14:17:57.2756523Z - 8436 - Info - Loaded 14691 devices using 11640 strings in 1928ms
2011-10-22T14:18:01.0488681Z - 8436 - Info - Loaded 14691 devices using 11640 strings in 1886ms
2011-10-22T14:18:04.6790757Z - 8436 - Info - Loaded 14691 devices using 11640 strings in 1862ms

Furthermore, setting <fiftyOne> <log ... logLevel="Debug"> in web.config throws the following exception on start:

Storage scopes cannot be created when _AppStart is executing.

MVC 4 Update

Everything works perfectly if I create a blank ASP.NET MVC 4 application and add the latest 51Degrees 2.0.3.2 NuGet package. As expected, the log reflects that the binary data as only being loaded once despite multiple requests (51Degrees.mobi-Lite-2012.01.05.dat).

Carefully optimistic, I copied all my main MVC 3 project code over to a new ASP.NET MVC 4 project and re-added the latest 51Degrees package, but the problem recurs. Must be an incompatibility with one of my packages, or a weird setting.

The log shows that the library is being reloaded for each request:

2012-01-18T11:50:02.5026920Z - 11928 - Info - Creating provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.
2012-01-18T11:50:02.8137098Z - 11928 - Info - Created provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.
2012-01-18T11:50:07.7419917Z - 11928 - Info - Creating provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.
2012-01-18T11:50:08.0170074Z - 11928 - Info - Created provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.
2012-01-18T11:50:10.4191448Z - 11928 - Info - Creating provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.
2012-01-18T11:50:10.7251623Z - 11928 - Info - Created provider from binary data file '~\App_Data\51Degrees.mobi-Lite-2012.01.05.dat'.

The delay is much less than the XML data file (300ms vs 3000ms), but it’s still causing a noticeable delay.

The two projects’ 51Degrees.mobi.config files are identical and in my web.config, this is the module I have loaded:

<modules>
    <remove name="Detector"/>
    <add name="Detector" type="FiftyOne.Foundation.Mobile.Detection.DetectorModule, FiftyOne.Foundation"/>
</modules>

What could be causing the 51Degrees library to reload on each request?

  • 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-28T13:26:51+00:00Added an answer on May 28, 2026 at 1:26 pm

    This is happening because the log file is placed in the bin folder. Whenever anything changes in the bin folder the worker process will restart. Move the log file to the ~/App_Data folder and you’ll find the problem will be resolved. Thank you for using 51Degrees.mobi.

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

Sidebar

Related Questions

In our ASP.NET MVC project we have a Strings.resx file and the accompanying autogenerated
Today I started adding unit tests to an ASP.NET MVC project we are developing
I am using an ASP.NET MVC project and everytime I add a class to
I have an ASP.NET MVC project with a form. In the Action method that
I have an ASP.NET MVC project and I have a single action that accepts
I have a new ASP.NET MVC project (my first), and I had been running
I just created a ASP.NET MVC project in VS2008. When I press F5 to
I just created a ASP.NET MVC project and was able to build and browse
I have a new asp.net mvc project and i am trying to figure out
I'm starting an ASP.NET MVC project using SubSonic 3 ActiveRecord. I added a table

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.