260 likes | 283 Views
Challenges and opportunities with M2. Christos Stavrakis Leader PHP Web Developer. Christos Stavrakis Leader PHP Web Developer. About Me Senior PHP Developer on Magento 1 CE/EE & 2 CE Senior PHP Developer on Zend Framework 2 MSc in Information System BSc in Mathematics.
E N D
Challenges and opportunities with M2 Christos StavrakisLeader PHP Web Developer
Christos StavrakisLeader PHP Web Developer About Me Senior PHP Developer on Magento 1 CE/EE & 2 CE Senior PHP Developer on Zend Framework 2 MSc in Information System BSc in Mathematics
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching (enable Gzip compression)5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
What I can do to improve magento performance? 1. Upgrade to latest version2. Implement a CDN with Magento3. Utilize Caching (Varnish/Memcache/Redis)4. Browser Caching5. Enable Flat Catalog6. Image Optimization7. Merge CSS and JavaScript Files8. Clean Up Magento Database & Logs9. Disable Unnecessary Extensions & Modules10. Code Optimization
Code Optimization!– What I can do for that? As long as your site becomes bigger... a) New data continuously feeds your Data Base (quotes, orders, products, logs, customers… etc)b) New business logic, adds more complexity to PHP (analytics, newsletter, custom related products… etc)c) More customers visiting and shopping!!
Code Optimization!– What I can do for that? 1) Start optimization from most visited pages a. Home Page b. Product Page c. List Page d. Cart e. Checkout !!! ← Be careful here
Code Optimization!– What I can do for that? 2) Inspect PHP code a. Follow Magento Coding Standards (ALWAYS!!) → Read from devdocs.magento.com, (always updated with the last version of Magento) → Read about proper module structure... → Read about test driven development in Magento
Code Optimization!– What I can do for that? 2) Inspect PHP codeb. Remove raw SQL queries inside *.phtml files → Use Blocks and ViewModels for this job! → You gain Blocks Html caching system
Code Optimization!– What I can do for that? 2) Inspect PHP code c. Inspect every product collection and remove any new product load inside iteration → Add additional attributes in product collection instead → You gain less queries in DataBase
Code Optimization!– What I can do for that? 2) Inspect PHP code d. Proper Exception Handling → Implement custom Logger and use try,catch try{/* Some logic that throws exception */ }catch(\Exception $e){ $this→logger→critical($e→getMessage()); }
Code Optimization!– What I can do for that? 2) Inspect PHP code e. Optimize Cron-Jobs → ERP crons → Import/Export Products crons → Feeds export crons → Use “Pagination” for large collections → Gain CPU and Memory from your server and give it to your customers.
Developing!– What I can do for that? Magento Modularization System 1. Create New Magento 2 Shipping Methods → ACS * → Speedex * Note: Try to mimic native Magento shipping methods and build your own logic inside them. * has been developed by
Developing!– What I can do for that? Magento Modularization System 2. Create New Magento 2 Payment Methods → Eurobank * → Peiraius Bank * Note: Try to mimic native Magento payment methods and build your own logic inside them. * has been developed by
Developing!– What I can do for that? Magento Modularization System 2. Create New Magento 2 analytics/marketing modules → Linkwise * → ContactPigeon* → Warply ** has been developed by
Developing!– What I can do for that? Magento Modularization System 3. Feel free to change or extend the Magento application, with your own creativeness!!! (..create modules like ExtendCore, ExtendTheme…etc)Just Follow the rules!!!!
Thank you! Christos StavrakisLeader PHP Web Developer