The TCache package

[ Tags: bsd3, data, database, library ] [ Propose Tags ]

TCache is a transactional cache with configurable persitence. It allows conventional STM transactions for objects that syncronize with their user defined storages. Default persistence in files is provided for testing purposes

This version support the backward compatible stuff, that permits transparent retrievals of objects and transcactions between objects without directly using STM references ('with*Resource(s)' calls), Now it goes in the oposite direction by providing explicit STM persistent references (called 'DBRefś') that leverage the nice and traditional haskell reference syntax for performing database transactions.

DBRefs are in essence, persistent TVars indexed in the cache, with a traditional readDBRef, writeDBRef Haskell interface in the STM monad. Additionally, because DBRefs are serializable, they can be embeded in serializable registers. Because they are references,they point to other serializable registers. This permits persistent mutable and efficient Inter-object relations.

Triggers are also included in this release. They are user defined hooks that are called back on register updates. That can be used for easing the actualization of inter-object relations and also permit more higuer level and customizable accesses. The internal indexes used for the query language uses triggers.

It also implements an straighforwards non-intrusive pure-haskell type safe query language based on register field relations. This module must be imported separately. See Data.TCache.IndexQuery for further information

Now the file persistence is more reliable.The IO reads are safe inside STM transactions.

To ease the implementation of other user-defined persistence, Data.TCache.FIlePersistence needed to be imported explcitly for deriving file persistence instances.

In this release some stuff has been supressed without losing functionality. Dynamic interfaces are not needed since TCache can handle heterogeneous data.


Versions 0.5, 0.5.1, 0.5.2, 0.5.3, 0.5.4, 0.5.5, 0.6.4, 0.6.5, 0.8.0,,, 0.9,,,,,,,,,,,,,,,,,,,,,,,, 0.12.0, 0.12.1
Dependencies base (==4.*), containers (>=, directory (>=1.0), old-time (>=1.0), stm (>=2), transformers (==0.2.*) [details]
License BSD3
Author Alberto Gómez Corona
Category Data, Database, Concurrency
Uploaded Mon Apr 11 20:06:29 UTC 2011 by AlbertoCorona
Distributions LTSHaskell:0.12.1, NixOS:0.12.1, Stackage:0.12.1, openSUSE:0.12.1
Downloads 16256 total (326 in the last 30 days)
Rating (no votes yet) [estimated by rule of succession]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
All reported builds failed as of 2016-12-28 [all 9 reports]
Hackage Matrix CI


  • Data
    • Data.TCache
      • Data.TCache.FilePersistence
      • Data.TCache.IndexQuery


Maintainer's Corner

For package maintainers and hackage trustees