() Parentheses Kevin Corcoran @KevinOfCorc Im from Portland, - - PowerPoint PPT Presentation

parentheses kevin corcoran kevinofcorc i m from portland
SMART_READER_LITE
LIVE PREVIEW

() Parentheses Kevin Corcoran @KevinOfCorc Im from Portland, - - PowerPoint PPT Presentation

Puppet Plus () Parentheses Kevin Corcoran @KevinOfCorc Im from Portland, Oregon, U.S.A. I work at Puppet Labs. WHATS THIS PUPPET THING? DevOps, Infrastructure As Code, <Insert Buzzword/Catchphrase here> open-source tool for


slide-1
SLIDE 1

Puppet Plus Parentheses

()

slide-2
SLIDE 2

Kevin Corcoran

@KevinOfCorc

I’m from Portland, Oregon, U.S.A. I work at Puppet Labs.

slide-3
SLIDE 3

DevOps, Infrastructure As Code, <Insert Buzzword/Catchphrase here>

  • pen-source tool for sysadmins

Puppet DSL

a language for describing system state

WHAT’S THIS PUPPET THING?

slide-4
SLIDE 4

BABY’S FIRST MANIFEST

slide-5
SLIDE 5
slide-6
SLIDE 6

PUPPET ▪ puppet agent on each machine ▪ puppet master contains manifests ▪ agents “check-in” (agent run) periodically

slide-7
SLIDE 7
  • 1. system info (facts)
  • 2. your state

should be X (catalog)

  • 3. okay, let’s

change things!

AGENT MASTER OTHER AGENTS

.pp MANIFESTS

slide-8
SLIDE 8

▪ Ruby ▪ monolithic codebase

▫ agent + master ▫ shared code

▪ Rack ▪ Apache + Passenger

PUPPET IMPLEMENTATION

slide-9
SLIDE 9

IMPLEMENTATION ISSUES

▪ difficult to change ▪ client/server/both? ▪ MRI + GIL ▪ Passenger

▫ concurrency via multiple processes ▫ no shared state / coordination

slide-10
SLIDE 10

LET’S BUILD A BETTER TECHNOLOGY STACK

▪ complete re-write?

▫ too difficult ▫ some functionality needed on both client + server ▫ moving target

▪ less drastic

▫ no more MRI on the server-side ▫ … but still Ruby ▫ battle-tested server platform ▫ avoid re-inventing the wheel

slide-11
SLIDE 11
slide-12
SLIDE 12

JAVA VIRTUAL MACHINE

▪ stable ▪ fast ▪ free ▪ portable ▪ mature ▪ concurrent ▪ libraries for everything

slide-13
SLIDE 13
slide-14
SLIDE 14

But, we don’t want to write Java code, so ...

slide-15
SLIDE 15

Clojure

Finally, Lisp!

slide-16
SLIDE 16

▪ runs on the JVM ▪ tolerates OOP

▫ seamless Java inter-op

▪ pure functions, immutable values ▪ excellent built-ins for concurrency + state management ▪ PuppetDB

CLOJURE

slide-17
SLIDE 17

CLOJURE @ PUPPET LABS, CIRCA 2013

▪ PuppetDB ▪ Puppet master -> Clojure ▪ moar! ▪ common needs:

▫ web server ▫ configurability ▫ logging ▫ lifecycle ▫ deployment, packaging

slide-18
SLIDE 18

▪ Clojure

▫ Component ▫ others

▪ Java

▫ OSGi ■ Classloader issues? ▫ JBoss ■ heavyweight

APPLICATION FRAMEWORK OPTIONS

slide-19
SLIDE 19

Of course we did!

So we wrote

  • ur own.
slide-20
SLIDE 20

TRAPPERKEEPER

▪ open-source Clojure application framework ▪ code modularity, re-use ▪ s/Component/Service ▪ Service:

▫ protocol (set of functions signatures) ▫ lifecycle ▫ state ▫ dependencies on other services

slide-21
SLIDE 21
slide-22
SLIDE 22

A VERY QUICK BRAG

slide-23
SLIDE 23

(let [puppet-server ...

slide-24
SLIDE 24
slide-25
SLIDE 25
slide-26
SLIDE 26

CLOJURE

▪ glue ▪ Certificate Authority ▪ initialization ▪ HTTP ▪ future: incremental re- write ▪ new features

slide-27
SLIDE 27

OUR EXPERIENCE WITH CLOJURE

▪ good

▫ simplicity, immutability ▫ developers love it ▫ REPL-driven development, “reloaded” workflow ▫ easy to hire for ▫ surprisingly easy to learn ▫ active community

▪ less than good

▫ slow startup time ▫ long stacktraces ▫ not as easy as Ruby

slide-28
SLIDE 28

TRAPPERKEEPER

We got the Big Idea right. We’ve gotten lots of mileage standardized solutions for a handful of incidental concerns. Let us know how you’re using it!

slide-29
SLIDE 29

Jetty

▪ embedded! ▪ fast, reliable ▪ lots of knobs ▪ right choice ▪ pure-Clojure web server would be nice

slide-30
SLIDE 30

Puppet <3 JRuby

▪ biggest risk ▪ huge success! ▪ the JRuby devs have been awesome

slide-31
SLIDE 31
slide-32
SLIDE 32

Kevin Corcoran @KevinOfCorc ON GITHUB

  • puppetlabs/puppet-server
  • puppetlabs/trapperkeeeper

CREDITS ▪ Busy Icons by Olly Holovchenko ▪ Portland photo by Amateria1121 via Wikipedia

questions?