The e-commerce is one of the main points of modern software. The e-commerce sector is growing about 15% annually, which is why it deserves special attention from software engineers. Speaking of e-commerce and open source at once is not easy. For many years we have identified the concept with pain and despair, so we must work urgently to change the way we understand it should be. What are the important points to consider? Where do we find the line between architecture and pragmatism? Are we walking in the right direction? How can Symfony help in this?
Co-founder and lead at Elcodi
Organizer of Symfony Barcelona UG
Entrepreneur in AntaiVB - Barcelona
Maintainer of several open source Libs and Bundles
(GearmanBundle, ControllerExtraBundle, Visithor, php-
About this talk
E-commerce in PHP until 201*
E-commerce project life cycles
Architecture for pragmatic development
Symfony in action
3 tips about Elcodi
PHP Until 201*
So… why are they that used?
A lot of users and developers have based their
companies on them (YAY! Me, want!)
BIG and Extremely well created plugin and template
E-commerce with minimum time-to-market
Minimum Valuable Project
The minimum you need to make sure you can measure the
impact of your application - First stage… ALWAYS!
Small investment (FFF)
Small budget to spend on everything
Perfect for applications with advanced template and plugin
Technology is not used to being important here
And, in fact, it should never be…
Most of times, projects die after this stage because the
market is not ready or the project is not valuable enough
Fast set-up technologies are used here
Business Angels in action!
Bigger budget than before, but not as big as we’d love to
We can spend a little bit more on technology
This is where we need to make the difference, so…
This is where a lot of companies start a refactoring
This refactoring is used to costing too much money $$$
Everything is for yesterday :’(
Things are done poorly and rapidly
After MVP : #tip
Choosing here your strategy can save your project!
As important as MVP, but even more difﬁcult to manage
Smart decisions will be important
When Venture Capital
The amount of money is much bigger (shut up and take
We are going to be a player, so our technology must be a
player as well
Time for do all these things you always had in mind
No excuses, you have to hire talent and be responsible
Just some questions…
From a technical point of view… what criteria should I
follow about when deciding an E-commerce platform?
Do I feel confortable working with it?
Will I be able to born with this project?
Plugins, Templates, User documentation
Will I be able to grow with this project?
Excellent technical documentation, Communication,
Will I be able to increase my skills as developer using
Will I be able to do it… properly?
Will I (as a company) co-exist with this technology?
For how long?
Just some questions…
Should I test my MVP application?
Take a tested (or popular) platform when you need to
reach your MVP
If your project is not going to grow, take the project with
the most advanced plugin and template system. Forget
about everything else
You may not care about the roadmap of the project if
your project ends as soon as you ﬁnish it
If your project is LTS, then… tests battery will only tell
you if the initial product works properly
You will really need tests after your MVP, and your
application will be completely different
You will have to do your own tests then. Be ready for that!
That one of the things you could invest on with your new
Just some questions…
What architecture should I use?
What architecture allow you to overwrite more easily
Cart, Product, Shipping, Payment
Admin functionalities, integrations, change capacity
What architecture allow your team to understand the business model?
What part of the application handles your business logic? Service layer?
Model? Commands + Controllers + EventListeners + Twig Extensions?
CQRS, Event-Driven Design… do you really know how it works?
Annotations at the beginning, maybe? Easier :)
Choose the architecture that
really fits your case
As soon as your developers (or you) are better, then your
needs will be bigger and stronger
Technology will follow you, not vice versa
Don’t base your E-commerce on practices you don’t
really know how to handle with
Annotations will become bad practices, maybe
You will understand that an Event Listener, for example,
should have 0 business Logic (Same as other entry points)
You will NEED tests in all your developments. Not for the
“tested” badge on Github, but only for you
You will understand as well why ValueObjects are great,
What parts of Symfony can really help us on our
adventure <E-commerce case>!
Tests integrations (PHPUnit, Behat, Visithor…)
Event-Driven Design is one of the most important things
when you want to build a Plugin-based environment
+Events = +Extension points = +Adopters =
How easy overwriting a service is by registering your
own service with the same name (after the original one)
Good for composition and inheritance
+Easy to overwrite = +Customizations = +Adopters =
Set of E-commerce PHP Components
Set of Symfony2 bundles for these components
Project called Bamboo. Full stack E-commerce based on
Elcodi + Symfony components and bundles.
By giving us a star is like… Hey guys! You’re cool ;)
Elcodi Tip #1
Intended to be a great option for MVPs
Create a Plugin environment on top of Symfony Bundles
Template as a Plugin
Install in less than 2 minutes with Heroku (i.e.)
4 layers of testing
Elcodi Tip #1
[Components] PHPUnit for unit testing of our Service
[Bundles] PHPUnit for functional testing of our processes
(services, event listeners, event dispatchers…)
[Bamboo] Behat for behavioral testing (user processes…)
[Bamboo] Visithor just for testing the HTTP layer
You only need a single and small YAML ﬁle, and some
lines. One per route.
Deﬁne your routes by url, url name (Visithor) +
Authenticate in a Firewall with a ROLE (Admin routes)
Elcodi Tip #2
Intended to be a great option after MVP
Use Symfony ecosystem for evolving your project. No
The project is built on top of some Best Practices, and is
treated with A LOT OF LOVE
Both developer and ﬁnal user oriented. No one is less
important than the other one
Elcodi Tip #3
Community-Driven. Developers are the brain of any open
source project. Final users are the heart
The more happiness any open source project provides,
the more quality offers
Join us on this adventure :)
Elcodi Extra Tip
Elcodi (L) Symfony ^3.0.0 (December 2015)
Elcodi App Market (2016)
And… much, more, soon!
Emanuele Minotto, new Core dev :) Thanks dude!
Each E-commerce stage needs different strategies
Check all Symfony E-commerce solutions, and ﬁnd the
one who REALLY makes you feel comfortable
And if you really love E-commerce… consider getting
involved in one of them, and spread the word :)
and meanwhile… read!
Differences Elcodi - ~^.*$~
Elcodi is a ready-for-production project
We offer both a project and a way of doing, of
understanding open source and collaborative projects
Just make sure you discover this way of doing, and join us
if you really enjoy it
We are still waiting for your feedback and energy :)