1.1.0 is a minor release that introduces several minor features
andhas breaking changes.
Changes between 1.0.0 and 1.1.0
Clojure 1.4 Requirement
1.1.0 drops support for Clojure 1.3.
Heroku Add-on Support
By using SpyMemcached
2.8.9, you now can use Spyglass with Heroku
1 2 3 4 5 6
Contributed by Connor Mendenhall.
Clojure 1.5 By Default
Spyglass now depends on
1.5.1. It is
still compatible with Clojure 1.3+ and if your
on a different version, it will be used, but 1.5 is the default now.
We encourage all users to upgrade to 1.5, it is a drop-in replacement for the majority of projects out there.
Asynchronous Cache Store
Spyglass now ships both sync and async implementations of clojure.core.cache.
To instantiate async store, use
clojurewerkz.spyglass.cache/spyglass-cache-factory was renamed to
Contributed by Joseph Wilk.
Fix Authentication Support
no longer fail when credentials are passed in.
Empty gets Responses
clojurewerkz.spyglass.client/gets now correctly handles responses for
keys that do not exist.
GH issue: #4.
SASL (Authentication) Support
now support credentials:
(ns my.service (:require [clojurewerkz.spyglass.client :as c]))
;; uses credentials from environment variables, e.g. on Heroku: (c/text-connection “127.0.0.1:11211” (System/getenv “MEMCACHE_USERNAME”)
When you need to fine tune things and want to use a custom connection factory, you need to instantiate auth descriptor and pass it explicitly, like so:
1 2 3 4 5 6 7 8
Blocking Deref for Futures
Futures returned by async Spyglass operations now implement “blocking dereferencing”:
they can be dereferenced with a timeout and default value, just like futures created
clojure.core/future and similar.
Contributed by Joseph Wilk.
Support For Configurable Connections
clojurewerkz.spyglass.client/bin-connection-factory provide a Clojuric
way of instantiating connection factories. Those factories, in turn, can be
passed to new arities of
clojurewerkz.spyglass.client/bin-connection to control failure mode,
default transcoder and so on:
1 2 3 4
clojurewerkz.spyglass.cache now provides a
clojure.core.cache implementation on top of
1 2 3 4 5 6 7 8 9
SyncSpyglassCache uses synchronous operations from
clojurewerkz.spyglass.client. Asynchronous implementation
that returns futures will be added in the future.
SpyMemcached has been upgraded to
Improved Couchbase Support
clojurewerkz.spyglass.couchbase/connection is a new function that connects to Couchbase with the given
bucket and credentials. It returns a client that regular
clojurewerkz.spyglass.memcached functions can
We recommend all users to give 1.1.0 a try.
Spyglass change log is available on GitHub.
Spyglass is a ClojureWerkz Project
- Langohr, a Clojure client for RabbitMQ that embraces the AMQP 0.9.1 model
- Elastisch, a minimalistic Clojure client for ElasticSearch
- Monger, a Clojure MongoDB client for a more civilized age
- Neocons, a feature rich idiomatic Clojure client for the Neo4J REST API * Welle, a Riak client with batteries included
- Quartzite, a powerful scheduling library
and several others. If you like Spyglass, you may also like our other projects.