Results 1 to 4 of 4
  1. #1
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,622
    Plugin Contributions
    123

    Default Perfmon - A tool for finding performance bottlenecks

    Version 1.0 of Perfmon has just been released.

    http://www.zen-cart.com/downloads.php?do=file&id=1670

    Perfmon allows you to view the time when each notifier point is hit during a page load, and thus quickly isolate what could be slowing down your page loads.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  2. #2
    Join Date
    Aug 2007
    Location
    Gijón, Asturias, Spain
    Posts
    2,571
    Plugin Contributions
    30

    Default Re: Perfmon - A tool for finding performance bottlenecks

    Looks useful, thanks.

    I didn't like it creating debug/error files as they show up in my admin, so I changed the last line:
    PHP Code:
           //error_log($line);
           
    error_log($line."\n",3,DIR_FS_LOGS.'/perfmon.log'); 
    I also changed the formatting a bit to line up the notifys (which does not display the same in the quote below)
    PHP Code:
    //$separator = ",";  // Could be " " if csv not desired
            
    $separator "\t\t";
           
    $currtime microtime(true);
           if (isset(
    $lasttime)) { 
              
    $timediff = (int)($currtime*10000) - (int)($lasttime*10000);
              if (
    strlen((string)$timediff)>=4$separator "\t"
    So, now I have my list from a product page. The notifiers are not in a time-order which I find a bit surprising.
    There seems to be some big numbers in there and indeed I feel the product pages load slowly.

    So, from your experience, how would you go about investigating this?
    Just find the notifier and work backwards?

    Code:
    0        NOTIFY_HEADER_START_PRODUCT_INFO
    712        NOTIFY_HEADER_END_PRODUCT_INFO
    249        NOTIFY_MODULE_START_META_TAGS
    193        NOTIFY_MODULE_END_META_TAGS
    3598    NOTIFIER_CART_COUNT_CONTENTS_START
    128        NOTIFIER_CART_GET_QUANTITY_START
    93        NOTIFIER_CART_GET_QUANTITY_END_QTY
    93        NOTIFIER_CART_COUNT_CONTENTS_END
    137        NOTIFIER_CART_COUNT_CONTENTS_START
    99        NOTIFIER_CART_GET_QUANTITY_START
    229        NOTIFIER_CART_GET_QUANTITY_END_QTY
    105        NOTIFIER_CART_COUNT_CONTENTS_END
    125        NOTIFIER_CART_SHOW_TOTAL_START
    200        NOTIFIER_CART_SHOW_TOTAL_END
    56524    PAGE_OUTPUT_IMAGE_SUBMIT
    584        PAGE_OUTPUT_IMAGE_SUBMIT
    623        PAGE_OUTPUT_IMAGE_SUBMIT
    870        NOTIFY_HANDLE_IMAGE
    2781    NOTIFY_MAIN_TEMPLATE_VARS_START_PRODUCT_INFO
    308        NOTIFY_PRODUCT_VIEWS_HIT_INCREMENTOR
    742        PAGE_OUTPUT_IMAGE_BUTTON
    463        PAGE_OUTPUT_IMAGE_BUTTON
    466        NOTIFY_HANDLE_IMAGE
    374        NOTIFY_HANDLE_IMAGE
    303        NOTIFY_PRODUCT_TYPE_VARS_START_PRODUCT_INFO
    127        NOTIFY_PRODUCT_TYPE_VARS_END_PRODUCT_INFO
    255        NOTIFY_MAIN_TEMPLATE_VARS_PRODUCT_TYPE_VARS_PRODUCT_INFO
    1184    NOTIFY_MAIN_TEMPLATE_VARS_EXTRA_PRODUCT_INFO
    1077    PAGE_OUTPUT_IMAGE_BUTTON
    1004    NOTIFY_HANDLE_IMAGE
    349        NOTIFY_HANDLE_IMAGE
    332        NOTIFIER_CART_IN_CART_START
    127        NOTIFIER_CART_IN_CART_END_FALSE
    295        NOTIFIER_CART_GET_QUANTITY_START
    139        NOTIFIER_CART_GET_QUANTITY_END_FALSE
    214        PAGE_OUTPUT_IMAGE_SUBMIT
    515        PAGE_OUTPUT_IMAGE_BUTTON
    1678    NOTIFY_HANDLE_IMAGE
    888        NOTIFY_HANDLE_IMAGE
    1118    NOTIFY_HANDLE_IMAGE
    572        NOTIFY_HANDLE_IMAGE
    425        NOTIFY_HANDLE_IMAGE
    353        NOTIFY_HANDLE_IMAGE
    576        NOTIFY_HANDLE_IMAGE
    403        NOTIFY_HANDLE_IMAGE
    674        NOTIFY_HANDLE_IMAGE
    3801    NOTIFY_HANDLE_IMAGE
    450        PAGE_OUTPUT_IMAGE_BUTTON
    680        PAGE_OUTPUT_IMAGE_BUTTON
    1025    NOTIFY_HANDLE_IMAGE
    588        NOTIFY_HANDLE_IMAGE
    740        NOTIFY_HANDLE_IMAGE
    339        NOTIFY_MAIN_TEMPLATE_VARS_END_PRODUCT_INFO
    Steve
    github.com/torvista: Spanish Language Pack, Google reCaptcha, Structured Data, Multiple Copy-Move-Delete, Image Checker, BackupMySQL Admin/Auto...

  3. #3
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,622
    Plugin Contributions
    123

    Default Re: Perfmon - A tool for finding performance bottlenecks

    Yes - just find the slowest ones and focus on those.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

  4. #4
    Join Date
    Feb 2006
    Location
    Tampa Bay, Florida
    Posts
    9,622
    Plugin Contributions
    123

    Default Re: Perfmon - A tool for finding performance bottlenecks

    Perfmon has been updated for Zen Cart 1.5.2 and 1.5.3.
    That Software Guy. My Store: Zen Cart Modifications
    Available for hire - See my ad in Services
    Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
    Do you benefit from Zen Cart? Then please support the project.

 

 

Similar Threads

  1. Replies: 5
    Last Post: 1 Aug 2016, 04:31 PM
  2. v150 utf-8: Developers Tool Kit not finding strings?
    By lat9 in forum General Questions
    Replies: 4
    Last Post: 3 May 2013, 09:21 AM
  3. Trying to get rid of "lbs" from php files - developers tool kit not finding it.
    By mtimber in forum Built-in Shipping and Payment Modules
    Replies: 6
    Last Post: 26 Oct 2008, 10:13 PM
  4. php.ini setting for ZenCart performance?
    By artcoder in forum General Questions
    Replies: 3
    Last Post: 25 Apr 2008, 09:32 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR