DrupalCamps 2012 Drupal it all comes down to performance Janis Janovskis @PASSIVUS http://passivemanagement.net
May 11, 2015
DrupalCamps 2012
Drupal it all comes down to performance
Janis Janovskis
@PASSIVUS
http://passivemanagement.net
Drupalit all comes down to performance
?
Drupalit all comes down to performance
WHY?
WHERE?
HOW?
:)
Drupalit all comes down to performance
Database level – wt … is cache?✔ cache_block✔ cache_bootstrap✔ cache_field✔ cache_form✔ cache_.....
Drupalit all comes down to performance
Database → cache_your_???();✔ cache_set✔ cache_get✔ ctools_include('object-cache');✔ ctools_object_cache_set('my_module', $id,
$object);✔ ctools_include('object-cache');✔ ctools_object_cache_clear('my_module', $id);
Drupalit all comes down to performance
Database → caching();✔ Query caching – query_cache_type=1✔ table caching – memcache✔ noSQL
➔ MongoDB➔ CouchDB➔ Reddis➔ ….
Drupalit all comes down to performance
PHP✔ APC✔ XCACHE✔ Remove redundant modules(code)✔ Profiling (Xhprof)
Drupalit all comes down to performance
PHP - Modules✔ entity_cache✔ boost (best on shared environments)✔ block_cache_alter✔ memcache api integration✔ apc integration✔ elysia cron (better cron job management)✔ ajax blocks
Drupalit all comes down to performance
Drupalit all comes down to performance
Filesystem - backendFilesystem - backend✔ File size limitations (file field configurationFile size limitations (file field configuration✔ aggregate cssaggregate css✔ aggregate jsaggregate js✔ remove redundant css/jsremove redundant css/js✔ cdncdn
Drupalit all comes down to performance
Files –> front end();✔ Build in css/js architecture (“clearfix”)✔ Built in js framework (jQuery, + jQuery UI(D7✔ Image preloads
ADMIN
THEMETHEME
CONTENT
MODULE
Drupalit all comes down to performance
Performance → Web servers();✔ Load balancing✔ Apache mod_proxy✔ Ningx vs Apache✔ Varnish proxy caching
Drupalit all comes down to performance
TESTING YOUR BUILT
✔ DrupalWebTestCase✔ devel module → query information✔ views statistics✔ performance tests(jmeter)
Drupalit all comes down to performance
www.bounty.com✔ ~1.5 milj. users✔ Affiliate marketing solutions✔ Embed community✔ “Crapped” (not fresh) backend✔ Almost no documentation✔ Offline db integration
Drupalit all comes down to performance
Architecture
LOAD BALANCER
APACHE2
APACHE1 MEMCACHE1
MEMCACHE1
MYSQLFILE SERVERMYSQLMYSQLMYSQL
Drupalit all comes down to performance
Bounty → Improvements();✔ No panels✔ Block instances✔ By, by boot :)✔ Education – tutoring✔ Micro-sites✔ Code improvements(Documentation)✔ Removing redundancies (profile module)
Drupalit all comes down to performance
www.savethechildren.org.uk✔ 25 editors✔ UI friendly configuration
➔ Panels➔ Context➔ Views➔ Pages
Drupalit all comes down to performance
Architecture
LOAD BALANCER
MYSQL
varnish1
varnish1
apache1
apache2
memcache1
memcache2
MYSQLMYSQL
files
Drupalit all comes down to performance
Save the Children → improvements();✔ Memcache✔ Profiling with xhprof, devel✔ Contributing to community✔ Education✔ … I am still on this role …..
Drupalit all comes down to performance
Improvements → personal();✔ Analysing✔ Contributing✔ Training✔ Sharing
Drupalit all comes down to performance
Thanks
http://passivemanagement.net
@PASSIVUS