Skip to content
This repository was archived by the owner on May 27, 2022. It is now read-only.

Commit 58fe37f

Browse files
authored
Streamline dc management api (#11)
* Add response for request messages * Fix numbering * Adding messages for node status check * Reverting the node_ready support
1 parent 0250c9f commit 58fe37f

File tree

5 files changed

+543
-72
lines changed

5 files changed

+543
-72
lines changed

include/antidote_pb.hrl

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,14 @@
281281
}).
282282
-endif.
283283

284+
-ifndef('APBCREATEDCRESP_PB_H').
285+
-define('APBCREATEDCRESP_PB_H', true).
286+
-record('ApbCreateDCResp',
287+
{success :: boolean() | 0 | 1, % = 1
288+
errorcode :: non_neg_integer() | undefined % = 2, 32 bits
289+
}).
290+
-endif.
291+
284292
-ifndef('APBGETCONNECTIONDESCRIPTOR_PB_H').
285293
-define('APBGETCONNECTIONDESCRIPTOR_PB_H', true).
286294
-record('ApbGetConnectionDescriptor',
@@ -304,4 +312,12 @@
304312
}).
305313
-endif.
306314

315+
-ifndef('APBCONNECTTODCSRESP_PB_H').
316+
-define('APBCONNECTTODCSRESP_PB_H', true).
317+
-record('ApbConnectToDCsResp',
318+
{success :: boolean() | 0 | 1, % = 1
319+
errorcode :: non_neg_integer() | undefined % = 2, 32 bits
320+
}).
321+
-endif.
322+
307323
-endif.

proto/antidote.proto

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,11 @@ message ApbCreateDC {
248248
repeated string nodes = 1;
249249
}
250250

251+
message ApbCreateDCResp {
252+
required bool success = 1;
253+
optional uint32 errorcode = 2;
254+
}
255+
251256
// Get a connection descriptor of the DC to be given to other DCs.
252257
message ApbGetConnectionDescriptor {
253258
}
@@ -265,3 +270,8 @@ message ApbConnectToDCs {
265270
// descriptors is a list of connection information of all DCs obtained from ApbGetConnectionDescriptorResp.descriptor
266271
repeated bytes descriptors = 1;
267272
}
273+
274+
message ApbConnectToDCsResp {
275+
required bool success = 1;
276+
optional uint32 errorcode = 2;
277+
}

0 commit comments

Comments
 (0)