TV Forum - ARRGHH!

James Hatts
Posts: 309
Joined: Sat 16 Aug, 2003 23.34
Location: London

Nick Harvey wrote:
James Hatts wrote:Good point - I suppose it probably does involve an additional database query.
I've just had a quick peek at my line traffic and it APPEARS to do a new database query every four seconds, each time the text changes.

Now, that IS processor heavy at the server end.
No - if you look at the source code, you will see that all the text and links for the ticker are held in a JavaScript array. It's YOUR machine that changes the text once the page has been downloaded.
User avatar
Nick Harvey
God
Posts: 4162
Joined: Fri 15 Aug, 2003 22.26
Location: Deepest Wiltshire
Contact:

Ah, okay, the traffic must be a co-incidence; as I said "APPEARS".

What ever happened to proper, old fashioned, V24 line-spys?
User avatar
Nick Harvey
God
Posts: 4162
Joined: Fri 15 Aug, 2003 22.26
Location: Deepest Wiltshire
Contact:

Interesting fact number thirty-nine, coming from the various comments in this thread.

I've just changed my profile here and on TVF to display the time in twenty-four hour clock (H:i).

It all changes correctly except the damn ticker at the top of the TVF main forum, which insists on staying in twelve hour, with "am" or "pm" on the end.

So whatever else we can or can't say about the ticker, it IS badly coded, as it takes no notice of your profile settings for how you want time displayed.
User avatar
Pete
Posts: 7643
Joined: Fri 15 Aug, 2003 13.36
Location: Dundee

James Hatts wrote:
Nick Harvey wrote:
James Hatts wrote:Good point - I suppose it probably does involve an additional database query.
I've just had a quick peek at my line traffic and it APPEARS to do a new database query every four seconds, each time the text changes.

Now, that IS processor heavy at the server end.
No - if you look at the source code, you will see that all the text and links for the ticker are held in a JavaScript array. It's YOUR machine that changes the text once the page has been downloaded.
So how does the array get it's information? Does Asa type it in by hand? How does it know I was the last person to type in a thread just after I do it?

Could it - perchance perhaps maybe just be - a database query? *GASP*
"He has to be larger than bacon"
James Hatts
Posts: 309
Joined: Sat 16 Aug, 2003 23.34
Location: London

Hymagumba wrote:So how does the array get it's information? Does Asa type it in by hand? How does it know I was the last person to type in a thread just after I do it?

Could it - perchance perhaps maybe just be - a database query? *GASP*
Yes, that's what I said a few messages back. But there isn't a fresh database query every time the ticker changes, which is what Nick was suggesting.
User avatar
Pete
Posts: 7643
Joined: Fri 15 Aug, 2003 13.36
Location: Dundee

James Hatts wrote:Yes, that's what I said a few messages back. But there isn't a fresh database query every time the ticker changes, which is what Nick was suggesting.
oh I see I see.

I personally think TVF is just on a crap host. If they can't cope with a smallish messageboard and some gunk on top then they really don't have much going for them.

I do hope we can change servers again as that's *ALWAYS* fun.
"He has to be larger than bacon"
User avatar
Sput
Posts: 7547
Joined: Wed 20 Aug, 2003 19.57

James Hatts wrote: Yes, that's what I said a few messages back. But there isn't a fresh database query every time the ticker changes, which is what Nick was suggesting.
Think in the fourth dimension, sonny, I'm willing to bet the results aren't cached, which means every time someone loads the list of posts, the query load is doubled. It might even be more, depending on if it's a separate query for each forum - a tempting easy way to code it.

I don't know about most people, but I must hit that front page several times per visit!

It might also be trying to use persistent db connections (though I would hope not) or be deeply inefficient in its querying.
Knight knight
User avatar
Nick Harvey
God
Posts: 4162
Joined: Fri 15 Aug, 2003 22.26
Location: Deepest Wiltshire
Contact:

Well, how are others finding TVF today?

It seems MUCH quicker without the business at the top of the main forum; and (as yet) I've not had one "busy" message.

Well done Asa for removing it.
User avatar
Gavin Scott
Admin
Posts: 6442
Joined: Fri 15 Aug, 2003 13.16
Location: Edinburgh
Contact:

Much faster for me too now.
User avatar
Nick Harvey
God
Posts: 4162
Joined: Fri 15 Aug, 2003 22.26
Location: Deepest Wiltshire
Contact:

Best part of thirty-six hours since since the revolving widget was removed and I still haven't had one "busy" message.

I shall take this opportunity to inflate my own brass instrument and say "I told you so"!
Square Eyes
Posts: 630
Joined: Fri 15 Aug, 2003 13.38

Nick Harvey wrote:Best part of thirty-six hours since since the revolving widget was removed and I still haven't had one "busy" message.

I shall take this opportunity to inflate my own brass instrument and say "I told you so"!
Don't get too excited with your brass instrument just yet Nick, I've been getting busy messages this morning.
Please Respond