SlideShare ist ein Scribd-Unternehmen logo
1 von 24
Downloaden Sie, um offline zu lesen
Make Your Site SpEEdy
Improving the performance of
your ExpressionEngine website




                            Prepared by Ruthie BenDor for the
                          BostonEErs September 2010 Meetup
Part I: Tools and techniques for

Measuring Performance
What impacts site speed?

1. Browser rendering time               4. Filesystem disk accessing time
2. Component transmission time          5. Database query execution time
3. Server-side script execution



                                                               1
                      3                            2

 5                        Server-side                     Browser
Database                    scripts

                          Filesystem
                     4

                                  Web server
What impacts site speed?

1. Browser rendering time               4. Filesystem disk accessing time
2. Component transmission time          5. Database query execution time
3. Server-side script execution



                                                                  1
                      3                              2

5                         Expression                           Browser
                                                    HTML
MySQL                       Engine               fragments,
                                                  CSS files,
                                                 Javascript
                                                files, images


                          Filesystem
                     4

                                  Web server
1      2


Page render time and component load time

can be measured with YSlow and/or Google Page Speed for Firebug.
                                             (Also useful: Webkit’s
                                             Developer Tools.)
3


Server-side script execution

can be measured by enabling EE’s Template Debugging.


                            In EE 1.6.x’s Control Panel:
          Admin › System Preferences › Output and Debugging Preferences




                             In EE 2.1’s Control Panel:
               Admin › System Administration › Output and Debugging
5


Database queries

can be seen by enabling EE’s output profiler. Note that this doesn’t tell us
how long a single query takes to run, but it does show us the full query.

                              In EE 1.6.x’s Control Panel:
            Admin › System Preferences › Output and Debugging Preferences




                               In EE 2.1’s Control Panel:
                 Admin › System Administration › Output and Debugging
Part 2: Recommendations for

Improving Performance
The site optimization cycle




     Measure
   performance.
  (“Benchmark.”)     Identify the
                     biggest (or
                    easiest-to-fix)
                     bottleneck.
                                     Remove that
                                      bottleneck.
What impacts site speed?

1. Browser rendering time               4. Filesystem disk accessing time
2. Component transmission time          5. Database query execution time
3. Server-side script execution



                                                                  1
                      3                              2

5                         Expression                           Browser
                                                    HTML
MySQL                       Engine               fragments,
                                                  CSS files,
                                                 Javascript
                                                files, images


                          Filesystem
                     4

                                  Web server
1


Browser rendering time optimizations

• Make your Javascript and CSS more efficient, so the browser
  is able to render (draw) the completed page more quickly.
  • For writing faster CSS, check out OOCSS:
     http://wiki.github.com/stubbornella/oocss/
  • For writing faster JavaScript, speed-test snippets using JSPerf:
     http://jsperf.com/
2


Component transmission time optimizations

• Minify and concatenate all JavaScript into a single file, and
  minify and concatenate all CSS into a single file.
  • If you keep your Javascript and CSS in EE templates, concatenate these
    assets using this technique: http://easy-reader.net/archives/2010/07/11/
    template-based-asset-munging-in-expressionengine
  • To concatenate and minify JS/CSS in EE templates, try SL Combinator
    http://experienceinternet.co.uk/software/sl-combinator/docs/, which uses
    an old version of Minify http://code.google.com/p/minify/
  • If you keep your JS and CSS assets outside of EE, use Minify http://
    code.google.com/p/minify/
2


Component transmission time optimizations (con’t)

• Serve optimized images.
  • Prevent content maintainers from uploading content images that are too
    large by using http://www.lumis.com/page/imgsizer/
  • Run all site image assets through http://smush.it/ to reduce filesize as
    much as possible.
  • Where possible, combine (aka sprite) site image assets.

• Enable GZIP compression in EE.
     In EE 1.6.x’s Control Panel:
     Admin › System Preferences ›         In EE 2.1’s Control Panel:
     Output and Debugging Preferences     Admin › System Administration › Output and Debugging
3


Server-side script execution optimizations

• Cache individual tags.
  • Tag caches are time-based, set in minutes. Use on any EE tag like so:
    {exp:some:tag cache="yes" refresh="30"}

• Cache entire templates.
  • Enabled on a per-template basis. In EE1, look in Templates > Preferences. In EE2,
    look in Design > Templates > Template Preferences.
  • Template caches are time-based, mostly - certain events will clear the cache:
     http://expressionengine.com/user_guide/general/caching.html#template_caching

  • Template caching supercedes tag caching, so if you’re caching the entire
    template, there’s no reason to also cache individual tags.
  • A cached template in EE is still heavier, performance-wise, than a 100% static
    page served from outside EE.
3


Server-side script execution optimizations (con’t)

• Where possible, use Global Variables and Snippets instead of
  embedded templates.
  • Snippets can contain EE tags, while Global Variables can contain only HTML.
  • Snippets are EE2-only.
  • Why Snippets are faster than embedded templates:
    http://www.meetup.com/BostonEErs/messages/boards/thread/9783637

• Where possible, avoid nesting embedded templates.
4


Filesystem optimizations

• Don’t save templates as flat files.
  • Why? “Saving templates as files can marginally increase disk 1/o as teach
    template must be retrieved from disk in addition to the standard database
    query responsible for managing your template’s meta data (access, PHP
    parsing, template type, etc.)” - http://expressionengine.com/user_guide/
    general/handling_extreme_traffic.html

• But flat files are really convenient during development!
  • Suggestion: work with templates as flat files during development. At site
    launch, sync all templates back to the database, and set all templates to
    no longer save as flat files. How?
     • In EE2, use the built-in Synchronize Templates tool under Design >
       Templates.
     • In EE1, either sync manually, or use the free DC Template Manager
       module: http://devot-ee.com/add-ons/dc-template-manager/
5


Database query optimizations

• Set the database connection to non-persistent.
  • In EE2, set Persistent Database Connection to No at
    Admin › System Administration › Database Settings
  • In EE1, set Database Connection Type to Non Persistent at
    Admin › System Preferences › Database Settings

• Reduce the number of queries each page calls.
  • http://expressionengine.com/wiki/Reduce_Queries/

• Cache frequently used queries.
  • In EE2, set Enable SQL Query Caching to Yes at
    Admin › System Administration › Database Settings
  • In EE1, set Enable SQL Query Caching to Yes at
    Admin › System Preferences › Database Settings
5


Database query optimizations (con’t)

• Enable dynamic channel query caching.
  • Only enable if your site doesn’t use future, expiring, or random entries.
  • In EE1, set Cache Dynamic Channel Queries? to Yes at
    Admin › Weblog Administration › Global Weblog Preferences.
  • In EE2, set Cache Dynamic Channel Queries? to Yes at
    Admin › Channel Administration › Global Preferences.

• Disable unused parts of {exp:channel:entries} queries.
  • In EE1, six things can be disabled: {exp:channel:entries disable="categories|
    category_fields|custom_fields|member_data|pagination|trackbacks"}
  • In EE2, trackbacks have been removed, so five things can be disabled:
    {exp:channel:entries disable="categories|category_fields|custom_fields|
    member_data|pagination"}
5


Database query optimizations (con’t)

• Repair and optimize EE’s MySQL tables.
  • In EE1, look under Admin › Utilities › SQL Manager › Manage Database Tables.
  • In EE2, look under Tools › Data › SQL Manager › Manage Database Tables.

• Disable template tracking.
  • In EE1, look under Admin › System Preferences › Tracking Preferences.
  • In EE2, these options must be set manually in config.php.
Part 3:

More Resources
Online Resources

• ExpressionEngine.com User Guide
  • http://expressionengine.com/user_guide/general/caching.html
  • http://expressionengine.com/user_guide/general/
    handling_extreme_traffic.html
  • http://expressionengine.com/user_guide/templates/flat_file_templates.html
  • http://expressionengine.com/legacy_docs/cp/admin/system_preferences/
    tracking_preferences.html


• SolSpace’s EE Website Performance Guidelines
  • http://www2.grist.org/misc/Performance_Guidelines.pdf
Books

• High Performance Web Sites, by Steve Souders:
 http://www.amazon.com/gp/product/0596529309

• Even Faster Web Sites, also by Steve Souders:
 http://www.amazon.com/gp/product/0596522304
Nearby Groups

• Boston Web Performance Group:
  http://www.meetup.com/Web-Performance-Boston/
Thanks!

http://twitter.com/BostonEErs

http://BostonEErs.org

Weitere ähnliche Inhalte

Was ist angesagt?

JBoss Enterprise Application Platform 6 Troubleshooting
JBoss Enterprise Application Platform 6 TroubleshootingJBoss Enterprise Application Platform 6 Troubleshooting
JBoss Enterprise Application Platform 6 TroubleshootingAlexandre Cavalcanti
 
Weblogic Administration Managed Server migration
Weblogic Administration Managed Server migrationWeblogic Administration Managed Server migration
Weblogic Administration Managed Server migrationRakesh Gujjarlapudi
 
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.Dimitris Andreadis
 
Building the Perfect SharePoint 2010 Farm - Sharing the Point South America
Building the Perfect SharePoint 2010 Farm - Sharing the Point South AmericaBuilding the Perfect SharePoint 2010 Farm - Sharing the Point South America
Building the Perfect SharePoint 2010 Farm - Sharing the Point South AmericaMichael Noel
 
[DanNotes] XPages - Beyound the Basics
[DanNotes] XPages - Beyound the Basics[DanNotes] XPages - Beyound the Basics
[DanNotes] XPages - Beyound the BasicsUlrich Krause
 
The Play Framework at LinkedIn
The Play Framework at LinkedInThe Play Framework at LinkedIn
The Play Framework at LinkedInYevgeniy Brikman
 
Was liberty at scale
Was liberty at scaleWas liberty at scale
Was liberty at scalesflynn073
 
Webcenter application performance tuning guide
Webcenter application performance tuning guideWebcenter application performance tuning guide
Webcenter application performance tuning guideVinay Kumar
 
Oracle WebLogic Server 11g for IT OPS
Oracle WebLogic Server 11g for IT OPSOracle WebLogic Server 11g for IT OPS
Oracle WebLogic Server 11g for IT OPSRakesh Gujjarlapudi
 
Oracle WebLogic Server Basic Concepts
Oracle WebLogic Server Basic ConceptsOracle WebLogic Server Basic Concepts
Oracle WebLogic Server Basic ConceptsJames Bayer
 
Jboss App Server
Jboss App ServerJboss App Server
Jboss App Serveracosdt
 
JBoss at Work: Using JBoss AS 6
JBoss at Work: Using JBoss AS 6JBoss at Work: Using JBoss AS 6
JBoss at Work: Using JBoss AS 6Saltmarch Media
 
Oracle WebLogic Diagnostics & Perfomance tuning
Oracle WebLogic Diagnostics & Perfomance tuningOracle WebLogic Diagnostics & Perfomance tuning
Oracle WebLogic Diagnostics & Perfomance tuningMichel Schildmeijer
 
Case Study with Answers.com on Scaling with Memcached and MySQL
Case Study with Answers.com on Scaling with Memcached and MySQLCase Study with Answers.com on Scaling with Memcached and MySQL
Case Study with Answers.com on Scaling with Memcached and MySQLanswers
 
WebLogic JMX for DevOps
WebLogic JMX for DevOpsWebLogic JMX for DevOps
WebLogic JMX for DevOpsFrank Munz
 

Was ist angesagt? (20)

JBoss Enterprise Application Platform 6 Troubleshooting
JBoss Enterprise Application Platform 6 TroubleshootingJBoss Enterprise Application Platform 6 Troubleshooting
JBoss Enterprise Application Platform 6 Troubleshooting
 
Weblogic Administration Managed Server migration
Weblogic Administration Managed Server migrationWeblogic Administration Managed Server migration
Weblogic Administration Managed Server migration
 
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.
WildFly v9 - State of the Union Session at Voxxed, Istanbul, May/9th 2015.
 
Building the Perfect SharePoint 2010 Farm - Sharing the Point South America
Building the Perfect SharePoint 2010 Farm - Sharing the Point South AmericaBuilding the Perfect SharePoint 2010 Farm - Sharing the Point South America
Building the Perfect SharePoint 2010 Farm - Sharing the Point South America
 
JBOSS Training
JBOSS Training JBOSS Training
JBOSS Training
 
[DanNotes] XPages - Beyound the Basics
[DanNotes] XPages - Beyound the Basics[DanNotes] XPages - Beyound the Basics
[DanNotes] XPages - Beyound the Basics
 
The Play Framework at LinkedIn
The Play Framework at LinkedInThe Play Framework at LinkedIn
The Play Framework at LinkedIn
 
Was liberty at scale
Was liberty at scaleWas liberty at scale
Was liberty at scale
 
Webcenter application performance tuning guide
Webcenter application performance tuning guideWebcenter application performance tuning guide
Webcenter application performance tuning guide
 
Oracle WebLogic Server 11g for IT OPS
Oracle WebLogic Server 11g for IT OPSOracle WebLogic Server 11g for IT OPS
Oracle WebLogic Server 11g for IT OPS
 
Oracle WebLogic Server Basic Concepts
Oracle WebLogic Server Basic ConceptsOracle WebLogic Server Basic Concepts
Oracle WebLogic Server Basic Concepts
 
Jboss App Server
Jboss App ServerJboss App Server
Jboss App Server
 
Jboss Tutorial Basics
Jboss Tutorial BasicsJboss Tutorial Basics
Jboss Tutorial Basics
 
Weblogic12 c installation guide
Weblogic12 c installation guideWeblogic12 c installation guide
Weblogic12 c installation guide
 
JBoss at Work: Using JBoss AS 6
JBoss at Work: Using JBoss AS 6JBoss at Work: Using JBoss AS 6
JBoss at Work: Using JBoss AS 6
 
Oracle WebLogic Diagnostics & Perfomance tuning
Oracle WebLogic Diagnostics & Perfomance tuningOracle WebLogic Diagnostics & Perfomance tuning
Oracle WebLogic Diagnostics & Perfomance tuning
 
Case Study with Answers.com on Scaling with Memcached and MySQL
Case Study with Answers.com on Scaling with Memcached and MySQLCase Study with Answers.com on Scaling with Memcached and MySQL
Case Study with Answers.com on Scaling with Memcached and MySQL
 
JBoss AS / EAP and Java EE6
JBoss AS / EAP and Java EE6JBoss AS / EAP and Java EE6
JBoss AS / EAP and Java EE6
 
Test
TestTest
Test
 
WebLogic JMX for DevOps
WebLogic JMX for DevOpsWebLogic JMX for DevOps
WebLogic JMX for DevOps
 

Ähnlich wie Speed Up Your EE Site

Life In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesLife In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesUlrich Krause
 
Analysis of Google Page Speed Insight
Analysis of Google Page Speed InsightAnalysis of Google Page Speed Insight
Analysis of Google Page Speed InsightSarvesh Sonawane
 
SharePoint 2013 Performance Analysis - Robi Vončina
SharePoint 2013 Performance Analysis - Robi VončinaSharePoint 2013 Performance Analysis - Robi Vončina
SharePoint 2013 Performance Analysis - Robi VončinaSPC Adriatics
 
CTU June 2011 - Things that Every ASP.NET Developer Should Know
CTU June 2011 - Things that Every ASP.NET Developer Should KnowCTU June 2011 - Things that Every ASP.NET Developer Should Know
CTU June 2011 - Things that Every ASP.NET Developer Should KnowSpiffy
 
Extjs3.4 Migration Notes
Extjs3.4 Migration NotesExtjs3.4 Migration Notes
Extjs3.4 Migration NotesSimoAmi
 
Cloud computing 3702
Cloud computing 3702Cloud computing 3702
Cloud computing 3702Jess Coburn
 
How_To_Soup_Up_Your_Farm
How_To_Soup_Up_Your_FarmHow_To_Soup_Up_Your_Farm
How_To_Soup_Up_Your_FarmNigel Price
 
Extension Library - Viagra for XPages
Extension Library - Viagra for XPagesExtension Library - Viagra for XPages
Extension Library - Viagra for XPagesUlrich Krause
 
Orlando DNN Usergroup Pres 12/06/11
Orlando DNN Usergroup Pres 12/06/11Orlando DNN Usergroup Pres 12/06/11
Orlando DNN Usergroup Pres 12/06/11Jess Coburn
 
Mobile Browser Internal (Blink Rendering Engine)
Mobile Browser Internal (Blink Rendering Engine)Mobile Browser Internal (Blink Rendering Engine)
Mobile Browser Internal (Blink Rendering Engine)Hyungwook Lee
 
Sharepoint Performance - part 2
Sharepoint Performance - part 2Sharepoint Performance - part 2
Sharepoint Performance - part 2Regroove
 
Real-time Code Sharing Service for one-to-many coding classes
Real-time Code Sharing Service for one-to-many coding classesReal-time Code Sharing Service for one-to-many coding classes
Real-time Code Sharing Service for one-to-many coding classesa2tt
 
UKLUG 2012 - XPages, Beyond the basics
UKLUG 2012 - XPages, Beyond the basicsUKLUG 2012 - XPages, Beyond the basics
UKLUG 2012 - XPages, Beyond the basicsUlrich Krause
 
Internet Explorer 8
Internet Explorer 8Internet Explorer 8
Internet Explorer 8David Chou
 
SPSDenver - Wrapping Your Head Around the SharePoint Beast
SPSDenver - Wrapping Your Head Around the SharePoint BeastSPSDenver - Wrapping Your Head Around the SharePoint Beast
SPSDenver - Wrapping Your Head Around the SharePoint BeastMark Rackley
 
XPages -Beyond the Basics
XPages -Beyond the BasicsXPages -Beyond the Basics
XPages -Beyond the BasicsUlrich Krause
 
2/15/2012 - Wrapping Your Head Around the SharePoint Beast
2/15/2012 - Wrapping Your Head Around the SharePoint Beast2/15/2012 - Wrapping Your Head Around the SharePoint Beast
2/15/2012 - Wrapping Your Head Around the SharePoint BeastMark Rackley
 
La vita nella corsia di sorpasso; A tutta velocità, XPages!
La vita nella corsia di sorpasso; A tutta velocità, XPages!La vita nella corsia di sorpasso; A tutta velocità, XPages!
La vita nella corsia di sorpasso; A tutta velocità, XPages!Ulrich Krause
 

Ähnlich wie Speed Up Your EE Site (20)

Life In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPagesLife In The FastLane: Full Speed XPages
Life In The FastLane: Full Speed XPages
 
Analysis of Google Page Speed Insight
Analysis of Google Page Speed InsightAnalysis of Google Page Speed Insight
Analysis of Google Page Speed Insight
 
SharePoint 2013 Performance Analysis - Robi Vončina
SharePoint 2013 Performance Analysis - Robi VončinaSharePoint 2013 Performance Analysis - Robi Vončina
SharePoint 2013 Performance Analysis - Robi Vončina
 
CTU June 2011 - Things that Every ASP.NET Developer Should Know
CTU June 2011 - Things that Every ASP.NET Developer Should KnowCTU June 2011 - Things that Every ASP.NET Developer Should Know
CTU June 2011 - Things that Every ASP.NET Developer Should Know
 
Extjs3.4 Migration Notes
Extjs3.4 Migration NotesExtjs3.4 Migration Notes
Extjs3.4 Migration Notes
 
Cloud computing 3702
Cloud computing 3702Cloud computing 3702
Cloud computing 3702
 
How_To_Soup_Up_Your_Farm
How_To_Soup_Up_Your_FarmHow_To_Soup_Up_Your_Farm
How_To_Soup_Up_Your_Farm
 
Extension Library - Viagra for XPages
Extension Library - Viagra for XPagesExtension Library - Viagra for XPages
Extension Library - Viagra for XPages
 
Alfresco tuning part1
Alfresco tuning part1Alfresco tuning part1
Alfresco tuning part1
 
Alfresco tuning part1
Alfresco tuning part1Alfresco tuning part1
Alfresco tuning part1
 
Orlando DNN Usergroup Pres 12/06/11
Orlando DNN Usergroup Pres 12/06/11Orlando DNN Usergroup Pres 12/06/11
Orlando DNN Usergroup Pres 12/06/11
 
Mobile Browser Internal (Blink Rendering Engine)
Mobile Browser Internal (Blink Rendering Engine)Mobile Browser Internal (Blink Rendering Engine)
Mobile Browser Internal (Blink Rendering Engine)
 
Sharepoint Performance - part 2
Sharepoint Performance - part 2Sharepoint Performance - part 2
Sharepoint Performance - part 2
 
Real-time Code Sharing Service for one-to-many coding classes
Real-time Code Sharing Service for one-to-many coding classesReal-time Code Sharing Service for one-to-many coding classes
Real-time Code Sharing Service for one-to-many coding classes
 
UKLUG 2012 - XPages, Beyond the basics
UKLUG 2012 - XPages, Beyond the basicsUKLUG 2012 - XPages, Beyond the basics
UKLUG 2012 - XPages, Beyond the basics
 
Internet Explorer 8
Internet Explorer 8Internet Explorer 8
Internet Explorer 8
 
SPSDenver - Wrapping Your Head Around the SharePoint Beast
SPSDenver - Wrapping Your Head Around the SharePoint BeastSPSDenver - Wrapping Your Head Around the SharePoint Beast
SPSDenver - Wrapping Your Head Around the SharePoint Beast
 
XPages -Beyond the Basics
XPages -Beyond the BasicsXPages -Beyond the Basics
XPages -Beyond the Basics
 
2/15/2012 - Wrapping Your Head Around the SharePoint Beast
2/15/2012 - Wrapping Your Head Around the SharePoint Beast2/15/2012 - Wrapping Your Head Around the SharePoint Beast
2/15/2012 - Wrapping Your Head Around the SharePoint Beast
 
La vita nella corsia di sorpasso; A tutta velocità, XPages!
La vita nella corsia di sorpasso; A tutta velocità, XPages!La vita nella corsia di sorpasso; A tutta velocità, XPages!
La vita nella corsia di sorpasso; A tutta velocità, XPages!
 

Mehr von Ruthie BenDor

Even Naming This Talk Is Hard
Even Naming This Talk Is HardEven Naming This Talk Is Hard
Even Naming This Talk Is HardRuthie BenDor
 
Move Fast And Document Things
Move Fast And Document ThingsMove Fast And Document Things
Move Fast And Document ThingsRuthie BenDor
 
Build Your First EE2 Site
Build Your First EE2 SiteBuild Your First EE2 Site
Build Your First EE2 SiteRuthie BenDor
 
Add-On Migration Planner for EE 1.x to EE 2.x
Add-On Migration Planner for EE 1.x to EE 2.xAdd-On Migration Planner for EE 1.x to EE 2.x
Add-On Migration Planner for EE 1.x to EE 2.xRuthie BenDor
 
All About ExpressionEngine 2
All About ExpressionEngine 2All About ExpressionEngine 2
All About ExpressionEngine 2Ruthie BenDor
 
Content Management for the little guy
Content Management for the little guyContent Management for the little guy
Content Management for the little guyRuthie BenDor
 

Mehr von Ruthie BenDor (7)

Even Naming This Talk Is Hard
Even Naming This Talk Is HardEven Naming This Talk Is Hard
Even Naming This Talk Is Hard
 
Move Fast And Document Things
Move Fast And Document ThingsMove Fast And Document Things
Move Fast And Document Things
 
VersionEEring
VersionEEringVersionEEring
VersionEEring
 
Build Your First EE2 Site
Build Your First EE2 SiteBuild Your First EE2 Site
Build Your First EE2 Site
 
Add-On Migration Planner for EE 1.x to EE 2.x
Add-On Migration Planner for EE 1.x to EE 2.xAdd-On Migration Planner for EE 1.x to EE 2.x
Add-On Migration Planner for EE 1.x to EE 2.x
 
All About ExpressionEngine 2
All About ExpressionEngine 2All About ExpressionEngine 2
All About ExpressionEngine 2
 
Content Management for the little guy
Content Management for the little guyContent Management for the little guy
Content Management for the little guy
 

Kürzlich hochgeladen

TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Farhan Tariq
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...AliaaTarek5
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfLoriGlavin3
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...panagenda
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersRaghuram Pandurangan
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 

Kürzlich hochgeladen (20)

TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
(How to Program) Paul Deitel, Harvey Deitel-Java How to Program, Early Object...
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
Moving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdfMoving Beyond Passwords: FIDO Paris Seminar.pdf
Moving Beyond Passwords: FIDO Paris Seminar.pdf
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
 
Generative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information DevelopersGenerative AI for Technical Writer or Information Developers
Generative AI for Technical Writer or Information Developers
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 

Speed Up Your EE Site

  • 1. Make Your Site SpEEdy Improving the performance of your ExpressionEngine website Prepared by Ruthie BenDor for the BostonEErs September 2010 Meetup
  • 2. Part I: Tools and techniques for Measuring Performance
  • 3. What impacts site speed? 1. Browser rendering time 4. Filesystem disk accessing time 2. Component transmission time 5. Database query execution time 3. Server-side script execution 1 3 2 5 Server-side Browser Database scripts Filesystem 4 Web server
  • 4. What impacts site speed? 1. Browser rendering time 4. Filesystem disk accessing time 2. Component transmission time 5. Database query execution time 3. Server-side script execution 1 3 2 5 Expression Browser HTML MySQL Engine fragments, CSS files, Javascript files, images Filesystem 4 Web server
  • 5. 1 2 Page render time and component load time can be measured with YSlow and/or Google Page Speed for Firebug. (Also useful: Webkit’s Developer Tools.)
  • 6. 3 Server-side script execution can be measured by enabling EE’s Template Debugging. In EE 1.6.x’s Control Panel: Admin › System Preferences › Output and Debugging Preferences In EE 2.1’s Control Panel: Admin › System Administration › Output and Debugging
  • 7. 5 Database queries can be seen by enabling EE’s output profiler. Note that this doesn’t tell us how long a single query takes to run, but it does show us the full query. In EE 1.6.x’s Control Panel: Admin › System Preferences › Output and Debugging Preferences In EE 2.1’s Control Panel: Admin › System Administration › Output and Debugging
  • 8. Part 2: Recommendations for Improving Performance
  • 9. The site optimization cycle Measure performance. (“Benchmark.”) Identify the biggest (or easiest-to-fix) bottleneck. Remove that bottleneck.
  • 10. What impacts site speed? 1. Browser rendering time 4. Filesystem disk accessing time 2. Component transmission time 5. Database query execution time 3. Server-side script execution 1 3 2 5 Expression Browser HTML MySQL Engine fragments, CSS files, Javascript files, images Filesystem 4 Web server
  • 11. 1 Browser rendering time optimizations • Make your Javascript and CSS more efficient, so the browser is able to render (draw) the completed page more quickly. • For writing faster CSS, check out OOCSS: http://wiki.github.com/stubbornella/oocss/ • For writing faster JavaScript, speed-test snippets using JSPerf: http://jsperf.com/
  • 12. 2 Component transmission time optimizations • Minify and concatenate all JavaScript into a single file, and minify and concatenate all CSS into a single file. • If you keep your Javascript and CSS in EE templates, concatenate these assets using this technique: http://easy-reader.net/archives/2010/07/11/ template-based-asset-munging-in-expressionengine • To concatenate and minify JS/CSS in EE templates, try SL Combinator http://experienceinternet.co.uk/software/sl-combinator/docs/, which uses an old version of Minify http://code.google.com/p/minify/ • If you keep your JS and CSS assets outside of EE, use Minify http:// code.google.com/p/minify/
  • 13. 2 Component transmission time optimizations (con’t) • Serve optimized images. • Prevent content maintainers from uploading content images that are too large by using http://www.lumis.com/page/imgsizer/ • Run all site image assets through http://smush.it/ to reduce filesize as much as possible. • Where possible, combine (aka sprite) site image assets. • Enable GZIP compression in EE. In EE 1.6.x’s Control Panel: Admin › System Preferences › In EE 2.1’s Control Panel: Output and Debugging Preferences Admin › System Administration › Output and Debugging
  • 14. 3 Server-side script execution optimizations • Cache individual tags. • Tag caches are time-based, set in minutes. Use on any EE tag like so: {exp:some:tag cache="yes" refresh="30"} • Cache entire templates. • Enabled on a per-template basis. In EE1, look in Templates > Preferences. In EE2, look in Design > Templates > Template Preferences. • Template caches are time-based, mostly - certain events will clear the cache: http://expressionengine.com/user_guide/general/caching.html#template_caching • Template caching supercedes tag caching, so if you’re caching the entire template, there’s no reason to also cache individual tags. • A cached template in EE is still heavier, performance-wise, than a 100% static page served from outside EE.
  • 15. 3 Server-side script execution optimizations (con’t) • Where possible, use Global Variables and Snippets instead of embedded templates. • Snippets can contain EE tags, while Global Variables can contain only HTML. • Snippets are EE2-only. • Why Snippets are faster than embedded templates: http://www.meetup.com/BostonEErs/messages/boards/thread/9783637 • Where possible, avoid nesting embedded templates.
  • 16. 4 Filesystem optimizations • Don’t save templates as flat files. • Why? “Saving templates as files can marginally increase disk 1/o as teach template must be retrieved from disk in addition to the standard database query responsible for managing your template’s meta data (access, PHP parsing, template type, etc.)” - http://expressionengine.com/user_guide/ general/handling_extreme_traffic.html • But flat files are really convenient during development! • Suggestion: work with templates as flat files during development. At site launch, sync all templates back to the database, and set all templates to no longer save as flat files. How? • In EE2, use the built-in Synchronize Templates tool under Design > Templates. • In EE1, either sync manually, or use the free DC Template Manager module: http://devot-ee.com/add-ons/dc-template-manager/
  • 17. 5 Database query optimizations • Set the database connection to non-persistent. • In EE2, set Persistent Database Connection to No at Admin › System Administration › Database Settings • In EE1, set Database Connection Type to Non Persistent at Admin › System Preferences › Database Settings • Reduce the number of queries each page calls. • http://expressionengine.com/wiki/Reduce_Queries/ • Cache frequently used queries. • In EE2, set Enable SQL Query Caching to Yes at Admin › System Administration › Database Settings • In EE1, set Enable SQL Query Caching to Yes at Admin › System Preferences › Database Settings
  • 18. 5 Database query optimizations (con’t) • Enable dynamic channel query caching. • Only enable if your site doesn’t use future, expiring, or random entries. • In EE1, set Cache Dynamic Channel Queries? to Yes at Admin › Weblog Administration › Global Weblog Preferences. • In EE2, set Cache Dynamic Channel Queries? to Yes at Admin › Channel Administration › Global Preferences. • Disable unused parts of {exp:channel:entries} queries. • In EE1, six things can be disabled: {exp:channel:entries disable="categories| category_fields|custom_fields|member_data|pagination|trackbacks"} • In EE2, trackbacks have been removed, so five things can be disabled: {exp:channel:entries disable="categories|category_fields|custom_fields| member_data|pagination"}
  • 19. 5 Database query optimizations (con’t) • Repair and optimize EE’s MySQL tables. • In EE1, look under Admin › Utilities › SQL Manager › Manage Database Tables. • In EE2, look under Tools › Data › SQL Manager › Manage Database Tables. • Disable template tracking. • In EE1, look under Admin › System Preferences › Tracking Preferences. • In EE2, these options must be set manually in config.php.
  • 21. Online Resources • ExpressionEngine.com User Guide • http://expressionengine.com/user_guide/general/caching.html • http://expressionengine.com/user_guide/general/ handling_extreme_traffic.html • http://expressionengine.com/user_guide/templates/flat_file_templates.html • http://expressionengine.com/legacy_docs/cp/admin/system_preferences/ tracking_preferences.html • SolSpace’s EE Website Performance Guidelines • http://www2.grist.org/misc/Performance_Guidelines.pdf
  • 22. Books • High Performance Web Sites, by Steve Souders: http://www.amazon.com/gp/product/0596529309 • Even Faster Web Sites, also by Steve Souders: http://www.amazon.com/gp/product/0596522304
  • 23. Nearby Groups • Boston Web Performance Group: http://www.meetup.com/Web-Performance-Boston/