30
WHAT KEPT US BUSY A QUICK SUMMARY OF A YEAR WORKING IN CAKEPHP CakeFest 2013 @jose_zap

CakeFest 2013 keynote

Embed Size (px)

DESCRIPTION

This keynote presented in CakeFest 2013 contains a small summary of the things we have been working on for CakePHP 3.0

Citation preview

Page 1: CakeFest 2013 keynote

WHAT KEPT US BUSYA QUICK SUMMARY OF A YEAR WORKING IN CAKEPHP

CakeFest 2013 @jose_zap

Page 2: CakeFest 2013 keynote

CAKEPHP IS COMMUNITY DRIVENThis is both good and bad. There is a slower pace in what wedo, but the result is a consequence of what the community is

actually asking for based of the collective input.

Page 3: CakeFest 2013 keynote

WE GROW OLDER, BUT WISERIn general, people working in any organization...

Page 4: CakeFest 2013 keynote

JOIN

Page 5: CakeFest 2013 keynote

GET PASSIONATE ABOUT IT

Page 6: CakeFest 2013 keynote

GET EXPERIENCE

Page 7: CakeFest 2013 keynote

GET BORED

Page 8: CakeFest 2013 keynote

GET MARRIED, HAVE CHILDREN

Page 9: CakeFest 2013 keynote

BECOME BUSIER

Page 10: CakeFest 2013 keynote

AND SOME... LEAVE(sad panda face)

Page 11: CakeFest 2013 keynote

THE CORE TEAMHAVE A CONSTANT DREAM AND A PASSION TO MAKE THINGS BETTER

Page 12: CakeFest 2013 keynote

THIS IS A SUMMARY OF THE THINGS WEDREAMT ABOUT

and made its way into the code

Page 13: CakeFest 2013 keynote

HELLO PHP 5.4

Page 14: CakeFest 2013 keynote

NAMESPACESWe hate \ (wrong slash) but we finally converted the virtual

packages into namespacesif (strpos($class, '\\') !== false)

Yes, we'll keep using the plugin syntax and save from writingthings like that

Page 15: CakeFest 2013 keynote

NEW UNIFIED CONFIGConfiguration is passed directly to the classes that are

interested about them

Bye, Bye DATABASE_CONFIG

Page 16: CakeFest 2013 keynote

COMPOSER SUPPORT OUT OF THE BOX

Page 17: CakeFest 2013 keynote

FASTER, BETTER ROUTERReverse routing got extremely fast and now it is possible to

have named routes!

Page 18: CakeFest 2013 keynote

ROUTING PREFIXES USING NAMESPACESInstead of UsersController::admin_index() you will have a

separate Admin\UsersController::index()

Page 19: CakeFest 2013 keynote

FASTER, CONSISTENT AND LEANER EVENTMANAGER

Page 20: CakeFest 2013 keynote

FEATURE RICH HTTPSOCKET CLASS

Page 21: CakeFest 2013 keynote

NEW QUERY BUILDERCreate queries using a fluent interface with automatic type

conversion

$union = (new Query($connection)) ->select(['id', 'title']) ->from(['a' => 'articles']);

$results = (new Query($connection)) ->select(['id', 'comment']) ->from(['c' => 'comments']) ->where(['created >=', new DateTime('1 day ago')]) ->union($union) ->execute();

Page 22: CakeFest 2013 keynote

SMART SQL DIALECT TRANSLATIONYou can use this in both PostgreSQL and MySQL

$query = (new Query($connection))->select(function($q) { return [ 'id', 'full_name' => $q->concat(['first_name', ' ', 'last_name']) ]});

Page 23: CakeFest 2013 keynote

SMART ASSOCIATION EAGER LOADINGThis will use a single query

$table = Table::build('author');$table->hasMany('article', [ 'property' => 'articles', 'strategy' => 'subquery', 'sort' => ['article.id' => 'asc']]);$results = $table->find('all')->contain('article')->toArray();

Page 24: CakeFest 2013 keynote

CHAINABLE CUSTOM FINDERSWoot!?

$articles->latest()->popular()->list()->toArray();

Page 25: CakeFest 2013 keynote

RESULT STREAMING

Page 26: CakeFest 2013 keynote

STOPPABLE FINDSBefore find callbacks can stop the query from being executed

and return cached results

Page 27: CakeFest 2013 keynote

MAP-REDUCE

Page 28: CakeFest 2013 keynote

SCHEMA MIGRATIONS

Page 29: CakeFest 2013 keynote

AND MUCH, MUCH MORE

Page 30: CakeFest 2013 keynote

WELCOME TO CAKEFESTThis is the right place to figure out where we are heading