I need "durable data" that interacts well with the STM too. I describe a system that works well for a specific use-case:
All data is stored in the persistent datastructures that clojure provides and changes are protected via refs as one would expect -- standard idiomatic clojure. Any change to a ref that needs to be durable is encapsulated as a "change record" and externalised via send-off. These change records are written to durable storage and form a complete log that can be replayed when the system restarts. A series of change records can be consolidated into a "snapshot" so that replay can begin from the most recent snapshot rather than the beginning of time. This system works in the application I'm working on because, while there are many change records, the current "working set" data can be held in memory. In RDBMS terms, the relationships between the entities are complex, but the number of rows is limited. The changes to the entities are managed via the STM and the application logic can make good use of clojure's concurrency/MVCC features. I saw that there was some discussion of integrating clojure and terracotta -- and that approach might allow working with data sets larger than main memory. But I haven't seen anything "official" and I can maintain the system described above without concern about living too close to the bleeding edge. Perhaps this approach is a "clojure pattern" and I've reinvented the wheel? If so please provide links! hope this helps! Steven Marcus --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---