Reputation: 1
I have an ASP .Net website hosted on azure cloud (previously in godaddy shared hosting) The site is basically a multi user test website where users login and take online tests.
The site loads all the questions(40 numbers) of the test at once and shows one after one to the user using javascript show/hide. And every selected answer should be confirmed immediately using a confirm button which makes an ajax call to save the answer to the server.
Now both the hosting providers give me the same kind of problem. When there are so many concurrent users (I think) the answers do not get saved(ajax calls) and when the final submit button is clicked (postback) the page just hangs. So it must be an issue with my code.
I created a new instance of the web role yesterday and the first 60+ tests ran without any issues and few users reported errors in the evening. So I'm guessing some memory leak or some accumulation of some sort.
I use LINQ to SQL for database operations.
The real problem is I do not know how to replicate this (Load testing?) in our development machines.
Any advice or hint of any sort is appreciated.
(Please let me know if you need further information on the code or other details)
Upvotes: 0
Views: 330
Reputation: 1
To easily replicate load on your development website you can use Visual Studio Web Test.
It allows to record a brower session and replay it but with X amount of session in parallel using one or multiple machines.If you have a leak or a concurrency bug, it should help you to see it.
The Web test feature isn't part of all versions of Visual Studio and it gets expensive if you don't have it today.
You can do more or less the same with a few more hours.
1 - Use one of my favorite debbuging tool for the web, fiddler ,to "record" an exchange between your a page and your server.
2 - Replay some http requests with fiddler to see if you can reproduce the problems
3 - To push your website a bit more, you can create a small C# program replicating the http requests you have seen in fiddler but with multiple threads in parallele. You will need to use the HttpClient class.
Upvotes: 0
Reputation: 3332
Once you move an application to Windows Azure for production purposes, you really should have a copy of Cerebrata's Diagnostics Manager. This will allow you to easily see all of your logs and performance counters in a way that makes sure you are solving the right problem.
Do you need to scale up, scale out, or is there contention for a different resource is going to be hard to determine without some data.
I am in no way connected to this company or product, It is just my honest opinion that it is the best out there for this task
Upvotes: 1
Reputation: 8606
If your site have problem with performance (considered there is no problem with your code)you can increase Size of VM to medium or large to get more resources.
Ans simultaneously to handle traffic (multiple users) you can scale your application to from 1 instance to no of instances as per your website's traffic
Upvotes: 0
Reputation: 289
Did you deploy the site in debug or release?
We've experienced some pretty quirky things when a site gets deployed in debug mode.
Upvotes: 0