Abandoned baskets report timing out

For general questions and discussions specific to the AbleCommerce 7.0 Asp.Net product.
Post Reply
User avatar
WylieE
Captain (CAPT)
Captain (CAPT)
Posts: 281
Joined: Tue Mar 25, 2008 8:26 am
Location: Puyallup, WA
Contact:

Abandoned baskets report timing out

Post by WylieE » Fri Aug 28, 2009 2:52 pm

Our abandoned baskets report is suddenly timing out on us. I ran it last week and it worked fine. All of our other reports are working fine.

When running the report, we get a request timed out error. In the past, it took some time to run. I'm guessing a table has grown too large or something like that.

Has anyone ever encountered problems with this report? Timeouts?
Eric Wylie
Warmoth Guitar Products, Inc.
http://www.warmoth.com

User avatar
Logan Rhodehamel
Developer
Developer
Posts: 4116
Joined: Wed Dec 10, 2003 5:26 pm

Re: Abandoned baskets report timing out

Post by Logan Rhodehamel » Fri Aug 28, 2009 4:45 pm

This is the second time I've heard this this week. IIRC you can get to your database... Do you want to compare these two queries on your large dataset?

current query (approximate):

Code: Select all

SELECT b.BasketId FROM ac_Baskets b INNER JOIN ac_Users u on b.UserId=u.UserId WHERE u.StoreId = 1 AND u.LastActivityDate >= '8/1/2009' AND u.LastActivityDate < '8/28/2009'
possible improvement:

Code: Select all

SELECT BasketId WHERE ac_Baskets WHERE UserId IN (SELECT UserId FROM ac_Users WHERE StoreId = 1 AND LastActivityDate >= '8/1/2009' AND LastActivityDate < '8/28/2009')
We may also need to add an index on lastactivitydate.
Cheers,
Logan
Image.com

If I do not respond to an unsolicited private message, it's not because I'm ignoring you. It's because the answer to your question is valuable to others. Try the new topic button.

User avatar
WylieE
Captain (CAPT)
Captain (CAPT)
Posts: 281
Joined: Tue Mar 25, 2008 8:26 am
Location: Puyallup, WA
Contact:

Re: Abandoned baskets report timing out

Post by WylieE » Mon Aug 31, 2009 9:17 am

I compared both queries and the results were near identical. Approximately 2 seconds to return 217,454 rows. I also indexed LastActivityDate. Marginally faster search results.

After adding the index, I tried running the Abandoned carts report and it still errored out with a timeout error.
Eric Wylie
Warmoth Guitar Products, Inc.
http://www.warmoth.com

User avatar
Logan Rhodehamel
Developer
Developer
Posts: 4116
Joined: Wed Dec 10, 2003 5:26 pm

Re: Abandoned baskets report timing out

Post by Logan Rhodehamel » Mon Aug 31, 2009 9:51 am

WylieE wrote:After adding the index, I tried running the Abandoned carts report and it still errored out with a timeout error.
I assumed timeout meaning sql timeout. Is this perhaps an ASP.NET timeout? Something about the page processing that it's taking too long to draw the page? Because a 2 second query won't do that.
Cheers,
Logan
Image.com

If I do not respond to an unsolicited private message, it's not because I'm ignoring you. It's because the answer to your question is valuable to others. Try the new topic button.

User avatar
WylieE
Captain (CAPT)
Captain (CAPT)
Posts: 281
Joined: Tue Mar 25, 2008 8:26 am
Location: Puyallup, WA
Contact:

Re: Abandoned baskets report timing out

Post by WylieE » Mon Aug 31, 2009 10:19 am

Here's the exact error as reported in our event viewer.
Event code: 3001
Event message: The request has been aborted.
Event time: 8/31/2009 9:52:58 AM
Event time (UTC): 8/31/2009 4:52:58 PM
Event ID: c2cd69bdf74f4249884af79a9f6504e3
Event sequence: 965
Event occurrence: 1
Event detail code: 0

Application information:
Application domain: /LM/W3SVC/195289828/Root-1-128962108928276250
Trust level: Full
Application Virtual Path: /
Application Path: C:\Inetpub\wwwroot\warmothable\
Machine name: WARMOTH

Process information:
Process ID: 2560
Process name: w3wp.exe
Account name: NT AUTHORITY\NETWORK SERVICE

Exception information:
Exception type: HttpException
Exception message: Request timed out.

Request information:
Request URL: https://www.warmoth.com:443/Admin/Repor ... skets.aspx
Request path: /Admin/Reports/MonthlyAbandonedBaskets.aspx
User host address: 75.149.171.225
User: eric@warmoth.com
Is authenticated: True
Authentication Type: Forms
Thread account name: NT AUTHORITY\NETWORK SERVICE

Thread information:
Thread ID: 7
Thread account name: NT AUTHORITY\NETWORK SERVICE
Is impersonating: False
Stack trace:
Eric Wylie
Warmoth Guitar Products, Inc.
http://www.warmoth.com

User avatar
WylieE
Captain (CAPT)
Captain (CAPT)
Posts: 281
Joined: Tue Mar 25, 2008 8:26 am
Location: Puyallup, WA
Contact:

Re: Abandoned baskets report timing out

Post by WylieE » Fri Sep 04, 2009 2:43 pm

Update:

We can run the abandoned carts report for September. Once in the report, I can select any month *but* August and have the report run correctly. If I select August in the report, it updates the month display at the top of the report, but returns the previously selected month's totals.

Logan, I'm guessing you have some error checking in place that returns the previous data set if there's an error. I checked the error log and app.log and no errors were reports.
Eric Wylie
Warmoth Guitar Products, Inc.
http://www.warmoth.com

User avatar
Logan Rhodehamel
Developer
Developer
Posts: 4116
Joined: Wed Dec 10, 2003 5:26 pm

Re: Abandoned baskets report timing out

Post by Logan Rhodehamel » Fri Sep 04, 2009 3:00 pm

It's just timing out trying to produce the page - it might not be directly a SQL timeout. You could try upping the timeout with a small edit to MonthlyAbandonedBaskets.aspx.cs:

Code: Select all

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
turns into

Code: Select all

    protected void Page_Load(object sender, EventArgs e)
    {
        Server.ScriptTimeout = 7200;
        if (!Page.IsPostBack)
Cheers,
Logan
Image.com

If I do not respond to an unsolicited private message, it's not because I'm ignoring you. It's because the answer to your question is valuable to others. Try the new topic button.

divers-supply
Ensign (ENS)
Ensign (ENS)
Posts: 20
Joined: Fri Nov 21, 2008 5:15 pm

Re: Abandoned baskets report timing out

Post by divers-supply » Thu Oct 08, 2009 11:21 pm

Anybody figured this out? I just ran my Abandoned baskets report and I'm getting a timing out error before it loads the page in my web browser!

User avatar
triplw
Commander (CMDR)
Commander (CMDR)
Posts: 144
Joined: Sat Jan 12, 2008 5:34 pm
Contact:

Re: Abandoned baskets report timing out

Post by triplw » Mon Mar 01, 2010 9:40 pm

I have this problem with the timeouts too. At the beginning of the month I usually can load the abandoned baskets report but it gets slower as the month goes on then starts timing out. I added a link on the dropdown to DailyAbandonedBaskets.aspx and that way I can view the days one at a time without any problems. But I would like to have the MonthlyAbandonedBasket.aspx page load too.

User avatar
mazhar
Master Yoda
Master Yoda
Posts: 5084
Joined: Wed Jul 09, 2008 8:21 am
Contact:

Re: Abandoned baskets report timing out

Post by mazhar » Tue Mar 02, 2010 7:14 am

Did you tired to increase the timeout period as suggested by Logan in his above post? I think that will also work.

User avatar
triplw
Commander (CMDR)
Commander (CMDR)
Posts: 144
Joined: Sat Jan 12, 2008 5:34 pm
Contact:

Re: Abandoned baskets report timing out

Post by triplw » Wed Mar 03, 2010 2:17 pm

I did what Logan suggested. I just wondered why it would take SO LONG to load the report.

User avatar
crockettdunn
Lieutenant Commander (LCDR)
Lieutenant Commander (LCDR)
Posts: 105
Joined: Sun Oct 26, 2008 6:32 pm
Contact:

Re: Abandoned baskets report timing out

Post by crockettdunn » Mon Jul 14, 2014 11:10 pm

glad to know how to do this. Would anyone be kind enough to tell me where the anonymous user maintenance code lives, so I can increase the timeout there?

User avatar
jmestep
AbleCommerce Angel
Posts: 8164
Joined: Sun Feb 29, 2004 8:04 pm
Location: Dayton, OH
Contact:

Re: Abandoned baskets report timing out

Post by jmestep » Tue Jul 15, 2014 3:49 am

protected void Page_Load(object sender, EventArgs e)
{
Server.ScriptTimeout = 7200;
if (!Page.IsPostBack)
The above code would go into the Admin/Reports/MonthlyAbandonedBaskets.aspx.cs
Is that what you were asking about?
Judy Estep
Web Developer
jestep@web2market.com
http://www.web2market.com
708-653-3100 x209
New search report plugin for business intelligence:
http://www.web2market.com/Search-Report ... -P154.aspx

Post Reply