SIM INFORMATION SYSTEM: REVOLUTIONIZING DATA MANAGEMENT
Clojure
1. Welcome to the World
of
Clojure
The language for
Web startups?
railando .com
Gain%%Speed%with%%Ruby%on% Rails
Berlin, Sep 21, 2012
2. Welcome to the World
of
Clojure
The language for
Web startups?
railando .com
Gain%%Speed%with%%Ruby%on% Rails
Berlin, Sep 21, 2012
3. What to expect in this presentation?
railando .com
Gain%%Speed%with%%Ruby%on% Rails
Berlin, Sep 21, 2012
4. What to expect in this presentation?
railando .com
Gain%%Speed%with%%Ruby%on% Rails
Berlin, Sep 21, 2012
5. What to expect in this presentation?
•Understand what Clojure is
•Understand what functional programming is
•Understand its benefits and drawbacks
•Inspiration to your own thoughts
•Hear about practical experience
•Know where to get help:
railando .com
Gain%%Speed%with%%Ruby%on% Rails
Berlin, Sep 21, 2012
8. New langugages build libraries slowly
Some language’s greatest reason to use
(even reason to be in existence)
is great library support
Otherwise great languages are not being widely
used because of (still) poor library support
9. Parallel Processing
Making an existing application thread-safe
means basically rebuilding it from scratch
if written in an imperative language (OO or not)
Moore’s Law (double performance every two years)
is still observed (as of 2012)
Change: Since a physical barrier in semiconductor
speed has been reached, Moore’s Law can only
materialize through parallelism
Proof in the real world: multi-core processors
10. Mutable State
It’s been a given in programming since Turing
Machines, so hardly anyone questions it
Tools like LOGO or SCRATCH teach kids that
programming is equivalent to managing mutable
state
Makes it incredibly hard to reuse code!
Makes it incredibly hard to parallelize.
11. What now?
How is
Clojure
an answer to these problems?
12. Functional Programming
Mutable State is a well-managed exception,
not the rule
Pure functions: Don’t depend on state
Makes it easy to reason about code and to reuse
code (OO was a step, but small)
Contrasting paradigm to imperative prpgramming.
13. Parallelism
Clojure manages mutable state well, taking
parallelism (in different flavors) carefully into
account
Clojure code can easily be made parallel
Even automatic parallelization is possible to some
extent
Remember: Who does not manage parallelism well,
will be non-existent by 2020!
14. Extensibilty
Clojure’s extensibility mechanism (called “Macros”,
an all-day name for a world-class concept) is
unrivaled
Examples:
Machine Learning/Statistics: R vs. cloj-ml
Logic Programming: Prolog vs. core-logic
15. Libraries / Communities
Based on Java / JVM
Can fully profit from Java’s enormous community,
battle-proven libraries and tools, etc.
Plus:
Clojure is fast.
FAST!
16. LISP syntax
Clojure is a dialect of LISP!
Syntax is simple. I mean: simple.
No LR parsing, Chomsky grammars, yni.
Who knows for sure all operator precedence in C,
C++, Java, Perl, Python, Ruby, ... ???
Fully parenthesized notation removes all
ambiguity
“Polish” notation. (Remember RPN?)
17. Our experience
Surprising amount of libraries available
Web develpment greatly simplified. Many things that require gems in
ruby work “just like that” in Clojure
Better performance than Ruby or Python
Extremely helpful and vibrant community
Incredible fun!
We expect enormous productivity gains in new projects.
Enables us to do things that matter, that wouldn’t be possible before!
Matching database system: Datomic!
Webapps: Clojure on the server and ClojureScript in the browser:
How cool is that?
21. Finally
Care for
help?
consulting?
support?
training?
Don’t forget to give us a call ;-)
bernd.blume@railando.com
railando .com
Gain%%Speed%with%%Ruby%on% Rails