Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.0 > vBulletin 3.0 Full Releases
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
New Posts / Get Daily Optimization Details »»
New Posts / Get Daily Optimization
Version: 1.00, by Freddie Bingham Freddie Bingham is offline
Developer Last Online: Aug 2016 Show Printable Version Email this Page

Version: 3.0.1 Rating:
Released: 06-26-2004 Last Update: Never Installs: 32
 
No support by the author.

Here is a small 3.0.2 optimization to search.php?do=getnew / search.php?do=getdaily that you can make a noticeable impact on your load.

edit search.php, find:

PHP Code:
ORDER BY lastpost DESC 
Above this, place:

PHP Code:
AND sticky IN(0,1
For example on vb.com, we went from doing a scan of 107000 thread rows on every getnew/getdaily (that wasn't cached in search.php) to a scan of 188 rows.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #32  
Old 06-28-2004, 06:18 PM
tamarian tamarian is offline
 
Join Date: Oct 2001
Location: Canada
Posts: 1,205
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by noppid
This should be listed as a bug if it's bringing servers to their knees.
What is bringing your server to it's knees? I'm using it on 2 million+ forum with no problems.
Reply With Quote
  #33  
Old 06-28-2004, 07:37 PM
Freddie Bingham's Avatar
Freddie Bingham Freddie Bingham is offline
 
Join Date: Oct 2001
Posts: 506
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by noppid
This should be listed as a bug if it's bringing servers to their knees. Nice try trying to hide it and offer it as a hack. It should have been announced at .com.
If you are going to have that attitude then I don't need to bother posting things like this but if it makes you happy I can post it in the bug tracker. I'm sorry that you feel I'm trying to "hide" something. Perhaps if that was my goal then I would have just updated the code and not posted here at all? Doesn't that seem to make more sense?
Reply With Quote
  #34  
Old 06-28-2004, 08:10 PM
P.Jackson P.Jackson is offline
 
Join Date: Sep 2003
Location: Newcastle,Uk
Posts: 170
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

well whatever thanks for releasing it here freddie im sure alot of people appriciate it including me
Reply With Quote
  #35  
Old 06-28-2004, 08:20 PM
Xenon's Avatar
Xenon Xenon is offline
 
Join Date: Oct 2001
Location: Bavaria
Posts: 12,878
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

nice one Freddie

that shows the little hints can boost MySQL
Reply With Quote
  #36  
Old 06-28-2004, 08:23 PM
the Sandman's Avatar
the Sandman the Sandman is offline
 
Join Date: Aug 2003
Location: Tampa, FL
Posts: 229
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

IMO Freddie's first post was accurate and straightforward - it's an optimization for vB3 from the upcoming 3.0.2 release. Since adding it involves editing a file, and it's not a bug, this seems to be the appropriate place to release it. Of course, there are other possible ways to look at it, but the majority here seem to appreciate it as do I. Thanks again Freddie!

Any other tidbits you can throw our way?
Reply With Quote
  #37  
Old 06-28-2004, 09:08 PM
WoodiE WoodiE is offline
 
Join Date: May 2002
Posts: 317
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Funny - my speeds increased with this hack.

getnew went from .02 to .03

getdaily went from .05 to .07

and my get unanswered threads went from .30 to .44

-Michael
Reply With Quote
  #38  
Old 06-29-2004, 06:11 PM
Freddie Bingham's Avatar
Freddie Bingham Freddie Bingham is offline
 
Join Date: Oct 2001
Posts: 506
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by WoodiE
Funny - my speeds increased with this hack.

getnew went from .02 to .03

getdaily went from .05 to .07

and my get unanswered threads went from .30 to .44



-Michael
WoodiE that isn't possible unless you ran an unscientific test or you are missing the index on the thread table.
Reply With Quote
  #39  
Old 06-29-2004, 06:36 PM
Alien's Avatar
Alien Alien is offline
 
Join Date: Oct 2001
Posts: 827
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Freddie Bingham
WoodiE that isn't possible unless you ran an unscientific test or you are missing the index on the thread table.
Kick ass. Thanks a LOT, Freddie! Doing nicely...
Reply With Quote
  #40  
Old 06-29-2004, 08:17 PM
vbmechanic vbmechanic is offline
 
Join Date: Jan 2004
Posts: 104
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ignore the naysayers... THANK YOU for releasing this early; makes a huge difference on sites with 1 mil+ posts.
Reply With Quote
  #41  
Old 06-29-2004, 10:07 PM
Princeton's Avatar
Princeton Princeton is offline
 
Join Date: Nov 2001
Location: Vineland, NJ
Posts: 6,693
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

thanks Freddie ...

optimization hacks/tip = :up:
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 12:54 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07160 seconds
  • Memory Usage 2,308KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (2)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete