• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Death of variables revisited
 

Death of variables revisited

on

  • 259 views

Current state of Configuration System (CMI) in Drupal 8. What it is for and how does it work?

Current state of Configuration System (CMI) in Drupal 8. What it is for and how does it work?

Statistics

Views

Total Views
259
Views on SlideShare
259
Embed Views
0

Actions

Likes
0
Downloads
0
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

CC Attribution License

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Death of variables revisited Death of variables revisited Presentation Transcript

    • CMI: Death of Variables revisitedRoni KantisThursday, May 16, 13
    • Roni Kantisdrupal.org: bfr@roni_kantisDruid Oy@druidfiDrupal Meetup Finland14.6.2013Program:Sauna, terva and kossu.Generously sponsored by the association andKW Digital.druid.fi/meetupThursday, May 16, 13
    • Current state of configuration• 95% of Drupal development is done through UI• Scattered throughout the database• Variable table• Custom tables and entities• No standard format• No APIThursday, May 16, 13
    • Thursday, May 16, 13
    • Features -module" Features is not a reliable way to deploy configurationchanges.It was never meant to be. "- Tim PlunkettThursday, May 16, 13
    • Problems with variables• No standardized way to move between environments• Cumbersome to manage environment specific configuration• Loaded on every requestThursday, May 16, 13
    • So we killed it!- No more variable_trololoo()- No more Features?Thursday, May 16, 13
    • Enter Configuration Management Initiative (CMI)•Configuration system•ConfigEntity•States APIThursday, May 16, 13
    • Configuration system• Automatically exportable• Lazy loadable• UUID in core• Standardized APIThursday, May 16, 13
    • Content vs configuration• Can you give it a default value?• Would it benefit significally from direct sql-queries?• Is it environment specific?Thursday, May 16, 13
    • How does it work?• Object oriented approach:• BEFORE: variable_set(‘my variable’, $data);• NOW: $config->set(‘my variable’, $data)->save();Thursday, May 16, 13
    • How does it work?• Configuration locations:• sites/default/files/config_{hash}/active• sites/default/files/config_{hash}/staging• Configuration files:• manifest.image.styles.yml• image.settings.yml• image.style.medium.ymlThursday, May 16, 13
    • Image.style.medium.ymlThursday, May 16, 13
    • Configuration sync UIThursday, May 16, 13
    • Configuration sync UIThursday, May 16, 13
    • Questions?Thursday, May 16, 13