# HG changeset patch # User Matthew Wild # Date 1435182857 -3600 # Node ID 4aee55c0cc5c25accc4f35822a63f10c7ed85c63 # Parent b553a30620b28a4790b49760147a34bd1191cc1e mod_storage_sql2: Add some comments diff -r b553a30620b2 -r 4aee55c0cc5c plugins/mod_storage_sql2.lua --- a/plugins/mod_storage_sql2.lua Wed Jun 03 15:57:46 2015 +0100 +++ b/plugins/mod_storage_sql2.lua Wed Jun 24 22:54:17 2015 +0100 @@ -192,6 +192,8 @@ return true; end +--- Key/value store API (default store type) + local keyval_store = {}; keyval_store.__index = keyval_store; function keyval_store:get(username) @@ -214,6 +216,8 @@ return iterator(result); end +--- Archive store API + local archive_store = {} archive_store.__index = archive_store function archive_store:append(username, key, when, with, value) @@ -342,6 +346,10 @@ archive = archive_store; }; +--- Implement storage driver API + +-- FIXME: Some of these operations need to operate on the archive store(s) too + local driver = {}; function driver:open(store, typ)