Sha256: 6e6ac3935d5925528f6fedac64689ee229a1f514e682d1194cc00e974c904e09
Contents?: true
Size: 662 Bytes
Versions: 2
Compression:
Stored size: 662 Bytes
Contents
require_relative 'cache/version' require_relative 'cache/settings' require_relative 'cache/memcached' require_relative 'cache/redis' module Legion module Cache class << self attr_reader :client include Legion::Cache::Memcached if Legion::Settings[:cache][:driver] == 'dalli' include Legion::Cache::Redis if Legion::Settings[:cache][:driver] == 'redis' def setup connect Legion::Logging.info 'Legion::Cache connected and enabled' end def shutdown Legion::Logging.info 'Shutting down Legion::Cache' close Legion::Settings[:cache][:connected] = false end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
legion-cache-0.2.1 | lib/legion/cache.rb |
legion-cache-0.2.0 | lib/legion/cache.rb |