﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc	launchpad_bug
2866	Accounting, lease-db from cloud-backend	meejah		"Partial summary of devchat from February 21, 2017 and the path forward on pulling some of the things from the cloud-backend branch:

 - add pluggable backends, like 2237
 - add lease-db, like 2237 *except* the API for the lease-db goes into the backend API
 - add lease-db implementation using sqlite
 - like in 2237 currently, if a share isn't in the lease-db at all a new ""starter lease"" is added
 - lease-db is throw-away and can be lost at any time

We'd also discussed backing up the lease-db, but that can be an enhancement at a later date.

Some notes on various use-cases:

 - ""how much space is Alice using"" (we don't have notions of Alice etc yet though): this can be answered from the leasedb. If we've ""recently"" lost the lease-db, this answer will be inaccurate until ""default-share-expiry"" time has passed.
 - garbage-collecting: if the lease-db was lost, and a client didn't care about a share (and therefore never renewed it) the garbage-collector will be the first thing to ask the lease-db about it so a ""starter"" share will be created at that time. Therefore, it won't be garbage-collected until another default-share-expiry time has passed"	enhancement	closed	normal	soon	code-storage	1.12.1	wontfix			
