Category: EuroClojure
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”
EuroClojure – Day 1
I’ll be putting some notes / mind maps up here from EuroClojure over the next two days. In the “agile spirit” I’m including my notes fairly raw below and may refine them later… For the meantime, in case you weren’t able to attend EuroClojure, here is a summary of some of the fun you’ve missed ;-)
Keynote
Critical Theory
- Nomad
- Rhizome
- “Interconnectedness of Things”
- State
- Information
- Collapse of Abstracton to Reality
- Brazilia
- Collapse of Abstracton to Reality
Software
- Production methods
- Prussian “Scientific Forestry”
- Create Flawless Abstractions
- vs Organic Forests
- Prussian “Scientific Forestry”
- ~ Forest
Greeks
- Techne
- Timeless
- Metis
- Cunning
- Local
- Contextual
- Nomadic
- Cunning
Refs
- Patterns of Software
- Fictions and the aleph
- Data and reality
- Seeing like a state
- Simila and simulation
- Invisible cities
Alexander
- The Quality without a name
- Contextual
- Richard Gabriel
- Pattern Language
- To express patterns that were observed (locally)
Gerald Weinberg
- An Introduction to Systems Thinking
- Heuristic Devices don’t tell you when to stop
Make your own Lisp
BODOL
- Homoiconic
- Immutable
- Typed
- Robin Milner
- Example
- Pure
- Makes HN Caremad
- Pattern Matchinng
- Used core.logic
Instaparse
- Mark Engelberg
- EBNF
- Or Parse Combinators
Refs
- GitHub.com/bodil/BODOL
- GitHub.com/bodil/building-lisp
Misc
- Core Match
- Not used as specific to Clojure…?
- Lispkell
- Also Lisp + Haskell
Life in a Browser
Genetic Algorithms
- Breed s-expressions
Zipper
- Tree handling Library
Resources
- Complexity – a guided tour
- Complexity explorer
- Stephen wolfram
- A new kind of science
Biologically inspired computing – Artificial Life Project
- In browser with core.async
- Enlil
- Head Mesopotamian god
Liberator
Free your data with RFC2616
- Http 1.0
- + Patch
- Liberator doesn’t handle
- + WebDav
- Almost 40 decision points for all status codes
- + Patch
Only 1 use in prod – Clojure library
- Implement REST Resources
- On the server side
~ 1/3 LOC Takes care of most of the status code processing
- Uses “standard” from http flow diagram
- See web site
Automatically converts your data to JSON or EDN
Creative Machines
Book: Creative Music
- Death = Entropy Chaos*
- Recombinance
- Creativity does not occur in a vacuum
Influence
- Serendipity
Learning + Inference + Knowledge
- Canon Builder
- Association Network
- Like Neural
New neural networks
Cognitive Bias
Examples
- Death Dance
- Aaron
- Painter
- Howard Kern / Cohen
- Music (overtone)
- Markov Chains
- Neural Nets
David Cope
- Emily Howell
- Music
Creativity
- Can happen by
- Combination
- Exploration
- Transformation
- Reflect on System Rules
- And Change those Rules
- Psychological
- Historical
Functional
Common Clojure Smells
Martin Fowler & Kent Beck
- Refactoring
Long parameter lists
- Underlying issues
Clojure specific smells
- Locally scoped atoms
- Magic Keys
- aka Data structure coupling
- Hard to figure out the cost of change of key names, data types etc…
- Keep data aware fns together (defrecord?)
- Indirection by partiality
- Macromania
- Parents Proliferation
- aka Over-nesting
- Trying to do everything in one expression
- Balance between tenseness & readability
- Lazi-itis
- Excessive use of lazy evaluation
- Many discrete steps with a final one that executes the seq
- Consider pulling things in to coarser-grained steps to avoid long pipelines
Kent Beck
- Smalltalk practice
Jennifer Smith
Do OO Heuristics apply to Functional code?
You must be logged in to post a comment.