Skip to content

Commit 17204a2

Browse files
committed
Add some more db -> ledger deprecations
1 parent eb88807 commit 17204a2

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

src/fluree/db/operations.cljc

+12-12
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,9 @@
6060
([session] (delete-ledger-async session nil))
6161
([session {:keys [snapshot?] :as opts}]
6262
(let [{:keys [dbid network conn]} session]
63-
(send-operation conn :delete-db {:network network
64-
:dbid dbid
65-
:snapshot? snapshot?}))))
63+
(send-operation conn :delete-ledger {:network network
64+
:ledger-id dbid
65+
:snapshot? snapshot?}))))
6666

6767

6868
(defn garbage-collect-async
@@ -72,10 +72,10 @@
7272
[session & [{:keys [toBlock toTime]} :as opts]]
7373
(async/go
7474
(let [{:keys [network dbid conn]} session]
75-
(send-operation conn :garbage {:network network
76-
:dbid dbid
77-
:toBlock toBlock
78-
:toTime toTime}))))
75+
(send-operation conn :garbage {:network network
76+
:ledger-id dbid
77+
:toBlock toBlock
78+
:toTime toTime}))))
7979

8080

8181
(defn snapshot-ledger-async
@@ -84,7 +84,7 @@
8484
A final 'completed' message will be sent in the future, if anyone cares to hear it."
8585
[session opts]
8686
(let [{:keys [network dbid conn]} session]
87-
(send-operation conn :snapshot-db [network dbid])))
87+
(send-operation conn :snapshot-ledger [network dbid])))
8888

8989

9090
(defn command-async
@@ -106,24 +106,24 @@
106106

107107

108108
(defn ledger-info-async
109-
"Returns information about a ledger in a map, or empty map if db doesn't exist."
109+
"Returns information about a ledger in a map, or empty map if ledger doesn't exist."
110110
[conn ledger]
111111
(send-operation conn :ledger-info ledger))
112112

113113
(defn ledger-status-async
114-
"Returns information about a ledger in a map, or empty map if db doesn't exist."
114+
"Returns information about a ledger in a map, or empty map if ledger doesn't exist."
115115
[conn ledger]
116116
(:status (send-operation conn :ledger-info ledger)))
117117

118118
(defn ledger-stats-async
119-
"Returns stats about a ledger in a map, or empty map if db doesn't exist."
119+
"Returns stats about a ledger in a map, or empty map if ledger doesn't exist."
120120
[conn ledger]
121121
(send-operation conn :ledger-stats ledger))
122122

123123
(defn ledgers-async
124124
"Returns a list of ledgers in two-tuples of [network ledger-id]."
125125
[conn]
126-
(send-operation conn :db-list nil))
126+
(send-operation conn :ledger-list nil))
127127

128128

129129
(defn transact-async

0 commit comments

Comments
 (0)