struct _BlueSkyLog;
typedef struct _BlueSkyLog BlueSkyLog;
+struct _BlueSkyCloudLogState;
+typedef struct _BlueSkyCloudLogState BlueSkyCloudLogState;
+
void bluesky_store_init();
BlueSkyStore *bluesky_store_new(const gchar *type);
void bluesky_store_free(BlueSkyStore *store);
BlueSkyStore *store;
BlueSkyLog *log;
+ BlueSkyCloudLogState *log_state;
/* Accounting for memory used for caches. Space is measured in blocks, not
* bytes. We track both total data in the caches and dirty data (total
* avoid deadlock do not attempt to take any other locks while the FS lock
* is held for list editing purposes. Items at the head of the list are
* most recently accessed/modified. */
- GList dirty_list, accessed_list;
+ GList unlogged_list; // Changes not yet synced to journal
+ GList dirty_list; // Not yet written to cloud storage
+ GList accessed_list; // All in-memory inodes
/* Mutex for the flush daemon, to prevent concurrent execution. */
GMutex *flushd_lock;
* dirty linked lists. We re-use the GList structure, using ->next to
* point to the head of the list and ->prev to point to the tail. The data
* element is unused. */
- GList *accessed_list, *dirty_list;
+ GList *unlogged_list, *accessed_list, *dirty_list;
int64_t atime; /* Microseconds since the Unix epoch */
int64_t ctime;