Here's an example of a Ring session store that writes clojure maps to and
from Redis:

https://github.com/wuzhe/clj-redis-session/blob/master/src/clj_redis_session/core.clj

In addition to Deep Freeze, you might check out Kryo, accessible via Alex
Miller's Carbonite <https://github.com/revelytix/carbonite> library. I use
Kryo in both Cascalog and ElephantDB for Clojure data serialization, and
it's been working out wonderfully. Here are some kryo
benchmarks<http://code.google.com/p/kryo/wiki/BenchmarksAndComparisons>
if
you're interested.

On Wed, Jan 4, 2012 at 7:55 AM, Peter Taoussanis <ptaoussa...@gmail.com>wrote:

> read/pr-str works well, but it's painfully slow relative to something
> like Redis. JSON libraries and the like would be faster, but might
> require more contortions if you're using lots of Clojure data types.
> My 2c: the best overall compromise atm is the Deep-Freeze
> serialization library (https://github.com/halgari/deep-freeze). It
> gets you very decent performance and great support for Clojure data
> types.
>
> You don't mention what Redis client you're using, but be aware that if
> you're going to be going the binary serialization route, you'll want
> to communicate with Redis via byte[]s rather than JVM strings. If
> you're using Jedis, take a look at BinaryJedis.
>
> Hope that helps!
>
> --
> Peter
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/clojure?hl=en
>



-- 
Sam Ritchie, Twitter Inc
703.662.1337
@sritchie09

(Too brief? Here's why! http://emailcharter.org)

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to