EuroClojre – Day 2
Wow! I thought Day 1 was Great – Day 2 just as good, including some great but “enterprise geeky” topics like Enterprise Integration in Clojure and A Perfect Storm for Legacy Migration ;-) Plus, we had Stuart Halloway’s…
Keynote – Narcissistic Design
- Stuart Halloway
- Examples
- Build Tools
- ORM
- Advanced
- Integrating narcissism and agile practice
- Technologies to avoid
- Functional languages & databases
- Never eliminate complexity, automate around it
- Manage by pull request, because code is the first and best unit of discussion
- Top 10
- Use OO, and don’t forget those setter methods!
- Prefer APIs over data
- Start with DSLs
– Nothing says “screw you” like a DSL
– JVM - Always connect (and never enqueue)
- Create abstractions for information
– Encapsulate! - Use static typing across subsystem boundaries
– Exceptions - Put language semantics on the wire
– Focus on programming rather than data languages - Write lots of unit tests
– Example Based Testing
– TDD
– Always be coding
– Never get on the hammock - Update information in place
– The one thing about OO: gives you all the complexity but no history - Leverage context
Using Clojure to Serve The Internet of Things
- Kontiki
- Lightweight OS
- Nest
- How do I get iot on my CV?
- Dev kits
- mBed
- Electric imp
- RasberryPi
- Arduino
- Beagle bone
- Open data sets
- Web / Mob apps
- Dev kits
- Xively
- LogMeIn
- Went from Ruby
- To Clojure
- Order of magnitude improvement!
- To Clojure
- Architecture of “thermometer”
- Twitter
- Clojure hero ku
- Clojure Xivi
- ?
- Clojure Xivi
- Clojure hero ku
- Twitter
- IoT
- 1.1b PCs
- 2mm2 32-bit computer with wiFi for $1
- 32kB RAM
- 128kB Flash
- Radio
- Weightless – OS?
- Batt
- 50 bytes/h for 10y on 2 AA Batt!
- Batt
- 5.8b mob
- 1T Things
- Main challenges
- Discovery
- Directories
- Provisioning
- Security
- Should take off due to economies of scale
- Massive Data Volumes
- Motor
- 1Gb data / h
- Motor
Newspaper Massacre!
- Conways Law
- Daily Mail
- Mail Online
- Largest online newspaper
- Serve 154Bn images!
- Cached by Akamai
- Serve 1000 articles/s
- Very long home page
- Largest online newspaper
- Mail Online
- Mobile
- Gamechanger
- Personalisation
- Trying to scale
- Personalisation
- Gamechanger
- Published messages from Legacy to Topic
- Challenge
- Render the homepage
- No caching
- Response <300ms
- Render the homepage
- Mustache
- Templates Library
- Themes
- e.g. Mobile
- Libs / Projects
- Memcached
- Mule
- Reddis
- Riemann
- Graphite
- Logstash
- GitHub.com/mailonline
- Ppl
- @clifcunn
- @jonpither
- Pitheringabout
- Config
- Avout
- Wrapper around Zookeeper
- Avout
- Services
- Built a library around software infrastructure
- Future
- Rewrite everything
- ~13kLOC
- Rewrite everything
- Devs sit next to newsroom
- E2E Ownership
- Responsibility
- Terrible Legacy
- Using Spring
(into reduce transient)
- Clojure.core/ancestors
- (Ancestors (class []))
- Libraries
- avl.clj
- core.rrb-vector
- Guy Steel Talk
- About sequential reduction
Lightning talks: Literate Programming, Bare Metal Lisp & Templating
In search of workflow nirvana: Clojure, Emacs, Org
- Rich Hickey
- Ant Simulation
- Org – mode in EMACS
- Literate Programming
- “is what you need to rise above the ordinary level of achievement”
- Pedestal
- Working on functional CMS system
- hackerretreat.com
Lithium: a small Clojure-inspired Lisp on the bare metal
- Compiles to x86
- No runtime dependencies
- Fluchtpunkt Lisp
- Paper: An incremental approach to compiler construction
- Movitz
- Similar for Common Lisp
- Synthesis: an efficient implementation of fundamental operating system services
Templating In Clojure
- Hiccup
- HTML as a data structure
- No real separation
- Good if full stack devs
- clj-jade
- Successor to HAML
- Use Jade for J
- Or moustache
- Enlive
- Transformations of HTML
- Good for front-end
- CSS Selector based
- Can break transformations
- Lacks HTML abstraction
- + Hamilito
Enterprise Integration in Clojure
- clumsyjedi @ GitHub
- Enterprise Integration Patterns
- Looked At
- Mule
- Not used – too many problems
- Camel
- HolyGrail
- Use
- core.async
- + Threaded Macros
- Lamina
- Event Stream Processing Library
- Superset of EIP
- Rysome
- Event Stream Processing Library
- Storm
- Java / Clojure Hybrid
- Chosen
- Java / Clojure Hybrid
- ClamQ
- Clojure i/f for ActiveMQ
- EEP
- Good visualisation
- Mule
- Areas of Interest
- Systems Integration
- Business Rules Capture
- Distributed Systems Orchestration
- Using Vim
- Beyond Patterns
A Perfect Storm for Legacy Migration
- Twitter Storm
- Clojure
- Distributed runtime
- For “eXtreme Processing”
- Apache Thrift
- Nimbus
- ?
- Gives
- Stream Processing
- Realtime Analytics
- Continuous Computation
- Distributed RPC
- Concepts
- Bolt
- Spout
- Topology
- Grouping “field”