Clojure High Performance Programming - Second Edition

Become an expert at writing fast and high performant code in Clojure 1.7.0
Preview in Mapt
Code Files

Clojure High Performance Programming - Second Edition

Shantanu Kumar

1 customer reviews
Become an expert at writing fast and high performant code in Clojure 1.7.0
Mapt Subscription
FREE
$29.99/m after trial
eBook
$19.60
RRP $27.99
Save 29%
Print + eBook
$34.99
RRP $34.99
What do I get with a Mapt Pro subscription?
  • Unlimited access to all Packt’s 5,000+ eBooks and Videos
  • Early Access content, Progress Tracking, and Assessments
  • 1 Free eBook or Video to download and keep every month after trial
What do I get with an eBook?
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with Print & eBook?
  • Get a paperback copy of the book delivered to you
  • Download this book in EPUB, PDF, MOBI formats
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
What do I get with a Video?
  • Download this Video course in MP4 format
  • DRM FREE - read and interact with your content when you want, where you want, and how you want
  • Access this title in the Mapt reader
$0.00
$19.60
$34.99
$29.99 p/m after trial
RRP $27.99
RRP $34.99
Subscription
eBook
Print + eBook
Start 30 Day Trial

Frequently bought together


Clojure High Performance Programming - Second Edition Book Cover
Clojure High Performance Programming - Second Edition
$ 27.99
$ 19.60
Cassandra High Performance Cookbook - Second Edition Book Cover
Cassandra High Performance Cookbook - Second Edition
$ 35.99
$ 25.20
Buy 2 for $35.00
Save $28.98
Add to Cart

Book Details

ISBN 139781785283642
Paperback198 pages

Book Description

Clojure treats code as data and has a macro system. It focuses on programming with immutable values and explicit progression-of-time constructs, which are intended to facilitate the development of more robust programs, particularly multithreaded ones. It is built with performance, pragmatism, and simplicity in mind. Like most general purpose languages, various Clojure features have different performance characteristics that one should know in order to write high performance code.

This book shows you how to evaluate the performance implications of various Clojure abstractions, discover their underpinnings, and apply the right approach for optimum performance in real-world programs.

It starts by helping you classify various use cases and the need for them with respect to performance and analysis of various performance aspects. You will also learn the performance vocabulary that experts use throughout the world and discover various Clojure data structures, abstractions, and their performance characteristics. Further, the book will guide you through enhancing performance by using Java interoperability and JVM-specific features from Clojure. It also highlights the importance of using the right concurrent data structure and Java concurrency abstractions.

This book also sheds light on performance metrics for measuring, how to measure, and how to visualize and monitor the collected data. At the end of the book, you will learn to run a performance profiler, identify bottlenecks, tune performance, and refactor code to get a better performance.

Table of Contents

Chapter 1: Performance by Design
Use case classification
A structured approach to the performance
The performance vocabulary
The latency numbers that every programmer should know
Summary
Chapter 2: Clojure Abstractions
Non-numeric scalars and interning
Identity, value, and epochal time model
Persistent data structures
Sequences and laziness
Transducers
Transients
Performance miscellanea
Summary
Chapter 3: Leaning on Java
Inspecting the equivalent Java source for Clojure code
Numerics, boxing, and primitives
Arrays
Reflection and type hints
Using array/numeric libraries for efficiency
Resorting to Java and native code
Summary
Chapter 4: Host Performance
The hardware
The Java Virtual Machine
Measuring latency with Criterium
Summary
Chapter 5: Concurrency
Low-level concurrency
Atomic updates and state
Asynchronous agents and state
Coordinated transactional ref and state
Dynamic var binding and state
Validating and watching the reference types
Java concurrent data structures
Concurrency with threads
Clojure parallelization and the JVM
Parallelism with reducers
Summary
Chapter 6: Measuring Performance
Performance measurement and statistics
Performance testing
Performance monitoring
Profiling
Summary
Chapter 7: Performance Optimization
Project setup
Identifying performance bottlenecks
Profiling code with VisualVM
The Monitor tab
Performance tuning
Summary
Chapter 8: Application Performance
Choosing libraries
Logging
Data sizing
Resource pooling
I/O batching and throttling
Precomputing and caching
Concurrent pipelines
Applying back pressure
Performance and queueing theory
Summary

What You Will Learn

  • Identify performance issues in Clojure programs using different profiling tools
  • Master techniques to achieve numerical performance in Clojure
  • Use Criterium library to measure latency of Clojure expressions
  • Exploit Java features in Clojure code to enhance performance
  • Avoid reflection and boxing with type hints
  • Understand Clojure's concurrency and state-management primitives in depth
  • Measure and monitor performance, and understand optimization techniques

Authors

Table of Contents

Chapter 1: Performance by Design
Use case classification
A structured approach to the performance
The performance vocabulary
The latency numbers that every programmer should know
Summary
Chapter 2: Clojure Abstractions
Non-numeric scalars and interning
Identity, value, and epochal time model
Persistent data structures
Sequences and laziness
Transducers
Transients
Performance miscellanea
Summary
Chapter 3: Leaning on Java
Inspecting the equivalent Java source for Clojure code
Numerics, boxing, and primitives
Arrays
Reflection and type hints
Using array/numeric libraries for efficiency
Resorting to Java and native code
Summary
Chapter 4: Host Performance
The hardware
The Java Virtual Machine
Measuring latency with Criterium
Summary
Chapter 5: Concurrency
Low-level concurrency
Atomic updates and state
Asynchronous agents and state
Coordinated transactional ref and state
Dynamic var binding and state
Validating and watching the reference types
Java concurrent data structures
Concurrency with threads
Clojure parallelization and the JVM
Parallelism with reducers
Summary
Chapter 6: Measuring Performance
Performance measurement and statistics
Performance testing
Performance monitoring
Profiling
Summary
Chapter 7: Performance Optimization
Project setup
Identifying performance bottlenecks
Profiling code with VisualVM
The Monitor tab
Performance tuning
Summary
Chapter 8: Application Performance
Choosing libraries
Logging
Data sizing
Resource pooling
I/O batching and throttling
Precomputing and caching
Concurrent pipelines
Applying back pressure
Performance and queueing theory
Summary

Book Details

ISBN 139781785283642
Paperback198 pages
Read More
From 1 reviews

Read More Reviews

Recommended for You

Clojure Programming Cookbook Book Cover
Clojure Programming Cookbook
$ 39.99
$ 28.00
Mastering Clojure Book Cover
Mastering Clojure
$ 39.99
$ 28.00
Learning ClojureScript Book Cover
Learning ClojureScript
$ 31.99
$ 22.40
Clojure for Finance Book Cover
Clojure for Finance
$ 27.99
$ 19.60
Learning Functional Data Structures and Algorithms Book Cover
Learning Functional Data Structures and Algorithms
$ 35.99
$ 25.20
Getting Started with TensorFlow Book Cover
Getting Started with TensorFlow
$ 27.99
$ 19.60