gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-wallet-core] branch master updated: CRDT-style tombstones


From: gnunet
Subject: [taler-wallet-core] branch master updated: CRDT-style tombstones
Date: Mon, 07 Dec 2020 22:32:26 +0100

This is an automated email from the git hooks/post-receive script.

dold pushed a commit to branch master
in repository wallet-core.

The following commit(s) were added to refs/heads/master by this push:
     new 0e33e540 CRDT-style tombstones
0e33e540 is described below

commit 0e33e540f32aa90ef8bd6ee19c239ae7f5bd7db9
Author: Florian Dold <florian@dold.me>
AuthorDate: Mon Dec 7 23:32:20 2020 +0100

    CRDT-style tombstones
---
 .../taler-wallet-core/src/types/backupTypes.ts     | 39 +++++++++++++++++-----
 1 file changed, 31 insertions(+), 8 deletions(-)

diff --git a/packages/taler-wallet-core/src/types/backupTypes.ts 
b/packages/taler-wallet-core/src/types/backupTypes.ts
index 6bdf2699..d6062b92 100644
--- a/packages/taler-wallet-core/src/types/backupTypes.ts
+++ b/packages/taler-wallet-core/src/types/backupTypes.ts
@@ -21,8 +21,7 @@
  * as the backup schema must remain very stable and should be self-contained.
  *
  * Current limitations:
- * 1. Deletion tomb stones aren't supported yet
- * 2. Exchange/auditor trust isn't exported yet
+ * 1. Exchange/auditor trust isn't exported yet
  *    (see https://bugs.gnunet.org/view.php?id=6448)
  *
  * General considerations / decisions:
@@ -69,12 +68,6 @@ export interface WalletBackupContentV1 {
    */
   schema_version: 1;
 
-  /**
-   * Monotonically increasing clock of the wallet,
-   * used to determine causality when merging backups.
-   */
-  clock: number;
-
   /**
    * Root public key of the wallet.  This field is present as
    * a sanity check if the backup content JSON is loaded from file.
@@ -89,6 +82,16 @@ export interface WalletBackupContentV1 {
    */
   current_device_id: string;
 
+  /**
+   * Monotonically increasing clock of the wallet,
+   * used to determine causality when merging backups.
+   * 
+   * Information about other clocks, used to delete
+   * tombstones in the hopefully rare case that multiple wallets
+   * are connected to the same sync server.
+   */
+  clocks: { [device_id: string]: number };
+
   /**
    * Per-exchange data sorted by exchange master public key.
    *
@@ -137,6 +140,21 @@ export interface WalletBackupContentV1 {
    * Recoup groups.
    */
   recoup_groups: BackupRecoupGroup[];
+
+  /**
+   * Tombstones for deleting purchases.
+   */
+  purchase_tombstones: {
+    /**
+     * Clock when the purchase was deleted
+     */
+    clock_deleted: number;
+
+    /**
+     * Proposal ID identifying the purchase.
+     */
+    proposal_id: string;
+  }[];
 }
 
 /**
@@ -645,6 +663,11 @@ export interface BackupPurchase {
    */
   proposal_id: string;
 
+  /**
+   * Clock when this purchase was created.
+   */
+  clock_created: number;
+
   /**
    * Contract terms we got from the merchant.
    */

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]