magento 2 overview. alan kent

Post on 24-Jun-2015

1.194 Views

Category:

Technology

2 Downloads

Preview:

Click to see full reader

DESCRIPTION

Magento 2 overview. Alan Kent

TRANSCRIPT

Magento 2 Overview

Alan KentMagento Chief Architect

MAGENTO 2 TIMELINE & GOALS

Release Approach

2014 20162015 2017

2.0 Dev Beta

2.0Merchant Beta

2.0Merchant

GA

2.xOngoing Releases

2.0 Dev RC

WE WANT FEEDBACK!

magento/magento2(weekly code pushes)

Product and Software Versions

CE EE Verticals?(Fashion & Apparel)

2.0 2.1 2.2 2.0 2.1 2.21.0 1.1 2.0

Modules

Cart Catalog Sales10.0.0 10.0.1 10.1.0

10.0.0 10.1.0 10.2.010.0.0 11.0.0 12.0.0

? = 10

Products

MAGENTO 2: PLATFORM GOALS

M2

Modern tech stack

Improved performance& scalability

Streamlinecustomizations

Simplify externalintegrations

Easier installation& upgrades

High code quality& testing

MODERN TECH STACK

Tech Stack

Integration

IMPROVED PERFORMANCE & SCALABILITY

Page Caching • CE Full Page Caching– Built-in: Filesystem/Redis– External: Varnish

• Private/public content• Cache invalidation logic

Page CachingIndexing

• Refactored: Catalog, Price, EAV, Stock, URL Rewrite, …

• Partial indexing• Work in background• No manual re-indexing• Materialized View (Mview)

Page CachingIndexingPerf Toolkit

• Standard toolkit for measuring performance

• Benchmarking key flows• M2 performance analysis

kicking off in earnest

Page CachingIndexingPerf ToolkitScalability

• Making it easier to scale • Blueprints for successful

scaling strategies

Docker and Simplifying Cloud Scalability“Docker - An open platform for distributed applications for developers and sysadmins”

• Public collaborative project (GitHub) to define standard recommended Docker images

• Each server registers itself in etcd• Each server watches other clusters for

changes in membership

CDN

Varnish

Apache2

MySQL REDISSOLR

Reverse Proxy

…… …

Master

ReplicaReplica

R/W RO RO

Store FrontAdmin JobServer

Payment Gateway

ETCD

Varnish fan outPURGE requests

NEW

https://hub.docker.com/u/alankent/27 Magento images from 19 community

members already on public Docker repository

STREAMLINE CUSTOMIZATIONS

Dependency Injection• Encourages loose code coupling

Mage Class

• God Class “Mage::” is eliminated

Mage::getModel('Magento_Customer_Model_Address')

Interceptors & Plugins• Before method• After method• Around method• Sorting

Magento Framework

All framework code in one namespace

Modularity

Framework/ View

Block Rendering

Template Engine

Layout Infrastructure

View

Framework/ App

Front Controller

Request/ Response

Boot-strapping

Routers

App

Magento/ Adminhtml

*{Module}/ Adminhtml

Catalog/ Adminhtml

Customer/ Adminhtm

l

Admin

Modularity• Product: optional product types• Catalog: new modules, delete from code• Sales: extracted Recurring Payment• Shipping: carrier, decoupled shipping methods• Checkout: extracted Term&Conditions, multishipping• Payments: offline payment, decoupling payment methods

Price Logic• Price logic decomposition per price

type • Price Interfaces• Price decoupled from Tax and Weee• Price “adjustment”

i18n• Global function __()• Phrase• RendererInterface• Composite, Inline, Placeholder, Translate • [Module]/i18n

Layouts• Layouts, templates (view) in Modules• Layout file responsible only for single page/block• Validation Layout XML (XML Schema)• Extend Layout• Merging Layouts• Override Layout• Page Types

Magento UI Library• Upgradability

• Consistency

• Reusable Magento UI components

• Styling and design best practices

• Good documentation

• Simplifies customization

Blank Theme

Mobile First Responsive Design

Multilevel Theme Inheritance• Simplifies customization• Flexible store design• Allows store to be

special• Maintainability• Less code duplication

SIMPLIFY EXTERNAL INTEGRATIONS

Service Layer and Web API• Consistent, versioned PHP & Web Service API• REST & SOAP• Evolution strategy

– Super-glued: No restriction of what is called– Tightly coupled: Restricts calls to “stable” API– Loosely coupled: Restricts access to interface based API

(allows service replacement)

Side Benefit of Web Services:Exposing the Magento Schema

Customer

Addresses

Region

Customer Group

Customer Account Services

Cart

Cart Repository

Address Totals

Region Total Item

Cart ItemData Model

EASIER INSTALLATION & UPGRADES

Composer and Deployment Tool• Command line for advanced users• Web based for simpler use cases• Modules, extensions, faster patches

magento/magento-composer-installer

HIGH CODE QUALITY & TESTING

Test Automation• Full set of tests: Unit, Integration, Static, Legacy• Functional Test – Magento Testing Framework (MTF)• Continuous Integration & Continuous Delivery• Performance Testing• Regression Testing

magento/mtf

CONCLUSIONS

In a Nutshell• On track time-wise• Upgrade of tech stack• Decoupling and cleaning up the code base• Controlling cross module dependencies better• Marching towards full test automation

Thank You!

@akent99

https://github.com/alankent

http://alankent.wordpress.com/

https://registry.hub.docker.com/repos/alankent/

top related