Slide 1

Slide 1 text

Introduction to Contentful

Slide 2

Slide 2 text

Training Delivery Manager Jim Ambras ❏ Led the development of software products in Silicon Valley in companies ranging from 2 person startups to Fortune 50 companies. ❏ Been working with Drupal since 2007 and was the founding VP of Product Development at Zip2, an early SaaS CMS startup used by over 220 media companies before being acquired by Compaq/AltaVista. Previous to Contentful Ambras was a Pre-Sales Solutions Architect at Acquia. ❏ A lifelong music lover, he also contributes to the Volumio open source audiophile music player, developing its Spotify plugin in Node.js and Angular. ❏ B.S. degree in Computer Science from Syracuse University and did graduate study in computer science at Stanford University's School of Engineering.

Slide 3

Slide 3 text

Please raise your hand if you have previous experience with… ✔ Drupal/ Acquia ✔ Wordpress ✔ AEM ✔ Sitecore ✔ CoreMedia ✔ Typo3 ✔ Other

Slide 4

Slide 4 text

What is your experience with Contentful? I’ve used it and am loving it! I have some experience with it. What is Contentful?

Slide 5

Slide 5 text

Why Contentful?

Slide 6

Slide 6 text

Websites used to be only for customer acquisition

Slide 7

Slide 7 text

… but today reach across the full customer lifecycle

Slide 8

Slide 8 text

In the past, digital content meant websites

Slide 9

Slide 9 text

… but today involves multiple customer touchpoints

Slide 10

Slide 10 text

Our big platform bet: stacks beat suites Innovative companies will assemble their DXP, with a content platform at the center DX Suite DX Stack vs. Monolithic Marketing Suite

Slide 11

Slide 11 text

Contentful lets you build digital products, fast APIs JSON Structured content Reuse and repurpose content, independent of channel or language Composable stack, connected to other platforms, at cloud scale Integrate with digital delivery workflows for launch & optimization Decoupled architecture Agile workflows

Slide 12

Slide 12 text

Contentful in action Customer use cases and industry achievements

Slide 13

Slide 13 text

Enterprises are replatforming on Contentful TELUS transformed from slow and repetitive content updates to agile product releases for 12M customers Before Siloed content Slow to market Technical debt 7 content sources across 5 business units, powering 30+ digital products/properties After Fast time-to-value: reference architecture Low risk: more experiments & iteration Improved agility: 11 deploys per day One content infrastructure to rule them all, across business units and digital products 4x faster

Slide 14

Slide 14 text

Proven results across multiple solutions Teams can launch, iterate, and experiment with new digital products more rapidly 5x faster to launch new customer touch points Modern stack Websites 3x faster to launch new event and campaign microsites Personalized experiences 14% increase in conversion rate with personalization integrations Agile eCommerce 66% decrease in unit cost of new digital products across business teams Digital delivery platforms

Slide 15

Slide 15 text

12x faster to create and launch new landing pages Faster launches BeautyCounter dramatically speeds up the time it takes to publish new content

Slide 16

Slide 16 text

78% reduction in page load time Leading to: 31% reduction in bounce rate 11% increase in conversion rate “Site speed gains helped us become more competitive in search engine rankings.” Speedier sites & apps TUI Nordic achieves significant site speed gains by moving to a modern tech stack

Slide 17

Slide 17 text

14% increase in conversion rate Plus: 4x faster to market 30% increase in page load speed 4x improvement in YoY digital sales Higher conversion rates TELUS integrates personalization and testing tools with Contentful for better results

Slide 18

Slide 18 text

4 Days From brief to going live Faster launches Tribal/DBB built a new microsite for New Zealand Trade & Enterprise for Covid-19 info

Slide 19

Slide 19 text

Any channel, anywhere No matter where your customers are: mobile or web, online or onsite, all around the world Mobile Apps 2x quicker app load times Cross-Channel Experiences 4x faster to launch new onsite/offline and online experiences 98% reduction in time to launch new pages across multiple geographies Global Localization

Slide 20

Slide 20 text

Create reusable content Reuse the same content across pages, properties, and channels JSON output Rendered view Rich text editor view

Slide 21

Slide 21 text

Contentful technical overview

Slide 22

Slide 22 text

Content at scale Independent editorial and development workflows Using environments for agile development Refactoring content models Content intended to be used for multi-channel delivery

Slide 23

Slide 23 text

Content Management API Read/Write Create, edit, publish, unpublish, archive, and delete content and content model Content Preview API Read-only Retrieve draft and updated content in addition to published content Content Delivery API Read-only Retrieve published content to display in an app or website Images API Read-only Retrieve and apply transformations to images stored in Contentful Contentful core REST APIs

Slide 24

Slide 24 text

Contentful runs as a SaaS Service

Slide 25

Slide 25 text

Contentful is a content platform Content Creator Content Delivery API CLI Web App Content Management API SDK SDK SDK Apps & Websites Conversational & Wearables Apps & AR/VR Powerful CLI and tooling to integrate into existing developer workflows or to help define brand new workflows The APIs, webhooks and SDK’s developers need to power content in any digital product Content Preview API Customizable web app for marketers and publishers to collaborate and create content Developer Images API

Slide 26

Slide 26 text

Contentful terminology Organizations Top most parent object, connects users to a company. Users A User can have access to all or limited access to certain spaces based on roles & permissions. Spaces A child entity of an organization. A container for content, assets and UI extensions. Environments Are entities belonging to a space, they contain an isolated copy of content and assets. Implications for content modeling

Slide 27

Slide 27 text

Security & compliance Application security Compliance ISO 27001 certification TLS v1.2 for content delivery and mgmt AES-256 encryption Secure headers using HSTS CMA/CDA separation Web application firewall (Incapsula) Automated vulnerability testing Scanning & security penetration testing AWS Identity and Access Management Continuous monitoring (Librato, New Relic) All content changes require explicit authentication Full entry history recorded in log files PCI compliant, external scan every three months

Slide 28

Slide 28 text

Performance CDN Application Integrated CDN offering (Fastly for JSON; Cloudfront for images / assets) Capable of caching API data, purgeable within 150 milliseconds Optimized to serve binary assets and long-tail content Enforces application logic on the network edge Actively filters requests and restricts external access to origin servers Multi-layer setup to eliminate latency penalties Multi-region availability Compressed JSON response payloads Auto-scaling of computing resources during traffic spikes Sync API limits data transfer to updated entries/assets Automatic image optimization for individual platforms

Slide 29

Slide 29 text

Delivery architecture and APIs

Slide 30

Slide 30 text

Contentful’s “API-first” approach 1. Fast 2. Flexible 3. Modern Architecture 2. Build any user experience for any device (anywhere) ‐ A large collection of SDKs ‐ Flexible content models ‐ Designed for easy localization 3. Take advantage of the “modern stack” architecture - Combine industry-leading, single purpose apps (microservices) - Built-in integrations with popular platforms - Connect platforms easily using webhooks and UI extensions 1. Fast implementation, fast performance - Cloud-native SaaS with CDN - Use the development tools you know - Fast, scalable content migration and transformation using code

Slide 31

Slide 31 text

Content delivery architectures 1 2 3 Dynamic on Server Static Site Generator Dynamic on Device A client-side app using the Contentful SDKs requests content from the Contentful APIs and renders the content on the device. A server-side app receives a request from an end user, retrieves content from Contentful (and possibly other data sources), renders the content, and sends it back in response. A static site generator fetches content from Contentful at timed intervals or on content change webhook then builds the rendered HTML pages and stores them on a static web host.

Slide 32

Slide 32 text

Dynamic on server Server-Side Application, iPaaS (Integration Platform as a Service)

Slide 33

Slide 33 text

Dynamic on server Contentful CDN Your CDN Your Server App

Slide 34

Slide 34 text

Pros • Lots of languages & framework options • Reactive – no stale data • Easier SEO • Secure secrets (API tokens not exposed to end-users) Cons • Server-related scalability ($$$) • Higher page latency • Requires external caching or CDN • Potential single point of failure Dynamic on server

Slide 35

Slide 35 text

Dynamic on device Single Page Application, Native App, Mobile (iOS/Android) App

Slide 36

Slide 36 text

Static Host / App Store Dynamic on device

Slide 37

Slide 37 text

Pros • Simple • Reactive – no stale data • Fully leverages the Contentful CDN Cons • SEO support requires more effort • Possible browser compatibility issues Dynamic on device

Slide 38

Slide 38 text

Static site generator Jekyll, Next, Hugo, Gatsby, Metalsmith, Middleman, Wyam, etc.

Slide 39

Slide 39 text

1. Code or content changes trigger webhook to generate static site -OR- Generation triggered on set interval (hourly, daily, etc.) BUILD TIME REQUEST TIME Static site generator

Slide 40

Slide 40 text

Contentful & Gatsby demo

Slide 41

Slide 41 text

Pros • Easier SEO • Offline capability • Static HTML is fast and simple to serve • Secure secrets (API tokens not exposed to end-users) Cons • No immediate preview/potential for stale data • Web page-centric • Generation time can be problematic for frequent content changes • Requires external hosting, caching, and CDN Static site generator

Slide 42

Slide 42 text

Delivery models: pros & cons Dynamic on Server Static Site Generator Dynamic on Device Dynamic content • • • Page latency • • • App server load • • • SEO • • • Secure Secrets • • • Contentful CDN • • • Availability • • •

Slide 43

Slide 43 text

Dynamic hybrid with Node.js 1 2 Dynamic on Server Dynamic on Device JavaScript framework takes over user interaction and hydrates page Page initially built server-side on Node.js with JavaScript framework that supports isomorphic execution (e.g. React)

Slide 44

Slide 44 text

Core APIs

Slide 45

Slide 45 text

Content Management API Read/Write Create, edit, publish, unpublish, archive, and delete content and content model Content Preview API Read-only Retrieve draft and updated content in addition to published content Content Delivery API Read-only Retrieve published content to display in an app or website Images API Read-only Retrieve and apply transformations to images stored in Contentful Contentful core REST APIs

Slide 46

Slide 46 text

REST API demo

Slide 47

Slide 47 text

Contentful is a content platform Content Creator Content Delivery API CLI Web App Content Management API SDK SDK SDK Apps & Websites Conversational & Wearables Apps & AR/VR Powerful CLI and tooling to integrate into existing developer workflows or to help define brand new workflows The APIs, webhooks and SDK’s developers need to power content in any digital product Content Preview API Customizable web app for marketers and publishers to collaborate and create content Developer Images API

Slide 48

Slide 48 text

SDKs

Slide 49

Slide 49 text

SDKs Supported platforms

Slide 50

Slide 50 text

GraphQL Content API

Slide 51

Slide 51 text

GraphQL It is an open-source data query and manipulation language for APIs, and a runtime for fulfilling queries with existing data It allows clients to define the structure of the data required, and exactly the same structure of the data is returned from the server, therefore preventing excessively large amounts of data from being returned GraphQL schemas are strongly typed - reliably know what type of data is where

Slide 52

Slide 52 text

GraphQL Content API It provides a GraphQL interface to the content from Contentful. Each space has a GraphQL schema based on its content model. The schema is generated at request time so it is always current. You can use this API to consume both published and unpublished content. There is query complexity limit currently set to allow retrieval of 11,000 entities in one request. This API supports schema stitching which allows two or more GraphQL APIs to be combined into a single schema that can be presented to a client application.

Slide 53

Slide 53 text

Small GraphQL vs. Big REST Rest API call: curl -X GET --header "Accept: application/json" --header "Authorization: Bearer ..." "https://api.deutschebahn.com/fasta/v2/stations/1866" GraphQL API call: curl -X POST --header "Content-Type: application/json" --header "Authorization: Bearer ..." -d '{"query": "{stationWithStationNumber(stationNumber: 1866){facilities{type description} }}"}' https://bahnql.herokuapp.com/graphql query{ stationWithStationNumber(stationNumber: 1866){ facilities{ type description } } }

Slide 54

Slide 54 text

Small GraphQL vs. Big REST Rest API Response: { "stationnumber": 1866, "name": "Frankfurt (Main) Hbf", "facilities": [ { "equipmentnumber": 10313104, "type": "ESCALATOR", "description": "zu Gleis 103/104 (S-Bahn)", "geocoordX": 8.66231455, "geocoordY": 50.10727055, "state": "INACTIVE", "stateExplanation": "under construction", "stationnumber": 1866 }, { "equipmentnumber": 10313109, "type": "ESCALATOR", "description": "zu Gleis 101/102 (S-Bahn)", "geocoordX": 8.66341625, "geocoordY": 50.1074703, "state": "INACTIVE", "stateExplanation": "under construction", "stationnumber": 1866 }, GraphQL API Response: { "data": { "stationWithEvaId": { "facilities": [ { "type": "ESCALATOR", "description": "zu Gleis 103/104 (S-Bahn)" }, { "type": "ESCALATOR", "description": "zu Gleis 101/102 (S-Bahn)" },

Slide 55

Slide 55 text

Content modeling

Slide 56

Slide 56 text

Content modeling basics

Slide 57

Slide 57 text

What is a content model?

Slide 58

Slide 58 text

Real world content models can be complex

Slide 59

Slide 59 text

How do you build a content model?

Slide 60

Slide 60 text

Early stakeholder involvement is key Create a Pool of Sample Designs • Conduct an audit of existing content • Create prototypes of future content • Assemble screen shots into a slide deck Create a draft model based on visible fields • Create a list of visible fields from instances of each content type • Reconcile similar fields to create a master list • Group fields into content types of appropriate size & define relationships Revise model for functionality & best practices • Add invisible “meta” fields (for queries, workflow, webhooks, etc.) • Optimize for content creators • Optimize for developers • Implement naming conventions QA: Validate with actual content • Try to “break” the content model by using it to build diverse instances or real world content Test with Content Creators • Watch authors use the content model (usability test) • Create documentation, help and job aids Test with Developers • Have developers QA the model against front-end, migration scripts, etc. Test with Designers • Have designers test the content model by creating a variety of designs Assemble key stakeholders to define strategy • Clarify business objectives • Agree on required functionality • Make strategic content architecture decisions STEP 1 STEP 2 STEP 3 STEP 4 STEP 5 STEP 6 STEP 7 STEP 8

Slide 61

Slide 61 text

Who is your customer as a content modeler? Customers Content Authors Developers

Slide 62

Slide 62 text

Getting the right balance between developers and content authors is the key to successful content models.

Slide 63

Slide 63 text

What should you store in Contentful? Content • Text • Images • Audio/Video • Geo location Micro-Copy • Field labels • Button text • Navigation Localized Content • Localization strategies • Translation permissions/workflows Content Metadata • SEO & Social Media • Images as content types • Tags for navigating the content model Process Metadata • Site functionality (sort, search, etc.) • Editorial workflow • Webhooks Content Components (“Assemblies”) • Atomic design – chunks not blobs • Giving content creators control over layout • Visual design systems

Slide 64

Slide 64 text

What should you not store in Contentful? CSS HTML

Slide 65

Slide 65 text

Structured content enables content reuse Content Types

Slide 66

Slide 66 text

“Topics” and “assemblies”

Slide 67

Slide 67 text

Topics are reusable content components ✔ Individually authorable ✔ Pure content ✔ No presentation options ✔ Building block for assemblies

Slide 68

Slide 68 text

Assemblies are reusable visual components ✔ Not individually authorable ✔ Contains topics ✔ Includes presentation options ✔ Assemblies can contain assemblies

Slide 69

Slide 69 text

Assemblies Example: Shutterstock Homepage Similarly composed of reusable assemblies

Slide 70

Slide 70 text

One-to-many relationship

Slide 71

Slide 71 text

One-to-one relationship

Slide 72

Slide 72 text

Fixed Flexible

Slide 73

Slide 73 text

Flexible vs. fixed assemblies demo

Slide 74

Slide 74 text

Assemblies are everywhere Entry Level Localization

Slide 75

Slide 75 text

Rich text

Slide 76

Slide 76 text

Rich text provides a lot of flexibility

Slide 77

Slide 77 text

Rich text vs. markdown vs. WYSIWYG

Slide 78

Slide 78 text

Demo video of rich text in action

Slide 79

Slide 79 text

Inheritance vs. composition in content models

Slide 80

Slide 80 text

Content types can use inheritance Product Name Manufacturer Color Product Type (reference) Shoe Size Sole type Heel type Pants Waist Length Type (formal, casual) Shirt Sleeve length Collar Fabric weight You can add or change fields that apply to every product without duplicating the change for every product type

Slide 81

Slide 81 text

Content types can use composition Press Release Title Body SEO Content Contact Info Location Info SEO Content Page title Meta description OG tags Location Info Name Geo coordinates Contact Info Name Title Email address Adapted from Deane Barker’s “Real World Content Modeling”

Slide 82

Slide 82 text

Content modeling for localization

Slide 83

Slide 83 text

Field level localization vs. entry level localization Title Text (FR) Field Level Localization Entry Level Localization using Localization Objects Title Slug Text (EN) Text (FR) ... Title Slug Ref 1 Ref 2 ... Title Text (EN)

Slide 84

Slide 84 text

The field Localized is an array that contains an entry for each locale Entry level localization - two content types 1 2

Slide 85

Slide 85 text

Entry level localization

Slide 86

Slide 86 text

Entry-level localization support asynchronous publishing

Slide 87

Slide 87 text

Content aggregation

Slide 88

Slide 88 text

Viewing content puts user into segment by category Works for anonymous as well as known users Personalization Related Content Easy to create a “You also may like…” links Navigation Menus can point to content of various categories Analytics Analytics tools can show site viewing behavior by categories Why categorize your content?

Slide 89

Slide 89 text

Categorization organizes your content into groups

Slide 90

Slide 90 text

Categories are pre-defined by a site admin Entry Level Localization

Slide 91

Slide 91 text

Any content types can link to multiple categories Entry Level Localization

Slide 92

Slide 92 text

Categories demo Entry Level Localization

Slide 93

Slide 93 text

Contentful customers using Design Systems

Slide 94

Slide 94 text

Content Optimization Experimentation and personalization

Slide 95

Slide 95 text

No content

Slide 96

Slide 96 text

Integrating the Contentful way Enable integrations where the journey of the practitioner overlaps Monolithic, inflexible, opinionated Lean integrations of industry-leading services, modular, custom tailored Deployment Translation SEO Search Productivity Marketing Editorial Ecommerce Deployment Translation SEO Search Productivity Marketing Editorial Ecommerce ✔

Slide 97

Slide 97 text

Taking the Contentful Optimizely app as an example Multi-platform Take your content and experiments to any platform Structured content Control in a structured and API-first environment Integrated No need to ship new code to run an experiment High performance Render times under < 200ms

Slide 98

Slide 98 text

Optimizely app demo

Slide 99

Slide 99 text

What if your CMS supported Optimizely out-of-the box?

Slide 100

Slide 100 text

Considering this structure Hero Featured CTA Page Title: “Homepage” Slug: “home” Component: []

Slide 101

Slide 101 text

Hero Featured CTA Page Title: “Homepage” Slug: “home” Component: [] Enabling experimentation using the App CTA (control) CTA (variation) Variation container

Slide 102

Slide 102 text

import contentfulSdk from 'contentful'; const optimizelyClient = new Optimizely({ dataFile }); const user = getUser(); const variationEntry = await contentfulSdk.getEntry(entryId); const variation = optimizelyClient.activate( variationEntry.experimentKey, user.userId ); const variationEntryId = variationEntry.meta[variation]; const variationContent = await contentfulSdk.getEntry(variationEntryId); Experimentation layer Contentful SDK Optimizely SDK Experimentation layer Contentful SDK Optimizely SDK

Slide 103

Slide 103 text

Contentful Content variations Map content to experiments Optimizely Experiments Audiences / targeting Analytics Customer’s Code API stitching Tracking Separation of concerns Who does what?

Slide 104

Slide 104 text

Use cases Real world examples

Slide 105

Slide 105 text

Test copy & CTA

Slide 106

Slide 106 text

Test sections

Slide 107

Slide 107 text

Even pages & layouts

Slide 108

Slide 108 text

Across desktop & mobile

Slide 109

Slide 109 text

Personalization example: Contentful + Adobe + AWS Lambda Activity Container Experience Offer Visitor

Slide 110

Slide 110 text

Results RESULTS: 9.2% Increase in prospect cart start rate 18.5% Decrease in bounce rate New phone research experience for customers & prospects

Slide 111

Slide 111 text

Contentful web app

Slide 112

Slide 112 text

So, what’s in it for content authors? Reusable content change content in one place and it changes everywhere Customizable workflow build the approval process you need Independence add or change content instantly without the assistance of technical teams Version control see earlier versions of content and roll back instantly Flexible localization easily manage country-specific or audience-specific text and images

Slide 113

Slide 113 text

Extensibility

Slide 114

Slide 114 text

Contentful’s extensibility Check out our marketplace The App Framework Webhooks

Slide 115

Slide 115 text

Public Apps Turn-key apps featured on our marketplace, accessible via contentful.com & in the web app ● Launch apps ● Illustrate common use cases ● Source code available on Github Private Apps Roll out your own custom integrations to connect off-the-shelf or proprietary software ● Orgs & agencies can create app catalog ● Customize integrations to your needs & use cases Production-ready framework Customize and integrate with a seamless UX in less time with our design system, SDKs & developer tools ● Consistent UX ● Faster development ● Open source Forma 36 What is the App framework?

Slide 116

Slide 116 text

It’s a superset of UI extensions that bundles UI extensions and webhooks into a package It empowers users to integrate third-party services, build extraordinary workflows and customize the functionality of the Contentful web app Every app has access to the SDK, which makes it possible to read and write most of the data in a Contentful space. What is an App?

Slide 117

Slide 117 text

Experimentation Apps that allow editors to access, select or edit media Examples: Cloudinary, Bynder, Dropbox, Image Focal Point, Frontify Apps that allow marketers to run A/B experiments and obtain better insights Example: Optimizely Digital Asset Management Translation Apps that enable you to automate, manage, and professionally translate content Example: Smartling, Transperfect, Lingotek Apps use cases

Slide 118

Slide 118 text

Assemble DXPs with content at the core Content Platform Commerce Marketing Translation Collaboration Analytics Optimization & Personalization Developer & Editor Productivity Digital Asset Management Deployment & Delivery Artificial Intelligence Public apps

Slide 119

Slide 119 text

Our global solutions partners help customers build compelling digital experiences Leverage the App Framework: ● Technology solution consulting on assembling DXS ● Strategic vision on integrated stack ● Change management from traditional way of working to headless, micros-services ● Setup, implementation and frontend services

Slide 120

Slide 120 text

“Global brands such as Bang & Olufsen need to maintain a luxury digital experience across numerous channels, which is only possible with a content platform that’s extensible and modular. We recommend Contentful to our clients because it easily integrates with commerce solutions, digital displays or any future customer touchpoint.”

Slide 121

Slide 121 text

Custom sidebar

Slide 122

Slide 122 text

Custom field

Slide 123

Slide 123 text

Spotify editors can search for artists or songs and embed them into new content instantly (no fussing with multiple browser tabs, copy and paste, or human errors). Custom UI for Spotify Artists content creators

Slide 124

Slide 124 text

Apps in action at Telus

Slide 125

Slide 125 text

Viewing real-time analytics data in Contentful

Slide 126

Slide 126 text

Cloudinary app demo

Slide 127

Slide 127 text

Webhooks

Slide 128

Slide 128 text

What is a webhook? HTTP POST request whenever something happens to your content 18 Pre-built webhooks Customizable JSON payloads Triggers can be filtered by action, content type, environment

Slide 129

Slide 129 text

Webhooks are easy to configure

Slide 130

Slide 130 text

Webhook payloads are easily customizable

Slide 131

Slide 131 text

Webhook demo part I

Slide 132

Slide 132 text

Webhook demo part II

Slide 133

Slide 133 text

Managing content at scale

Slide 134

Slide 134 text

Content at scale Independent editorial and development workflows Using environments for agile development Refactoring content models

Slide 135

Slide 135 text

Independent editorial and development workflows Content Creator Content Delivery API CLI Web App Content Management API SDK SDK SDK Apps & Websites Conversational & Wearables Apps & AR/VR Powerful CLI and tooling to integrate into existing developer workflows or to help define brand new workflows The APIs, webhooks and SDK’s developers need to power content in any digital product. Content Preview API Customizable web app for marketers and publishers to collaborate and create content. Developer Images API

Slide 136

Slide 136 text

CLI tools

Slide 137

Slide 137 text

CLI tools support DevOps automation Contentful's command line interface tools let you use Contentful features straight from your CLI, providing the basis for DevOps automation. ● login- Start new CLI session ● logout - End CLI session ● boilerplate - Kickstart an example project with one of our 9 SDK's ● guide - Getting started with Contentful ● config - Config related commands ● space - Space related commands ● organization - Organization related commands ● content-type - Content Type related commands ● extension - UI Extension related commands

Slide 138

Slide 138 text

Space modeling

Slide 139

Slide 139 text

Contentful domain model Organizations Top most parent object, connects users to a company. Users A User can have access to all or limited access to certain spaces based on roles & permissions. Spaces A child entity of an organization. A container for content, assets and UI extensions. Environments Are entities belonging to a space, they contain an isolated copy of content and assets.

Slide 140

Slide 140 text

Tips for getting the most out of spaces Use spaces to separate content that has different teams or different use cases unless they need to share content For large scale implementations, consider putting global shared content, team shared content and project-specific content in separate spaces Roles are specific to a space—use separate spaces if the same users need different permissions

Slide 141

Slide 141 text

One space to rule them all Space 1 Used for microservice 1 all projects at org Project Spaces Content consists of Assemblies, Topics, and Media Best pattern for use cases where all of the following are true: ✔ Content types and/or content entries are reusable across projects. ✔ Projects all have the same localization needs. ✔ Roles & Permissions provide sufficient access controls across all projects. ✔ Content is intended to be used for multi-channel delivery. ✔ Multiple teams or business units want to collaborate together across projects.

Slide 142

Slide 142 text

Separate space per project Space 1 Used for microservice 1 specific content Space 2 Used for microservice 2 specific content Space N Used for microservice N specific content ... Project Spaces Content consists of Assemblies, Topics, and Media Best pattern for use cases where one or more of the following is true: ✔ Content types are not reusable across projects. ✔ Projects have different localization needs. ✔ Roles & permissions cannot be effectively used to create granular access controls. ✔ Business units have a regulatory or legal requirement to keep their project and content separate.

Slide 143

Slide 143 text

Multi-tier space pattern Space 1 Used for microservice 1 specific content Space 2 Used for microservice 2 specific content Space N Used for microservice N specific content ... Shared Space Used for highly reusable content across org Global Shared Spaces Project Spaces Shared Space 1 Used for reusable content for line of business 1 BU/Team Shared Spaces Shared Space K Used for reusable content for line of business K ... Content consists of Assemblies, Topics, and Media Requires UI Extension for cross space referencing

Slide 144

Slide 144 text

Determining best space pattern Will governance rules (i.e. user roles and access permissions) be the same or different among the teams and projects? Will content types be the same and/or shared across projects? Will projects have the same localization requirements? Same or different set of locales? Is there a legal or regulatory requirement for projects and their content to be isolated?

Slide 145

Slide 145 text

Use microservice spaces strategy instead of monolithic ones Microservice Spaces could be defined based on: ◦ Business Units ◦ Business Functions ◦ Projects ◦ Content/Dev Teams Goals: ◦ Reduce dependencies and time-to-market ◦ Improve release/publish lifecycle Space planning strategy

Slide 146

Slide 146 text

Using environments for agile development

Slide 147

Slide 147 text

Environment Aliases Environment aliases Convert master environment into an environment alias A promotion or rollback is achieved by retargeting the alias to another environment – which happens instantly Production content is served from unscoped/master API routes through the master alias Currently only master can be an environment alias

Slide 148

Slide 148 text

Enabling risk free releases and instant rollbacks master is no longer a stand-alone environment but acts as an alias targeting another environment Production content is served from release-1 environment Execute migration scripts Production content is now served from release-2 environment Release 2 release-1 release-2 Environment aliases Change master alias to target release-2 environment master Release 3 release-3 Optional: Delete release-1 environment Production content is now served from release-3 environment Change master alias to target release-3 environment

Slide 149

Slide 149 text

Use cases for aliases

Slide 150

Slide 150 text

Minimize downtime and allow instant rollback master is no longer a stand-alone environment but acts as an alias targeting another environment Production content is served from release-1 environment Execute migration scripts Change master alias to target release-2 environment Production content is now served from release-2 environment Promote Problem discovered! Rollback is required Rollback Rollback master to target release-1 environment release-1 release-2 Use case: promote an environment to master master

Slide 151

Slide 151 text

master is no longer a stand-alone environment but acts as an alias targeting another environment Content is served from prod environment Run migration scripts Restore by changing master alias to target prod-backup environment Backup Problem discovered! Rollback is required Restore prod prod-backup master Optional: Delete prod environment prod Optional: Recreate prod from prod-backup Change master alias to target prod environment Better safe than sorry Use case: Backup and restore

Slide 152

Slide 152 text

Managing content with code

Slide 153

Slide 153 text

Using migration scripts 5 steps to use migration scripts to accomplish managing content with code 1 Create the environments you need for CI/CD 2 Experiment with a content model in the web app where you can see JSON output 3 Create a script to programmatically build the full content model 4 Create migration scripts to evolve your content model and content 5 After testing, propagate your changes into the production environment by switching the master environment alias

Slide 154

Slide 154 text

Set up your initial environments 1

Slide 155

Slide 155 text

Explore what content types, fields, validations etc. look like as JSON. Use the JSON preview model to help write your initial script to programmatically build your content model. Browse content types in the web app 2

Slide 156

Slide 156 text

Create a script to build the content model Invoke with Contentful CLI against your development environment: contentful space migration --space-id zvrkepvkvv5z --environment-id 'r3-fall-promo' 01-add-author-content-type.js 3

Slide 157

Slide 157 text

Create a migration script to update model Programmatically update an existing content model. Execute the new script on your development environment: contentful space migration --space-id zvrkepvkvv5z --environment-id 'r3-fall-promo' 02-author-link.js Note when you execute a content migration, both the content type and all content entries (records) based on that content type are updated! 4

Slide 158

Slide 158 text

Propagate your changes to production After you have thoroughly tested and verified your changes in your development environment, you can now “push” your changes to production by switching your master environment to point to your development environment. Should you discover a problem you can always roll back master to your previous environment (r2 in this example). 5

Slide 159

Slide 159 text

Refactoring using the expand / contract pattern

Slide 160

Slide 160 text

Migrations: “expand” phase Content entries such that the changes do not prevent the currently released version of the software from running New fields and content types By leaving the existing content in place, while augmenting the content types and content such the new version of the software can also run. The content model can now support both the current version and the new version of your software in parallel. Add Transform

Slide 161

Slide 161 text

Once all users are successfully using your new version, the “contract” phase of the migration is to run to remove unneeded content types, fields and content. Remove Migrations: “contract” phase

Slide 162

Slide 162 text

Demo using the content migration API

Slide 163

Slide 163 text

So what’s next? Keep learning Contentful Learning Center (a growing catalog of online courses) Developer Certification Program Documentation Developer Portal Join our Meetups & Webinars (Gatsby,..) Keep track of new things Changelog What’s New

Slide 164

Slide 164 text

The leading content infrastructure for digital teams Customers Partners Investors ($78M) >240 employees in Berlin and San Francisco Team +1,000 other customers Technology Partners

Slide 165

Slide 165 text

Thank you. Any questions?