content management systems and refactoring - drupal, wordpress and ez publish

30
On Content Management, Technology and Refactoring Jani Tarvainen , @velmu , 2014/12/19

Upload: jani-tarvainen

Post on 22-Jan-2018

1.122 views

Category:

Internet


0 download

TRANSCRIPT

On Content Management, Technology and Refactoring

Jani Tarvainen, @velmu, 2014/12/19

Agenda and Focus

• History, briefly on today and a practical example of one way forward

• Focus on, but not limited to, Open Source PHP Content Management

• I'll just pretend I know it all and am always right

• In a developer mindset, no business agenda

Content management in the Nordics

• EpiServer, Midgard, SiteCore, eZ Publish, eScenic, Polopoly, Umbraco...

• The Nordics are a great place to do content management, but momentum seems to be shifting to central Europe

• There are not enough Content Management Hipsters around

• A lot of CMS enthusiasts (WordPressers, Drupalistas, Joomlagsters, etc.)

• Finns like to build websites, but not tools to build websites?

A reference (nevermind the Finnish)

• ...toimittama ratkaisu on globaalisti käytettävä Internetin julkaisu- ja sisällönhallintajärjestelmä. Se mahdollistaa sekä konserninmaailmanlaajuisesti levitettävän aineiston että maakohtaisen, paikallisilla kielillä valmistettavan sisällön hallinnan ja julkaisunkeskitetysti yhden järjestelmän kautta. Sisällönhallintajärjestelmänavulla Kone voi lisäksi rakentaa uusia palvelukokonaisuuksia täysinitsenäisesti.

Y u no say it's responsive?

Content Management Yesterday

• Pay a million dollars for some HTML forms, a database and some scripts to tie those together.

• Noobs started creating similar software for themselves with LAMP

• Better technology does not always "win", hip and easy does.

• Throwing money at it also worked.

Content Management Today

• Everything and nothing has changed

• The forms, DB and scripts free, but they're still just that in better(?) tech

• The noobs (and PHP) grew up, "their" software now powers the internet

• You can really setup a great website without coding skillz

• Known brands dominate, even though anyone can create cola

Content Management Today

• Content management is a commodity nowadays

• Expectations high: "Make it work like Google, Facebook and Apple do"

• Popular tools were not built for today, they have evolved for today

• 10+ year old feature rich software translates to a lot of legacy

• Wordpress and Drupal onboard: REST API is a sure bet in bullshit bingo

• Status quo likely to hold a few years, nothing groundbreaking in sight?

Content Management Tomorrow?

• The ferry trip ticket is free, but you're expected to spend at the taxfree on hosting, support, marketing automation, spam blocking...

• Some thoughts on sustainability:• Scaling Open Source communities

• Five for the Future

Famous quotes

• "WordPress is too big to fail"

• "Nobody ever got fired for buying Drupal"

• "If I had asked people what they wanted, they would have said a better Joomla!"

• "If all you have is eZ Publish, everything looks like content to publish”

Why change and is it even possible?

• "The Unix philosophy emphasizes building short, simple, clear, modular, and extensible code that can be easily maintained and repurposed by developers other than its creators."

• Our current tools are like Windows. Victims of their own success.

• Why do we reinvent the wheel? Create abstractions for content, etc.

• Operating systems being cloudified, but we still scaling with "servers" not services

Why change and is it even possible?

• The previously impossible does happen: Nokia phones sold to Microsoft as they fight irrelevance

• There needs to be a real payoff for change, not just tech tinkering

• These systems enforce you to work on their terms and you can't often genuinely swap pieces like in a framework

• Decoupling been trumpeted for years, but most CMSs remain monoliths

Bergie's decoupling slide

Create - Decoupled CMS interface from Henri Bergius

Examples of change in LAMP CMSs

• WordPress: Nothing fundamental yet, gradual improvements• Large scale change will be monumental (not core, but the plugins)

• Giant user and developer base to please

• "We are a framework!"

• Typo3: Write your own PHP web framework• No, just no.

Examples of change in LAMP CMSs

• Drupal 8: Introducing more common components• Major technical improvements to Drupal with Symfony Components

• Drupalisms, but with new stuff... a bit of a bastard.

• Some developer upheaval: a credible Drupal 7 fork

• Apostrophe: Rebuilding from scratch (Symfony1 -> Express.js)• Lots of work and two parallel versions

• An interesting project to follow!

RefactoringeZ Publish

Some truths about eZ Publish

• eZ Publish is not easy!

• eZ Publish will not take over the world!

• eZ Publish will not be as easy to hack as WordPress!

• eZ Publish does not "have a module for that" like Drupal!

• eZ Publish can still be a good choice for some use cases!

Solid basic concepts since, like... forever

• One application with one or more content repositories (with a tree)

• Perform queries on content (object) or location (node)

• Sites are configured views to a repository:• Site matching with domain, path, combo

• Site root location

• Languages

• Designs…

Starting point

• Started in 1999, ticks "all the boxes" in the feature lists ('membathese?)

• Custom MVC framework, DB, based on 2002 PHP4 OOP (static methods)

• Core product has rich text editing, locations, versioning, multilanguage, Solr search engine, auditing, web store, full XML content, REST API, etc...

• Limited popularity due to complexity and learning curve

• It works, but clearly the end is nigh

Refactoring eZ Publish

• Move to full stack Symfony2 with 100% backwards compatibility

• No DB schema change for legacy storage engine

• Storage engines are pluggable, currently legacy and legacy_solr(Elastic Search being worked on)

• Refactoring legacy functionality gradually to services

• Symfony3 in the future is an evolution, not a revolution

Refactoring eZ Publish

• Leveraging Symfony2 for authentication, routing, Doctrine DBAL...Uses Symfony2 bundles

• (Flysystem, Stash, Imagine, HTTPCache...)

• Existing framework documentation applies

• It took around 2 years for a version to be honestly great

• New admin interface and other changes in 2015

• Just one Open Source eZ Platform

Relevant versions*

• 4.7: The last legacy version

• 5.4: The last version with Symfony2 and legacy support

• 6.x: Symfony2 stack only

• API: eZ API and Domain objects only

* Community versions use YYYY.MM versioning

Working with 2014.11 - the great

• Woot, it is HMVC through and through. Symfony2 devs feel at home!

• Upgrade from a 2008 eZ Publish worked

• You can gradually refactor your legacy site(s):• Use a mixture of legacy and new template code

• Access legacy kernel anywhere (in a closure)

• Add new sites without legacy functionality calls

• Caching is Symfony awesome

• PHPStorm autocompletion for API kicks ass

Working with 2014.11 - the bad

• You'll need to know a lot to get started and it's work in progress

• Documentation is not really great, no established good practices

• Would need more "how-to" articles to gain popularity

• Symfony template functionality still not teh bestest (theme inheritance)

• Rapid development (coding can't touch Drupal clicking, WP hackability)

• Performance? I guess well built Symfony2 scales enough for most needs

Working with 2014.11 - the hmmm…

• So it's nice for developers, but no beef for the customers yet

• You can do things faster in XYZ if you know it

• Still limited adoption

• No set public site architecture (think Drupal behaviours, etc.)

• Symfonysms apply

Divide and conquer

• Use best from elsewhere, don't use the CMF/CMS for everything

• Full REST API and a client lib for single page apps (Angular, Ember...)

• Leverage Elcodi or Sylius components for eCommerce

• Push emails to RabbitMQ for sending, or other batch jobs?

• No need to include the whole stack to use just the API in your apps

Cool links of the day

• Sulu CMF

• Keystone.js

• Bolt CMS

• October CMS

• PHPCR

• ORO CRM

• Developing with prismic.io

• Contentful for developers

• Symfony and CMS: Comparing Bolt, Drupal 8 and eZ Platform

Thanks