diff --git a/.script/protoc-java.sh b/.script/protoc-java.sh
index 3abe221..356243b 100644
--- a/.script/protoc-java.sh
+++ b/.script/protoc-java.sh
@@ -3,7 +3,7 @@
# This script installs protoc-gen-grpc-java for the given platform (defaults to linux-x86_64).
# See: https://search.maven.org/search?q=g:io.grpc%20a:protoc-gen-grpc-java
-VERSION=1.19.0
+VERSION=1.27.2
PLATFORM=$1
if [ -z "$1" ] ; then
PLATFORM=linux-x86_64
diff --git a/CHANGELOG.md b/CHANGELOG.md
index f6532c6..56dd211 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -2,6 +2,12 @@
Tracks changes made in between releases
+# v3.1.0
+
+* Migrate replication protos out of `node` into `TxPB` [#45](https://github.com/RTradeLtd/TxPB/pull/45)
+* Change replication documentation to markdown format [#40](https://github.com/RTradeLtd/TxPB/pull/40)
+* Documetnation updates [#39](https://github.com/RTradeLtd/TxPB/pull/39)
+
# v3.0.0
* API refactor [#36](https://github.com/RTradeLtd/TxPB/pull/36)
diff --git a/Makefile b/Makefile
index 791aeff..c9051de 100644
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,7 @@ proto: proto-gen tidy
# -I are the import paths, because we're using some plugins, we need to import the gogo protobuf helpers
.PHONY: proto-gen
-proto-gen: gen-file gen-util gen-status gen-pubsub gen-admin gen-namesys 1gen-node gen-replication gen-docs
+proto-gen: gen-file gen-util gen-status gen-pubsub gen-admin gen-namesys gen-node gen-replication gen-docs
# builds the static website
@@ -59,7 +59,6 @@ install:
npm install -g grpc-tools
python3 -m pip install grpcio-tools
bash .script/protoc-js.sh
- bash .script/protoc-java.sh
# protocol buffer generation targets
diff --git a/README.md b/README.md
index 9af9fbe..362f08b 100644
--- a/README.md
+++ b/README.md
@@ -24,6 +24,20 @@ If you want bindings in other languages, feel free to open a github issue. Alter
* [TemporalX HTTP Gateway](./doc/GATEWAY.md)
* [Benchmarks](./doc/BENCHMARKS.md)
+# Code Generation
+
+Before generating the code, you'll need to download quite a few generators. Before downloading the generators you'll need to have a valid installation of the following, please consult appropriate installation manuals as required:
+
+* Go 1.13+
+* NodeJS
+* NPM
+* Python3
+* Make
+
+Once you have all of this installed, you can then install the needed generators which will allow you to generate the gRPC client stubs. To do this run `make install`. This has to download quite a few packages so it might take some time to complete. The only thing this doesn't install is a java generator, to do that visit https://search.maven.org/search?q=g:io.grpc%20a:protoc-gen-grpc-java and download the one for your platform.
+
+After you've downloaded all generator tooling, you can generate the client stubs, and documentation with a single `make`.
+
# License
All code in this repository is licensed under `AGPL-3.0`, and all documentation is licensed under `MIT`. Documentation is anything that is a readme, or html file. Code is pretty much anything other than documentation such as javascript, java, golang, python, and `.proto` files.
diff --git a/doc/PROTO.md b/doc/PROTO.md
index aa059cf..d698d1a 100644
--- a/doc/PROTO.md
+++ b/doc/PROTO.md
@@ -91,6 +91,20 @@
- [PubSubAPI](#pb.PubSubAPI)
+- [replication.proto](#replication.proto)
+ - [AddrInfo](#pb.AddrInfo)
+ - [Replication](#pb.Replication)
+ - [ReplicationStatus](#pb.ReplicationStatus)
+ - [ServerSource](#pb.ServerSource)
+ - [SignedSubscription](#pb.SignedSubscription)
+ - [Subscription](#pb.Subscription)
+ - [SubscriptionUpdate](#pb.SubscriptionUpdate)
+
+
+
+ - [replicator](#pb.replicator)
+
+
- [status.proto](#status.proto)
- [StatusResponse](#pb.StatusResponse)
- [VersionResponse](#pb.VersionResponse)
@@ -460,7 +474,7 @@ NameSysAPI provides a generic name resolution API
| Field | Type | Label | Description |
| ----- | ---- | ----- | ----------- |
| cid | [string](#string) | | cid is the identifier of the block |
-| data | [bytes](#bytes) | | data is the actual contnets of this block |
+| data | [bytes](#bytes) | | data is the actual contents of the block |
@@ -1111,6 +1125,156 @@ PubSubAPI provides a libp2p pubsub API and is equivalent to go-ipfs
+
+
Top
+
+## replication.proto
+
+
+
+
+
+### AddrInfo
+AddrInfo can be used to ID and locate a server (see also libp2p/go-libp2p-core/peer#AddrInfo)
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| id_bytes | [bytes](#bytes) | | id_bytes is a libp2p peer identity. It is used to verity the Peer's public key. Please use helper functions GetID and SetID for this field |
+| addrs_bytes | [bytes](#bytes) | repeated | addrBytes are bytes of Multiaddr for locating this peer. Please use helper functions GetMultiAddrs, and SetMultiAddrs for this field. |
+| grpc_port | [int32](#int32) | | grpc port for replication protocol. will be optional once grpc is integrated into multistream. |
+
+
+
+
+
+
+
+
+### Replication
+Replication message is a signable data structure to represent a replication scheme
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| header | [string](#string) | | Header must be "rtrade-replication v0..." for development stage, this is a required security header. - Avoid collision from other signed data. - Allow future versions to require different validation rules. Any signer must understand every header tag to sign documents. |
+| cids_bytes | [bytes](#bytes) | repeated | CIDs is the list of contents to replicate. Please use helper functions GetCIDs and AddCIDs for this field |
+| servers | [ServerSource](#pb.ServerSource) | repeated | Servers list the candidate severs to replicate to, in the order of preference. |
+| replication_factor | [int32](#int32) | | replication_factor is the number of replications desired. |
+| refresh_interval_seconds | [int32](#int32) | | refresh_interval_seconds is the *suggested* number of seconds to wait before checking if a remote server is up. The first check should be random from 0 to refresh_interval_seconds. Each replicator can have it's own max_interval. A sensible default value should be used if it is 0. |
+| server_down_delay_seconds | [int32](#int32) | | server_down_delay_seconds is the number of seconds to wait after a server is down before the next reserved server is requested to be active. A sensible default value should be used if it is 0. |
+
+
+
+
+
+
+
+
+### ReplicationStatus
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| ok | [bool](#bool) | | ok report success for action submitted |
+| is_active | [bool](#bool) | | is_active report if the replication is currently active on this server |
+| current_version | [int64](#int64) | | current_version is the highest version this replicator/server has locally. |
+| target_version | [int64](#int64) | | target_version is the highest version this replicator/server knows about and can verify to exist. |
+
+
+
+
+
+
+
+
+### ServerSource
+ServerSource is a list of one or more servers.
+TODO: add field to allow referring to a list of servers from another file.
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| addr_info | [AddrInfo](#pb.AddrInfo) | | |
+
+
+
+
+
+
+
+
+### SignedSubscription
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| sub_part | [Subscription](#pb.Subscription) | | |
+| update_part | [SubscriptionUpdate](#pb.SubscriptionUpdate) | | |
+
+
+
+
+
+
+
+
+### Subscription
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| topic | [string](#string) | | |
+| author_id_bytes | [bytes](#bytes) | | |
+| remove | [bool](#bool) | | if true, remove this Subscription. For replicator.Add, deactive this replication. For replicator.WaitForUpdates, stop reporting updates. |
+
+
+
+
+
+
+
+
+### SubscriptionUpdate
+
+
+
+| Field | Type | Label | Description |
+| ----- | ---- | ----- | ----------- |
+| version | [int64](#int64) | | strictly increasing version number |
+| replication_bytes | [bytes](#bytes) | | replication file is in bytes for signing |
+| signature | [bytes](#bytes) | | signature signs the Subscription and above data in length delimited form in the order topic|author|version|replication |
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+### replicator
+The replicator provides replication services.
+
+| Method Name | Request Type | Response Type | Description |
+| ----------- | ------------ | ------------- | ------------|
+| Add | [Subscription](#pb.Subscription) | [ReplicationStatus](#pb.ReplicationStatus) stream | Add is used to add a replication to this server, changing it's status from reserved to active. |
+| Status | [Subscription](#pb.Subscription) | [ReplicationStatus](#pb.ReplicationStatus) stream | Status returns an updating stream of the replication status on the server. |
+| GetSubscriptionUpdate | [Subscription](#pb.Subscription) | [SubscriptionUpdate](#pb.SubscriptionUpdate) | GetSubscriptionUpdate returns the latest version of subscribed replication |
+| SubmitReplication | [SignedSubscription](#pb.SignedSubscription) | [ReplicationStatus](#pb.ReplicationStatus) stream | SubmitReplication is used by client agents to start replications, after they have uploaded the files and retrieved the cid, and collected servers to replicate too. |
+
+
+
+
+
Top
diff --git a/go.mod b/go.mod
index d4885e0..bc0f5c3 100644
--- a/go.mod
+++ b/go.mod
@@ -4,8 +4,12 @@ go 1.13
require (
github.com/gogo/protobuf v1.3.1
+ github.com/golang/protobuf v1.3.4 // indirect
github.com/ipfs/go-cid v0.0.4
github.com/libp2p/go-libp2p-core v0.3.1
github.com/multiformats/go-multiaddr v0.2.0
- google.golang.org/grpc v1.26.0
+ golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d // indirect
+ golang.org/x/net v0.0.0-20191002035440-2ec189313ef0 // indirect
+ google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383 // indirect
+ google.golang.org/grpc v1.27.0
)
diff --git a/go.sum b/go.sum
index 37dbb9c..becf809 100644
--- a/go.sum
+++ b/go.sum
@@ -30,6 +30,9 @@ github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5y
github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
github.com/golang/protobuf v1.3.2 h1:6nsPYzhq5kReh6QImI3k5qWzO4PEbvbIW2cwSfR/6xs=
github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
+github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
+github.com/golang/protobuf v1.3.4 h1:87PNWwrRvUSnqS4dlcBU/ftvOIBep4sYuBLlh6rX2wk=
+github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw=
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
github.com/google/go-cmp v0.3.0 h1:crn/baboCvb5fXaQ0IJ1SGTsTVrWpDsCWC8EGETZijY=
github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU=
@@ -103,6 +106,8 @@ golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnf
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8 h1:1wopBVtVdWnn03fZelqdXTqk7U7zPQCb+T4rbU9ZEoU=
golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
+golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d h1:1ZiEyfaQIg3Qh0EoqpwAakHVhecoE5wlSg5GjnafJGw=
+golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE=
golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU=
@@ -116,6 +121,8 @@ golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859 h1:R/3boaszxrf1GEUWTVDzSKVwLmSJpwZ1yqXm8j0v2QI=
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
+golang.org/x/net v0.0.0-20191002035440-2ec189313ef0 h1:2mqDk8w/o6UmeUCu5Qiq2y7iMf6anbx+YA8d1JFoFrs=
+golang.org/x/net v0.0.0-20191002035440-2ec189313ef0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
@@ -147,11 +154,13 @@ google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoA
google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE=
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55 h1:gSJIx1SDwno+2ElGhA4+qG2zF97qiUzTM+rQ0klBOcE=
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
+google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383 h1:Vo0fD5w0fUKriWlZLyrim2GXbumyN0D6euW79T9PgEE=
+google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c=
google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c=
google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38=
google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg=
-google.golang.org/grpc v1.26.0 h1:2dTRdpdFEEhJYQD8EMLB61nnrzSCTbG38PhqdhvOltg=
-google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
+google.golang.org/grpc v1.27.0 h1:rRYRFMVgRv6E0D70Skyfsr28tDXIuuPZyWGMPdMcnXg=
+google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys=
diff --git a/go/node.pb.go b/go/node.pb.go
index 295b31c..8407fb8 100644
--- a/go/node.pb.go
+++ b/go/node.pb.go
@@ -1022,8 +1022,7 @@ func (m *BlockstoreResponse) GetBlocks() []*Block {
type Block struct {
// cid is the identifier of the block
Cid string `protobuf:"bytes,1,opt,name=cid,proto3" json:"cid,omitempty"`
- // data is the actual contnets of this block
- //
+ // data is the actual contents of the block
Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
}
@@ -1791,7 +1790,7 @@ type NodeAPIClient interface {
Blockstore(ctx context.Context, in *BlockstoreRequest, opts ...grpc.CallOption) (*BlockstoreResponse, error)
// Dag is a unidirectional rpc allowing manipulation of low-level ipld objects
Dag(ctx context.Context, in *DagRequest, opts ...grpc.CallOption) (*DagResponse, error)
- //Keystore is a unidirectional RPC allowing management of ipfs keystores
+ // Keystore is a unidirectional RPC allowing management of ipfs keystores
Keystore(ctx context.Context, in *KeystoreRequest, opts ...grpc.CallOption) (*KeystoreResponse, error)
// Persist is used to retrieve data from the network and make it available locally
Persist(ctx context.Context, in *PersistRequest, opts ...grpc.CallOption) (*PersistResponse, error)
@@ -1882,7 +1881,7 @@ type NodeAPIServer interface {
Blockstore(context.Context, *BlockstoreRequest) (*BlockstoreResponse, error)
// Dag is a unidirectional rpc allowing manipulation of low-level ipld objects
Dag(context.Context, *DagRequest) (*DagResponse, error)
- //Keystore is a unidirectional RPC allowing management of ipfs keystores
+ // Keystore is a unidirectional RPC allowing management of ipfs keystores
Keystore(context.Context, *KeystoreRequest) (*KeystoreResponse, error)
// Persist is used to retrieve data from the network and make it available locally
Persist(context.Context, *PersistRequest) (*PersistResponse, error)
diff --git a/go/replication.pb.go b/go/replication.pb.go
index 901b5b6..f827aa1 100644
--- a/go/replication.pb.go
+++ b/go/replication.pb.go
@@ -57,7 +57,7 @@ func (m *Replication) Reset() { *m = Replication{} }
func (m *Replication) String() string { return proto.CompactTextString(m) }
func (*Replication) ProtoMessage() {}
func (*Replication) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{0}
+ return fileDescriptor_ed0454e9e09fb71a, []int{0}
}
func (m *Replication) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -141,7 +141,7 @@ func (m *ServerSource) Reset() { *m = ServerSource{} }
func (m *ServerSource) String() string { return proto.CompactTextString(m) }
func (*ServerSource) ProtoMessage() {}
func (*ServerSource) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{1}
+ return fileDescriptor_ed0454e9e09fb71a, []int{1}
}
func (m *ServerSource) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -196,7 +196,7 @@ func (m *AddrInfo) Reset() { *m = AddrInfo{} }
func (m *AddrInfo) String() string { return proto.CompactTextString(m) }
func (*AddrInfo) ProtoMessage() {}
func (*AddrInfo) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{2}
+ return fileDescriptor_ed0454e9e09fb71a, []int{2}
}
func (m *AddrInfo) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -262,7 +262,7 @@ func (m *Subscription) Reset() { *m = Subscription{} }
func (m *Subscription) String() string { return proto.CompactTextString(m) }
func (*Subscription) ProtoMessage() {}
func (*Subscription) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{3}
+ return fileDescriptor_ed0454e9e09fb71a, []int{3}
}
func (m *Subscription) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -330,7 +330,7 @@ func (m *ReplicationStatus) Reset() { *m = ReplicationStatus{} }
func (m *ReplicationStatus) String() string { return proto.CompactTextString(m) }
func (*ReplicationStatus) ProtoMessage() {}
func (*ReplicationStatus) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{4}
+ return fileDescriptor_ed0454e9e09fb71a, []int{4}
}
func (m *ReplicationStatus) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -403,7 +403,7 @@ func (m *SubscriptionUpdate) Reset() { *m = SubscriptionUpdate{} }
func (m *SubscriptionUpdate) String() string { return proto.CompactTextString(m) }
func (*SubscriptionUpdate) ProtoMessage() {}
func (*SubscriptionUpdate) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{5}
+ return fileDescriptor_ed0454e9e09fb71a, []int{5}
}
func (m *SubscriptionUpdate) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -465,7 +465,7 @@ func (m *SignedSubscription) Reset() { *m = SignedSubscription{} }
func (m *SignedSubscription) String() string { return proto.CompactTextString(m) }
func (*SignedSubscription) ProtoMessage() {}
func (*SignedSubscription) Descriptor() ([]byte, []int) {
- return fileDescriptor_be7112c31591aaa3, []int{6}
+ return fileDescriptor_ed0454e9e09fb71a, []int{6}
}
func (m *SignedSubscription) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
@@ -518,50 +518,49 @@ func init() {
proto.RegisterType((*SignedSubscription)(nil), "pb.SignedSubscription")
}
-func init() { proto.RegisterFile("pb/replication.proto", fileDescriptor_be7112c31591aaa3) }
-
-var fileDescriptor_be7112c31591aaa3 = []byte{
- // 626 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0x5f, 0x6f, 0xd3, 0x3e,
- 0x14, 0x55, 0xd2, 0xad, 0x4d, 0x6f, 0xb3, 0x7f, 0xd6, 0x56, 0x65, 0xbf, 0x1f, 0x8c, 0x2a, 0x12,
- 0x50, 0x98, 0x18, 0xd3, 0xf6, 0x00, 0x7b, 0xec, 0x34, 0x81, 0xf6, 0x36, 0x39, 0x82, 0xd7, 0xc8,
- 0x89, 0xdd, 0xce, 0xda, 0x16, 0x47, 0xb6, 0xd3, 0x69, 0x7c, 0x0a, 0x1e, 0xf8, 0x50, 0x3c, 0xf2,
- 0x11, 0xd0, 0x3e, 0x07, 0x0f, 0x28, 0xb6, 0xbb, 0xa6, 0x94, 0x3d, 0xf0, 0x96, 0x7b, 0xee, 0x39,
- 0xb9, 0xc7, 0xe7, 0x5a, 0x86, 0xed, 0x32, 0x7b, 0x2b, 0x59, 0x79, 0xcd, 0x73, 0xa2, 0xb9, 0x28,
- 0x0e, 0x4a, 0x29, 0xb4, 0x40, 0x7e, 0x99, 0xc5, 0xdf, 0x7c, 0xe8, 0xe1, 0x79, 0x07, 0xf5, 0xa1,
- 0x7d, 0xc9, 0x08, 0x65, 0x32, 0xf2, 0x06, 0xde, 0xb0, 0x8b, 0x5d, 0x85, 0x9e, 0x02, 0xe4, 0x9c,
- 0xaa, 0x34, 0xbb, 0xd3, 0x4c, 0x45, 0xfe, 0xa0, 0x35, 0x0c, 0x71, 0xb7, 0x46, 0x4e, 0x6b, 0x00,
- 0xbd, 0x86, 0x8e, 0x62, 0x72, 0xca, 0xa4, 0x8a, 0x5a, 0x83, 0xd6, 0xb0, 0x77, 0xb4, 0x79, 0x50,
- 0x66, 0x07, 0x89, 0x81, 0x12, 0x51, 0xc9, 0x9c, 0xe1, 0x19, 0x01, 0xbd, 0x01, 0xd4, 0xf0, 0x92,
- 0x8e, 0x49, 0xae, 0x85, 0x8c, 0x56, 0x06, 0xde, 0x70, 0x15, 0x6f, 0x35, 0x3a, 0x1f, 0x4c, 0x03,
- 0xbd, 0x87, 0x48, 0xb2, 0xb1, 0x64, 0xea, 0x32, 0xe5, 0x85, 0x66, 0x72, 0x4a, 0xae, 0x53, 0xc5,
- 0x72, 0x51, 0x50, 0x15, 0xad, 0x1a, 0x51, 0xdf, 0xf5, 0xcf, 0x5d, 0x3b, 0xb1, 0x5d, 0x74, 0x02,
- 0xbb, 0x76, 0x66, 0x4a, 0xc5, 0x6d, 0x91, 0x52, 0x76, 0x4d, 0xee, 0x1e, 0xa4, 0x6d, 0x2b, 0xb5,
- 0x84, 0x33, 0x71, 0x5b, 0x9c, 0xd5, 0x6d, 0x27, 0x8d, 0x4f, 0x20, 0x6c, 0x9a, 0x47, 0xaf, 0xa0,
- 0x4b, 0x28, 0x95, 0x29, 0x2f, 0xc6, 0xc2, 0x24, 0xd3, 0x3b, 0x0a, 0xeb, 0x13, 0x8e, 0x28, 0x95,
- 0xe7, 0xc5, 0x58, 0xe0, 0x80, 0xb8, 0xaf, 0x38, 0x87, 0x60, 0x86, 0xa2, 0x5d, 0x08, 0x38, 0x75,
- 0x99, 0xd5, 0xaa, 0x10, 0x77, 0x38, 0xb5, 0x89, 0x3d, 0x83, 0x5e, 0x2d, 0x59, 0x4c, 0x14, 0x0c,
- 0x64, 0x09, 0xff, 0x43, 0x77, 0x22, 0xcb, 0x3c, 0x2d, 0x85, 0xd4, 0x51, 0xcb, 0xb8, 0x0d, 0x6a,
- 0xe0, 0x42, 0x48, 0x1d, 0x53, 0x08, 0x93, 0x2a, 0x53, 0xb9, 0xe4, 0xa5, 0x59, 0xdb, 0x36, 0xac,
- 0x6a, 0x51, 0xf2, 0xdc, 0x6d, 0xcd, 0x16, 0xe8, 0x05, 0x6c, 0x90, 0x4a, 0x5f, 0x0a, 0x99, 0x3e,
- 0xb8, 0xf0, 0x8d, 0x8b, 0x35, 0x0b, 0x9f, 0x3b, 0x2f, 0x7d, 0x68, 0x4b, 0x76, 0x23, 0xa6, 0xcc,
- 0xcc, 0x09, 0xb0, 0xab, 0xe2, 0xaf, 0x1e, 0x6c, 0x35, 0x2e, 0x47, 0xa2, 0x89, 0xae, 0x14, 0x5a,
- 0x07, 0x5f, 0x5c, 0x99, 0x41, 0x01, 0xf6, 0xc5, 0x55, 0x6d, 0x94, 0xab, 0x94, 0xe4, 0x9a, 0x4f,
- 0x99, 0xf9, 0x7f, 0x80, 0x03, 0xae, 0x46, 0xa6, 0x46, 0x2f, 0x61, 0x23, 0xaf, 0xa4, 0x64, 0x85,
- 0x4e, 0xeb, 0xe5, 0x73, 0x51, 0x98, 0x19, 0x2d, 0xbc, 0xee, 0xe0, 0xcf, 0x16, 0x45, 0xcf, 0x61,
- 0x5d, 0x13, 0x39, 0x61, 0x73, 0xde, 0x8a, 0xe1, 0xad, 0x59, 0xd4, 0xd1, 0xe2, 0x3b, 0x40, 0xcd,
- 0x83, 0x7f, 0x2a, 0x29, 0xd1, 0x0c, 0x45, 0xd0, 0x99, 0xa9, 0x3c, 0xa3, 0x9a, 0x95, 0x68, 0x1f,
- 0x9a, 0x57, 0x6a, 0x21, 0x84, 0xcd, 0x46, 0xc3, 0xe6, 0xf0, 0x04, 0xba, 0x8a, 0x4f, 0x0a, 0xa2,
- 0x2b, 0x69, 0xa3, 0x08, 0xf1, 0x1c, 0x88, 0xbf, 0x00, 0x4a, 0xf8, 0xa4, 0x60, 0x74, 0x21, 0xf9,
- 0x7d, 0x08, 0x54, 0x95, 0xa5, 0x25, 0x91, 0xda, 0x5d, 0x0c, 0x7b, 0xf5, 0x1b, 0x1c, 0xdc, 0x51,
- 0x55, 0x76, 0x41, 0xa4, 0x46, 0xef, 0xa0, 0x57, 0x19, 0xc7, 0x96, 0xef, 0x1b, 0x7e, 0xff, 0x4f,
- 0xbe, 0x3d, 0x14, 0x06, 0x4b, 0xad, 0x85, 0x47, 0xbf, 0x3c, 0x80, 0x99, 0x5d, 0x21, 0xd1, 0x21,
- 0xb4, 0x46, 0x94, 0xa2, 0xa5, 0x49, 0xff, 0xed, 0xd4, 0xc8, 0xd2, 0xca, 0x0e, 0x3d, 0x74, 0x0c,
- 0x6d, 0xb7, 0xbe, 0x7f, 0x10, 0x8d, 0x60, 0xe7, 0x23, 0xd3, 0x7f, 0xc9, 0x7b, 0xf9, 0x1f, 0x8f,
- 0x1c, 0x02, 0x9d, 0xc1, 0x56, 0x52, 0x65, 0x37, 0x5c, 0x2f, 0x3c, 0x32, 0x86, 0xbc, 0x94, 0xe5,
- 0xa3, 0x46, 0x4e, 0xc3, 0xef, 0xf7, 0x7b, 0xde, 0x8f, 0xfb, 0x3d, 0xef, 0xe7, 0xfd, 0x9e, 0x97,
- 0xb5, 0xcd, 0xf3, 0x75, 0xfc, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x0c, 0x22, 0x48, 0x23, 0xd6, 0x04,
- 0x00, 0x00,
+func init() { proto.RegisterFile("replication.proto", fileDescriptor_ed0454e9e09fb71a) }
+
+var fileDescriptor_ed0454e9e09fb71a = []byte{
+ // 622 bytes of a gzipped FileDescriptorProto
+ 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0xcd, 0x6e, 0xd4, 0x3c,
+ 0x14, 0x55, 0x92, 0x76, 0x26, 0x73, 0x27, 0xfd, 0xb3, 0xbe, 0x8e, 0xd2, 0x0f, 0x28, 0xa3, 0x48,
+ 0xc0, 0x40, 0x45, 0x55, 0xb5, 0x0b, 0xe8, 0x72, 0xaa, 0x0a, 0xd4, 0x5d, 0xe5, 0x08, 0xb6, 0x91,
+ 0x13, 0x7b, 0xa6, 0x56, 0xdb, 0x38, 0xb2, 0x9d, 0xa9, 0xca, 0x53, 0xb0, 0xe0, 0xa1, 0x58, 0xf2,
+ 0x08, 0xa8, 0xcf, 0xc1, 0x02, 0xc5, 0xf6, 0xb4, 0x19, 0x86, 0x2e, 0xd8, 0xe5, 0x9e, 0x7b, 0x4e,
+ 0xee, 0xf1, 0xb9, 0x96, 0x61, 0x4b, 0xb2, 0xea, 0x8a, 0x17, 0x44, 0x73, 0x51, 0xee, 0x57, 0x52,
+ 0x68, 0x81, 0xfc, 0x2a, 0x4f, 0xbe, 0xf9, 0xd0, 0xc7, 0x0f, 0x1d, 0x34, 0x80, 0xce, 0x05, 0x23,
+ 0x94, 0xc9, 0xd8, 0x1b, 0x7a, 0xa3, 0x1e, 0x76, 0x15, 0x7a, 0x06, 0x50, 0x70, 0xaa, 0xb2, 0xfc,
+ 0x56, 0x33, 0x15, 0xfb, 0xc3, 0x60, 0x14, 0xe1, 0x5e, 0x83, 0x9c, 0x34, 0x00, 0x7a, 0x03, 0x5d,
+ 0xc5, 0xe4, 0x8c, 0x49, 0x15, 0x07, 0xc3, 0x60, 0xd4, 0x3f, 0xdc, 0xdc, 0xaf, 0xf2, 0xfd, 0xd4,
+ 0x40, 0xa9, 0xa8, 0x65, 0xc1, 0xf0, 0x9c, 0x80, 0xde, 0x02, 0x6a, 0x79, 0xc9, 0x26, 0xa4, 0xd0,
+ 0x42, 0xc6, 0x2b, 0x43, 0x6f, 0xb4, 0x8a, 0xdb, 0x2e, 0x3f, 0x98, 0x06, 0x7a, 0x0f, 0xb1, 0x64,
+ 0x13, 0xc9, 0xd4, 0x45, 0xc6, 0x4b, 0xcd, 0xe4, 0x8c, 0x5c, 0x65, 0x8a, 0x15, 0xa2, 0xa4, 0x2a,
+ 0x5e, 0x35, 0xa2, 0x81, 0xeb, 0x9f, 0xb9, 0x76, 0x6a, 0xbb, 0xe8, 0x18, 0x76, 0xec, 0xcc, 0x8c,
+ 0x8a, 0x9b, 0x32, 0xa3, 0xec, 0x8a, 0xdc, 0xde, 0x4b, 0x3b, 0x56, 0x6a, 0x09, 0xa7, 0xe2, 0xa6,
+ 0x3c, 0x6d, 0xda, 0x4e, 0x9a, 0x1c, 0x43, 0xd4, 0x36, 0x8f, 0x5e, 0x43, 0x8f, 0x50, 0x2a, 0x33,
+ 0x5e, 0x4e, 0x84, 0x49, 0xa6, 0x7f, 0x18, 0x35, 0x27, 0x1c, 0x53, 0x2a, 0xcf, 0xca, 0x89, 0xc0,
+ 0x21, 0x71, 0x5f, 0x49, 0x01, 0xe1, 0x1c, 0x45, 0x3b, 0x10, 0x72, 0xea, 0x32, 0x6b, 0x54, 0x11,
+ 0xee, 0x72, 0x6a, 0x13, 0x7b, 0x0e, 0xfd, 0x46, 0xb2, 0x98, 0x28, 0x18, 0xc8, 0x12, 0x9e, 0x40,
+ 0x6f, 0x2a, 0xab, 0x22, 0xab, 0x84, 0xd4, 0x71, 0x60, 0xdc, 0x86, 0x0d, 0x70, 0x2e, 0xa4, 0x4e,
+ 0x28, 0x44, 0x69, 0x9d, 0xab, 0x42, 0xf2, 0xca, 0xac, 0xed, 0x3f, 0x58, 0xd5, 0xa2, 0xe2, 0x85,
+ 0xdb, 0x9a, 0x2d, 0xd0, 0x4b, 0xd8, 0x20, 0xb5, 0xbe, 0x10, 0x32, 0xbb, 0x77, 0xe1, 0x1b, 0x17,
+ 0x6b, 0x16, 0x3e, 0x73, 0x5e, 0x06, 0xd0, 0x91, 0xec, 0x5a, 0xcc, 0x98, 0x99, 0x13, 0x62, 0x57,
+ 0x25, 0x5f, 0x3d, 0xd8, 0x6a, 0x5d, 0x8e, 0x54, 0x13, 0x5d, 0x2b, 0xb4, 0x0e, 0xbe, 0xb8, 0x34,
+ 0x83, 0x42, 0xec, 0x8b, 0xcb, 0xc6, 0x28, 0x57, 0x19, 0x29, 0x34, 0x9f, 0x31, 0xf3, 0xff, 0x10,
+ 0x87, 0x5c, 0x8d, 0x4d, 0x8d, 0x5e, 0xc1, 0x46, 0x51, 0x4b, 0xc9, 0x4a, 0x9d, 0x35, 0xcb, 0xe7,
+ 0xa2, 0x34, 0x33, 0x02, 0xbc, 0xee, 0xe0, 0xcf, 0x16, 0x45, 0x2f, 0x60, 0x5d, 0x13, 0x39, 0x65,
+ 0x0f, 0xbc, 0x15, 0xc3, 0x5b, 0xb3, 0xa8, 0xa3, 0x25, 0xb7, 0x80, 0xda, 0x07, 0xff, 0x54, 0x51,
+ 0xa2, 0x19, 0x8a, 0xa1, 0x3b, 0x57, 0x79, 0x46, 0x35, 0x2f, 0xd1, 0xde, 0xc2, 0xc5, 0x5f, 0x08,
+ 0x61, 0xb3, 0xd5, 0xb0, 0x39, 0x3c, 0x85, 0x9e, 0xe2, 0xd3, 0x92, 0xe8, 0x5a, 0xda, 0x28, 0x22,
+ 0xfc, 0x00, 0x24, 0x5f, 0x00, 0xa5, 0x7c, 0x5a, 0x32, 0xba, 0x90, 0xfc, 0x1e, 0x84, 0xaa, 0xce,
+ 0xb3, 0x8a, 0x48, 0xed, 0x2e, 0x86, 0xbd, 0xfa, 0x2d, 0x0e, 0xee, 0xaa, 0x3a, 0x3f, 0x27, 0x52,
+ 0xa3, 0x77, 0xd0, 0xaf, 0x8d, 0x63, 0xcb, 0xf7, 0x0d, 0x7f, 0xf0, 0x27, 0xdf, 0x1e, 0x0a, 0x83,
+ 0xa5, 0x36, 0xc2, 0xc3, 0x5f, 0x1e, 0xc0, 0xdc, 0xae, 0x90, 0xe8, 0x00, 0x82, 0x31, 0xa5, 0x68,
+ 0x69, 0xd2, 0xff, 0xdb, 0x0d, 0xb2, 0xb4, 0xb2, 0x03, 0x0f, 0x1d, 0x41, 0xc7, 0xad, 0xef, 0x1f,
+ 0x44, 0x63, 0xd8, 0xfe, 0xc8, 0xf4, 0x5f, 0xf2, 0x5e, 0xfe, 0xc7, 0x23, 0x87, 0x40, 0xa7, 0xb0,
+ 0x95, 0xd6, 0xf9, 0x35, 0xd7, 0x0b, 0x8f, 0x8c, 0x21, 0x2f, 0x65, 0xf9, 0xa8, 0x91, 0x93, 0xe8,
+ 0xfb, 0xdd, 0xae, 0xf7, 0xe3, 0x6e, 0xd7, 0xfb, 0x79, 0xb7, 0xeb, 0xe5, 0x1d, 0xf3, 0x7c, 0x1d,
+ 0xfd, 0x0e, 0x00, 0x00, 0xff, 0xff, 0xb7, 0xf0, 0x26, 0x7f, 0xd3, 0x04, 0x00, 0x00,
}
// Reference imports to suppress errors if they are not otherwise used.
@@ -841,7 +840,7 @@ var _Replicator_serviceDesc = grpc.ServiceDesc{
ServerStreams: true,
},
},
- Metadata: "pb/replication.proto",
+ Metadata: "replication.proto",
}
func (m *Replication) Marshal() (dAtA []byte, err error) {
diff --git a/java/pb/AdminAPIGrpc.java b/java/pb/AdminAPIGrpc.java
index b261ea2..73c3c75 100644
--- a/java/pb/AdminAPIGrpc.java
+++ b/java/pb/AdminAPIGrpc.java
@@ -21,7 +21,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: admin.proto")
public final class AdminAPIGrpc {
@@ -44,22 +44,21 @@ pb.Admin.ManageGCResponse> getManageGCMethod() {
if ((getManageGCMethod = AdminAPIGrpc.getManageGCMethod) == null) {
synchronized (AdminAPIGrpc.class) {
if ((getManageGCMethod = AdminAPIGrpc.getManageGCMethod) == null) {
- AdminAPIGrpc.getManageGCMethod = getManageGCMethod =
+ AdminAPIGrpc.getManageGCMethod = getManageGCMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.AdminAPI", "ManageGC"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ManageGC"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Admin.ManageGCRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Admin.ManageGCResponse.getDefaultInstance()))
- .setSchemaDescriptor(new AdminAPIMethodDescriptorSupplier("ManageGC"))
- .build();
- }
+ .setSchemaDescriptor(new AdminAPIMethodDescriptorSupplier("ManageGC"))
+ .build();
}
- }
- return getManageGCMethod;
+ }
+ }
+ return getManageGCMethod;
}
private static volatile io.grpc.MethodDescriptor getRefCountMethod() {
if ((getRefCountMethod = AdminAPIGrpc.getRefCountMethod) == null) {
synchronized (AdminAPIGrpc.class) {
if ((getRefCountMethod = AdminAPIGrpc.getRefCountMethod) == null) {
- AdminAPIGrpc.getRefCountMethod = getRefCountMethod =
+ AdminAPIGrpc.getRefCountMethod = getRefCountMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.AdminAPI", "RefCount"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "RefCount"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Admin.RefCountRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Admin.RefCountResponse.getDefaultInstance()))
- .setSchemaDescriptor(new AdminAPIMethodDescriptorSupplier("RefCount"))
- .build();
- }
+ .setSchemaDescriptor(new AdminAPIMethodDescriptorSupplier("RefCount"))
+ .build();
}
- }
- return getRefCountMethod;
+ }
+ }
+ return getRefCountMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static AdminAPIStub newStub(io.grpc.Channel channel) {
- return new AdminAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public AdminAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new AdminAPIStub(channel, callOptions);
+ }
+ };
+ return AdminAPIStub.newStub(factory, channel);
}
/**
@@ -106,7 +111,14 @@ public static AdminAPIStub newStub(io.grpc.Channel channel) {
*/
public static AdminAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new AdminAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public AdminAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new AdminAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return AdminAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -114,7 +126,14 @@ public static AdminAPIBlockingStub newBlockingStub(
*/
public static AdminAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new AdminAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public AdminAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new AdminAPIFutureStub(channel, callOptions);
+ }
+ };
+ return AdminAPIFutureStub.newStub(factory, channel);
}
/**
@@ -169,19 +188,15 @@ public void refCount(pb.Admin.RefCountRequest request,
* AdminAPI facilitates administrative management of TemporalX via a localhost gRPC API
*
*/
- public static final class AdminAPIStub extends io.grpc.stub.AbstractStub {
- private AdminAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private AdminAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class AdminAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private AdminAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected AdminAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected AdminAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new AdminAPIStub(channel, callOptions);
}
@@ -213,19 +228,15 @@ public void refCount(pb.Admin.RefCountRequest request,
* AdminAPI facilitates administrative management of TemporalX via a localhost gRPC API
*
*/
- public static final class AdminAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private AdminAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private AdminAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class AdminAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private AdminAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected AdminAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected AdminAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new AdminAPIBlockingStub(channel, callOptions);
}
@@ -255,19 +266,15 @@ public pb.Admin.RefCountResponse refCount(pb.Admin.RefCountRequest request) {
* AdminAPI facilitates administrative management of TemporalX via a localhost gRPC API
*
*/
- public static final class AdminAPIFutureStub extends io.grpc.stub.AbstractStub {
- private AdminAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private AdminAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class AdminAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private AdminAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected AdminAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected AdminAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new AdminAPIFutureStub(channel, callOptions);
}
diff --git a/java/pb/FileAPIGrpc.java b/java/pb/FileAPIGrpc.java
index fef9dcb..c37b55c 100644
--- a/java/pb/FileAPIGrpc.java
+++ b/java/pb/FileAPIGrpc.java
@@ -21,7 +21,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: file.proto")
public final class FileAPIGrpc {
@@ -44,22 +44,21 @@ pb.Util.PutResponse> getUploadFileMethod() {
if ((getUploadFileMethod = FileAPIGrpc.getUploadFileMethod) == null) {
synchronized (FileAPIGrpc.class) {
if ((getUploadFileMethod = FileAPIGrpc.getUploadFileMethod) == null) {
- FileAPIGrpc.getUploadFileMethod = getUploadFileMethod =
+ FileAPIGrpc.getUploadFileMethod = getUploadFileMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.CLIENT_STREAMING)
- .setFullMethodName(generateFullMethodName(
- "pb.FileAPI", "UploadFile"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UploadFile"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.File.UploadRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Util.PutResponse.getDefaultInstance()))
- .setSchemaDescriptor(new FileAPIMethodDescriptorSupplier("UploadFile"))
- .build();
- }
+ .setSchemaDescriptor(new FileAPIMethodDescriptorSupplier("UploadFile"))
+ .build();
}
- }
- return getUploadFileMethod;
+ }
+ }
+ return getUploadFileMethod;
}
private static volatile io.grpc.MethodDescriptor getDownloadFileMethod() {
if ((getDownloadFileMethod = FileAPIGrpc.getDownloadFileMethod) == null) {
synchronized (FileAPIGrpc.class) {
if ((getDownloadFileMethod = FileAPIGrpc.getDownloadFileMethod) == null) {
- FileAPIGrpc.getDownloadFileMethod = getDownloadFileMethod =
+ FileAPIGrpc.getDownloadFileMethod = getDownloadFileMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
- .setFullMethodName(generateFullMethodName(
- "pb.FileAPI", "DownloadFile"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DownloadFile"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.File.DownloadRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.File.DownloadResponse.getDefaultInstance()))
- .setSchemaDescriptor(new FileAPIMethodDescriptorSupplier("DownloadFile"))
- .build();
- }
+ .setSchemaDescriptor(new FileAPIMethodDescriptorSupplier("DownloadFile"))
+ .build();
}
- }
- return getDownloadFileMethod;
+ }
+ }
+ return getDownloadFileMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static FileAPIStub newStub(io.grpc.Channel channel) {
- return new FileAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public FileAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new FileAPIStub(channel, callOptions);
+ }
+ };
+ return FileAPIStub.newStub(factory, channel);
}
/**
@@ -106,7 +111,14 @@ public static FileAPIStub newStub(io.grpc.Channel channel) {
*/
public static FileAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new FileAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public FileAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new FileAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return FileAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -114,7 +126,14 @@ public static FileAPIBlockingStub newBlockingStub(
*/
public static FileAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new FileAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public FileAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new FileAPIFutureStub(channel, callOptions);
+ }
+ };
+ return FileAPIFutureStub.newStub(factory, channel);
}
/**
@@ -169,19 +188,15 @@ public void downloadFile(pb.File.DownloadRequest request,
* FileAPI provides a gRPC api to upload/download files as UnixFS objects
*
*/
- public static final class FileAPIStub extends io.grpc.stub.AbstractStub {
- private FileAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private FileAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class FileAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private FileAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected FileAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected FileAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new FileAPIStub(channel, callOptions);
}
@@ -213,19 +228,15 @@ public void downloadFile(pb.File.DownloadRequest request,
* FileAPI provides a gRPC api to upload/download files as UnixFS objects
*
*/
- public static final class FileAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private FileAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private FileAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class FileAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private FileAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected FileAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected FileAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new FileAPIBlockingStub(channel, callOptions);
}
@@ -246,19 +257,15 @@ public java.util.Iterator downloadFile(
* FileAPI provides a gRPC api to upload/download files as UnixFS objects
*
*/
- public static final class FileAPIFutureStub extends io.grpc.stub.AbstractStub {
- private FileAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private FileAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class FileAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private FileAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected FileAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected FileAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new FileAPIFutureStub(channel, callOptions);
}
}
diff --git a/java/pb/NameSysAPIGrpc.java b/java/pb/NameSysAPIGrpc.java
index c0a8cd5..e94de7f 100644
--- a/java/pb/NameSysAPIGrpc.java
+++ b/java/pb/NameSysAPIGrpc.java
@@ -21,7 +21,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: namesys.proto")
public final class NameSysAPIGrpc {
@@ -44,22 +44,21 @@ pb.Namesys.NameSysResolveResult> getNameSysResolveMethod() {
if ((getNameSysResolveMethod = NameSysAPIGrpc.getNameSysResolveMethod) == null) {
synchronized (NameSysAPIGrpc.class) {
if ((getNameSysResolveMethod = NameSysAPIGrpc.getNameSysResolveMethod) == null) {
- NameSysAPIGrpc.getNameSysResolveMethod = getNameSysResolveMethod =
+ NameSysAPIGrpc.getNameSysResolveMethod = getNameSysResolveMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NameSysAPI", "NameSysResolve"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "NameSysResolve"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Namesys.NameSysResolveRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Namesys.NameSysResolveResult.getDefaultInstance()))
- .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysResolve"))
- .build();
- }
+ .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysResolve"))
+ .build();
}
- }
- return getNameSysResolveMethod;
+ }
+ }
+ return getNameSysResolveMethod;
}
private static volatile io.grpc.MethodDescriptor getNameSysResolveAsyncMethod() {
if ((getNameSysResolveAsyncMethod = NameSysAPIGrpc.getNameSysResolveAsyncMethod) == null) {
synchronized (NameSysAPIGrpc.class) {
if ((getNameSysResolveAsyncMethod = NameSysAPIGrpc.getNameSysResolveAsyncMethod) == null) {
- NameSysAPIGrpc.getNameSysResolveAsyncMethod = getNameSysResolveAsyncMethod =
+ NameSysAPIGrpc.getNameSysResolveAsyncMethod = getNameSysResolveAsyncMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
- .setFullMethodName(generateFullMethodName(
- "pb.NameSysAPI", "NameSysResolveAsync"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "NameSysResolveAsync"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Namesys.NameSysResolveRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Namesys.NameSysResolveResult.getDefaultInstance()))
- .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysResolveAsync"))
- .build();
- }
+ .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysResolveAsync"))
+ .build();
}
- }
- return getNameSysResolveAsyncMethod;
+ }
+ }
+ return getNameSysResolveAsyncMethod;
}
private static volatile io.grpc.MethodDescriptor getNameSysPublishMethod() {
if ((getNameSysPublishMethod = NameSysAPIGrpc.getNameSysPublishMethod) == null) {
synchronized (NameSysAPIGrpc.class) {
if ((getNameSysPublishMethod = NameSysAPIGrpc.getNameSysPublishMethod) == null) {
- NameSysAPIGrpc.getNameSysPublishMethod = getNameSysPublishMethod =
+ NameSysAPIGrpc.getNameSysPublishMethod = getNameSysPublishMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NameSysAPI", "NameSysPublish"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "NameSysPublish"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Namesys.NameSysPublishRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Util.Empty.getDefaultInstance()))
- .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysPublish"))
- .build();
- }
+ .setSchemaDescriptor(new NameSysAPIMethodDescriptorSupplier("NameSysPublish"))
+ .build();
}
- }
- return getNameSysPublishMethod;
+ }
+ }
+ return getNameSysPublishMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static NameSysAPIStub newStub(io.grpc.Channel channel) {
- return new NameSysAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NameSysAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NameSysAPIStub(channel, callOptions);
+ }
+ };
+ return NameSysAPIStub.newStub(factory, channel);
}
/**
@@ -138,7 +142,14 @@ public static NameSysAPIStub newStub(io.grpc.Channel channel) {
*/
public static NameSysAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new NameSysAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NameSysAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NameSysAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return NameSysAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -146,7 +157,14 @@ public static NameSysAPIBlockingStub newBlockingStub(
*/
public static NameSysAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new NameSysAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NameSysAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NameSysAPIFutureStub(channel, callOptions);
+ }
+ };
+ return NameSysAPIFutureStub.newStub(factory, channel);
}
/**
@@ -219,19 +237,15 @@ public void nameSysPublish(pb.Namesys.NameSysPublishRequest request,
* NameSysAPI provides a generic name resolution API
*
*/
- public static final class NameSysAPIStub extends io.grpc.stub.AbstractStub {
- private NameSysAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NameSysAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NameSysAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private NameSysAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NameSysAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NameSysAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NameSysAPIStub(channel, callOptions);
}
@@ -275,19 +289,15 @@ public void nameSysPublish(pb.Namesys.NameSysPublishRequest request,
* NameSysAPI provides a generic name resolution API
*
*/
- public static final class NameSysAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private NameSysAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NameSysAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NameSysAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private NameSysAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NameSysAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NameSysAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NameSysAPIBlockingStub(channel, callOptions);
}
@@ -329,19 +339,15 @@ public pb.Util.Empty nameSysPublish(pb.Namesys.NameSysPublishRequest request) {
* NameSysAPI provides a generic name resolution API
*
*/
- public static final class NameSysAPIFutureStub extends io.grpc.stub.AbstractStub {
- private NameSysAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NameSysAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NameSysAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private NameSysAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NameSysAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NameSysAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NameSysAPIFutureStub(channel, callOptions);
}
diff --git a/java/pb/NodeAPIGrpc.java b/java/pb/NodeAPIGrpc.java
index 84c9e48..e7bd6d1 100644
--- a/java/pb/NodeAPIGrpc.java
+++ b/java/pb/NodeAPIGrpc.java
@@ -21,7 +21,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: node.proto")
public final class NodeAPIGrpc {
@@ -44,22 +44,21 @@ pb.Node.ConnMgmtResponse> getConnMgmtMethod() {
if ((getConnMgmtMethod = NodeAPIGrpc.getConnMgmtMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getConnMgmtMethod = NodeAPIGrpc.getConnMgmtMethod) == null) {
- NodeAPIGrpc.getConnMgmtMethod = getConnMgmtMethod =
+ NodeAPIGrpc.getConnMgmtMethod = getConnMgmtMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "ConnMgmt"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ConnMgmt"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.ConnMgmtRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.ConnMgmtResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("ConnMgmt"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("ConnMgmt"))
+ .build();
}
- }
- return getConnMgmtMethod;
+ }
+ }
+ return getConnMgmtMethod;
}
private static volatile io.grpc.MethodDescriptor getExtrasMethod() {
if ((getExtrasMethod = NodeAPIGrpc.getExtrasMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getExtrasMethod = NodeAPIGrpc.getExtrasMethod) == null) {
- NodeAPIGrpc.getExtrasMethod = getExtrasMethod =
+ NodeAPIGrpc.getExtrasMethod = getExtrasMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "Extras"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Extras"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.ExtrasRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Util.Empty.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Extras"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Extras"))
+ .build();
}
- }
- return getExtrasMethod;
+ }
+ }
+ return getExtrasMethod;
}
private static volatile io.grpc.MethodDescriptor getP2PMethod() {
if ((getP2PMethod = NodeAPIGrpc.getP2PMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getP2PMethod = NodeAPIGrpc.getP2PMethod) == null) {
- NodeAPIGrpc.getP2PMethod = getP2PMethod =
+ NodeAPIGrpc.getP2PMethod = getP2PMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "P2P"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "P2P"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.P2PRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.P2PResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("P2P"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("P2P"))
+ .build();
}
- }
- return getP2PMethod;
+ }
+ }
+ return getP2PMethod;
}
private static volatile io.grpc.MethodDescriptor getBlockstoreMethod() {
if ((getBlockstoreMethod = NodeAPIGrpc.getBlockstoreMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getBlockstoreMethod = NodeAPIGrpc.getBlockstoreMethod) == null) {
- NodeAPIGrpc.getBlockstoreMethod = getBlockstoreMethod =
+ NodeAPIGrpc.getBlockstoreMethod = getBlockstoreMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "Blockstore"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Blockstore"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.BlockstoreRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.BlockstoreResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Blockstore"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Blockstore"))
+ .build();
}
- }
- return getBlockstoreMethod;
+ }
+ }
+ return getBlockstoreMethod;
}
private static volatile io.grpc.MethodDescriptor getDagMethod() {
if ((getDagMethod = NodeAPIGrpc.getDagMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getDagMethod = NodeAPIGrpc.getDagMethod) == null) {
- NodeAPIGrpc.getDagMethod = getDagMethod =
+ NodeAPIGrpc.getDagMethod = getDagMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "Dag"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Dag"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.DagRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.DagResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Dag"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Dag"))
+ .build();
}
- }
- return getDagMethod;
+ }
+ }
+ return getDagMethod;
}
private static volatile io.grpc.MethodDescriptor getKeystoreMethod() {
if ((getKeystoreMethod = NodeAPIGrpc.getKeystoreMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getKeystoreMethod = NodeAPIGrpc.getKeystoreMethod) == null) {
- NodeAPIGrpc.getKeystoreMethod = getKeystoreMethod =
+ NodeAPIGrpc.getKeystoreMethod = getKeystoreMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "Keystore"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Keystore"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.KeystoreRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.KeystoreResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Keystore"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Keystore"))
+ .build();
}
- }
- return getKeystoreMethod;
+ }
+ }
+ return getKeystoreMethod;
}
private static volatile io.grpc.MethodDescriptor getPersistMethod() {
if ((getPersistMethod = NodeAPIGrpc.getPersistMethod) == null) {
synchronized (NodeAPIGrpc.class) {
if ((getPersistMethod = NodeAPIGrpc.getPersistMethod) == null) {
- NodeAPIGrpc.getPersistMethod = getPersistMethod =
+ NodeAPIGrpc.getPersistMethod = getPersistMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.NodeAPI", "Persist"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Persist"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.PersistRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Node.PersistResponse.getDefaultInstance()))
- .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Persist"))
- .build();
- }
+ .setSchemaDescriptor(new NodeAPIMethodDescriptorSupplier("Persist"))
+ .build();
}
- }
- return getPersistMethod;
+ }
+ }
+ return getPersistMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static NodeAPIStub newStub(io.grpc.Channel channel) {
- return new NodeAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NodeAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NodeAPIStub(channel, callOptions);
+ }
+ };
+ return NodeAPIStub.newStub(factory, channel);
}
/**
@@ -266,7 +266,14 @@ public static NodeAPIStub newStub(io.grpc.Channel channel) {
*/
public static NodeAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new NodeAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NodeAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NodeAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return NodeAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -274,7 +281,14 @@ public static NodeAPIBlockingStub newBlockingStub(
*/
public static NodeAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new NodeAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public NodeAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new NodeAPIFutureStub(channel, callOptions);
+ }
+ };
+ return NodeAPIFutureStub.newStub(factory, channel);
}
/**
@@ -338,7 +352,7 @@ public void dag(pb.Node.DagRequest request,
/**
*
- *Keystore is a unidirectional RPC allowing management of ipfs keystores
+ * Keystore is a unidirectional RPC allowing management of ipfs keystores
*
*/
public void keystore(pb.Node.KeystoreRequest request,
@@ -416,19 +430,15 @@ public void persist(pb.Node.PersistRequest request,
* NodeAPI provide an API to control the underlying custom ipfs node
*
*/
- public static final class NodeAPIStub extends io.grpc.stub.AbstractStub {
- private NodeAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NodeAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NodeAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private NodeAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NodeAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NodeAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NodeAPIStub(channel, callOptions);
}
@@ -491,7 +501,7 @@ public void dag(pb.Node.DagRequest request,
/**
*
- *Keystore is a unidirectional RPC allowing management of ipfs keystores
+ * Keystore is a unidirectional RPC allowing management of ipfs keystores
*
*/
public void keystore(pb.Node.KeystoreRequest request,
@@ -517,19 +527,15 @@ public void persist(pb.Node.PersistRequest request,
* NodeAPI provide an API to control the underlying custom ipfs node
*
*/
- public static final class NodeAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private NodeAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NodeAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NodeAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private NodeAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NodeAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NodeAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NodeAPIBlockingStub(channel, callOptions);
}
@@ -587,7 +593,7 @@ public pb.Node.DagResponse dag(pb.Node.DagRequest request) {
/**
*
- *Keystore is a unidirectional RPC allowing management of ipfs keystores
+ * Keystore is a unidirectional RPC allowing management of ipfs keystores
*
*/
public pb.Node.KeystoreResponse keystore(pb.Node.KeystoreRequest request) {
@@ -611,19 +617,15 @@ public pb.Node.PersistResponse persist(pb.Node.PersistRequest request) {
* NodeAPI provide an API to control the underlying custom ipfs node
*
*/
- public static final class NodeAPIFutureStub extends io.grpc.stub.AbstractStub {
- private NodeAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private NodeAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class NodeAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private NodeAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected NodeAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected NodeAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new NodeAPIFutureStub(channel, callOptions);
}
@@ -686,7 +688,7 @@ public com.google.common.util.concurrent.ListenableFuture d
/**
*
- *Keystore is a unidirectional RPC allowing management of ipfs keystores
+ * Keystore is a unidirectional RPC allowing management of ipfs keystores
*
*/
public com.google.common.util.concurrent.ListenableFuture keystore(
diff --git a/java/pb/PubSubAPIGrpc.java b/java/pb/PubSubAPIGrpc.java
index 00b0964..639d0b2 100644
--- a/java/pb/PubSubAPIGrpc.java
+++ b/java/pb/PubSubAPIGrpc.java
@@ -22,7 +22,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: pubsub.proto")
public final class PubSubAPIGrpc {
@@ -45,29 +45,35 @@ pb.Pubsub.PubSubResponse> getPubSubMethod() {
if ((getPubSubMethod = PubSubAPIGrpc.getPubSubMethod) == null) {
synchronized (PubSubAPIGrpc.class) {
if ((getPubSubMethod = PubSubAPIGrpc.getPubSubMethod) == null) {
- PubSubAPIGrpc.getPubSubMethod = getPubSubMethod =
+ PubSubAPIGrpc.getPubSubMethod = getPubSubMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING)
- .setFullMethodName(generateFullMethodName(
- "pb.PubSubAPI", "PubSub"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "PubSub"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Pubsub.PubSubRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Pubsub.PubSubResponse.getDefaultInstance()))
- .setSchemaDescriptor(new PubSubAPIMethodDescriptorSupplier("PubSub"))
- .build();
- }
+ .setSchemaDescriptor(new PubSubAPIMethodDescriptorSupplier("PubSub"))
+ .build();
}
- }
- return getPubSubMethod;
+ }
+ }
+ return getPubSubMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static PubSubAPIStub newStub(io.grpc.Channel channel) {
- return new PubSubAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public PubSubAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new PubSubAPIStub(channel, callOptions);
+ }
+ };
+ return PubSubAPIStub.newStub(factory, channel);
}
/**
@@ -75,7 +81,14 @@ public static PubSubAPIStub newStub(io.grpc.Channel channel) {
*/
public static PubSubAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new PubSubAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public PubSubAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new PubSubAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return PubSubAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -83,7 +96,14 @@ public static PubSubAPIBlockingStub newBlockingStub(
*/
public static PubSubAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new PubSubAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public PubSubAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new PubSubAPIFutureStub(channel, callOptions);
+ }
+ };
+ return PubSubAPIFutureStub.newStub(factory, channel);
}
/**
@@ -124,19 +144,15 @@ public io.grpc.stub.StreamObserver pubSub(
* `ipfs pubsub` subset of commands.
*
*/
- public static final class PubSubAPIStub extends io.grpc.stub.AbstractStub {
- private PubSubAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private PubSubAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class PubSubAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private PubSubAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected PubSubAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected PubSubAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new PubSubAPIStub(channel, callOptions);
}
@@ -159,19 +175,15 @@ public io.grpc.stub.StreamObserver pubSub(
* `ipfs pubsub` subset of commands.
*
*/
- public static final class PubSubAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private PubSubAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private PubSubAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class PubSubAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private PubSubAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected PubSubAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected PubSubAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new PubSubAPIBlockingStub(channel, callOptions);
}
}
@@ -182,19 +194,15 @@ protected PubSubAPIBlockingStub build(io.grpc.Channel channel,
* `ipfs pubsub` subset of commands.
*
*/
- public static final class PubSubAPIFutureStub extends io.grpc.stub.AbstractStub {
- private PubSubAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private PubSubAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class PubSubAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private PubSubAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected PubSubAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected PubSubAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new PubSubAPIFutureStub(channel, callOptions);
}
}
diff --git a/java/pb/StatusAPIGrpc.java b/java/pb/StatusAPIGrpc.java
index 02e9cab..6af1833 100644
--- a/java/pb/StatusAPIGrpc.java
+++ b/java/pb/StatusAPIGrpc.java
@@ -21,7 +21,7 @@
*
*/
@javax.annotation.Generated(
- value = "by gRPC proto compiler (version 1.19.0)",
+ value = "by gRPC proto compiler (version 1.27.2)",
comments = "Source: status.proto")
public final class StatusAPIGrpc {
@@ -44,22 +44,21 @@ pb.Status.VersionResponse> getVersionMethod() {
if ((getVersionMethod = StatusAPIGrpc.getVersionMethod) == null) {
synchronized (StatusAPIGrpc.class) {
if ((getVersionMethod = StatusAPIGrpc.getVersionMethod) == null) {
- StatusAPIGrpc.getVersionMethod = getVersionMethod =
+ StatusAPIGrpc.getVersionMethod = getVersionMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.StatusAPI", "Version"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Version"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Util.Empty.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Status.VersionResponse.getDefaultInstance()))
- .setSchemaDescriptor(new StatusAPIMethodDescriptorSupplier("Version"))
- .build();
- }
+ .setSchemaDescriptor(new StatusAPIMethodDescriptorSupplier("Version"))
+ .build();
}
- }
- return getVersionMethod;
+ }
+ }
+ return getVersionMethod;
}
private static volatile io.grpc.MethodDescriptor getStatusMethod() {
if ((getStatusMethod = StatusAPIGrpc.getStatusMethod) == null) {
synchronized (StatusAPIGrpc.class) {
if ((getStatusMethod = StatusAPIGrpc.getStatusMethod) == null) {
- StatusAPIGrpc.getStatusMethod = getStatusMethod =
+ StatusAPIGrpc.getStatusMethod = getStatusMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
- .setFullMethodName(generateFullMethodName(
- "pb.StatusAPI", "Status"))
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Status"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Util.Empty.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
pb.Status.StatusResponse.getDefaultInstance()))
- .setSchemaDescriptor(new StatusAPIMethodDescriptorSupplier("Status"))
- .build();
- }
+ .setSchemaDescriptor(new StatusAPIMethodDescriptorSupplier("Status"))
+ .build();
}
- }
- return getStatusMethod;
+ }
+ }
+ return getStatusMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static StatusAPIStub newStub(io.grpc.Channel channel) {
- return new StatusAPIStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public StatusAPIStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new StatusAPIStub(channel, callOptions);
+ }
+ };
+ return StatusAPIStub.newStub(factory, channel);
}
/**
@@ -106,7 +111,14 @@ public static StatusAPIStub newStub(io.grpc.Channel channel) {
*/
public static StatusAPIBlockingStub newBlockingStub(
io.grpc.Channel channel) {
- return new StatusAPIBlockingStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public StatusAPIBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new StatusAPIBlockingStub(channel, callOptions);
+ }
+ };
+ return StatusAPIBlockingStub.newStub(factory, channel);
}
/**
@@ -114,7 +126,14 @@ public static StatusAPIBlockingStub newBlockingStub(
*/
public static StatusAPIFutureStub newFutureStub(
io.grpc.Channel channel) {
- return new StatusAPIFutureStub(channel);
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public StatusAPIFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new StatusAPIFutureStub(channel, callOptions);
+ }
+ };
+ return StatusAPIFutureStub.newStub(factory, channel);
}
/**
@@ -169,19 +188,15 @@ public void status(pb.Util.Empty request,
* provides utilities to retrieve api status information from
*
*/
- public static final class StatusAPIStub extends io.grpc.stub.AbstractStub {
- private StatusAPIStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private StatusAPIStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class StatusAPIStub extends io.grpc.stub.AbstractAsyncStub {
+ private StatusAPIStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected StatusAPIStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected StatusAPIStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new StatusAPIStub(channel, callOptions);
}
@@ -213,19 +228,15 @@ public void status(pb.Util.Empty request,
* provides utilities to retrieve api status information from
*
*/
- public static final class StatusAPIBlockingStub extends io.grpc.stub.AbstractStub {
- private StatusAPIBlockingStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private StatusAPIBlockingStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class StatusAPIBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private StatusAPIBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected StatusAPIBlockingStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected StatusAPIBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new StatusAPIBlockingStub(channel, callOptions);
}
@@ -255,19 +266,15 @@ public pb.Status.StatusResponse status(pb.Util.Empty request) {
* provides utilities to retrieve api status information from
*
*/
- public static final class StatusAPIFutureStub extends io.grpc.stub.AbstractStub {
- private StatusAPIFutureStub(io.grpc.Channel channel) {
- super(channel);
- }
-
- private StatusAPIFutureStub(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ public static final class StatusAPIFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private StatusAPIFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
- protected StatusAPIFutureStub build(io.grpc.Channel channel,
- io.grpc.CallOptions callOptions) {
+ protected StatusAPIFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new StatusAPIFutureStub(channel, callOptions);
}
diff --git a/java/pb/replicatorGrpc.java b/java/pb/replicatorGrpc.java
new file mode 100644
index 0000000..eb8799e
--- /dev/null
+++ b/java/pb/replicatorGrpc.java
@@ -0,0 +1,546 @@
+package pb;
+
+import static io.grpc.MethodDescriptor.generateFullMethodName;
+import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
+import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
+import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
+import static io.grpc.stub.ClientCalls.asyncUnaryCall;
+import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
+import static io.grpc.stub.ClientCalls.blockingUnaryCall;
+import static io.grpc.stub.ClientCalls.futureUnaryCall;
+import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
+import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
+import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
+import static io.grpc.stub.ServerCalls.asyncUnaryCall;
+import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
+import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
+
+/**
+ *
+ * The replicator provides replication services.
+ *
+ */
+@javax.annotation.Generated(
+ value = "by gRPC proto compiler (version 1.27.2)",
+ comments = "Source: replication.proto")
+public final class replicatorGrpc {
+
+ private replicatorGrpc() {}
+
+ public static final String SERVICE_NAME = "pb.replicator";
+
+ // Static method descriptors that strictly reflect the proto.
+ private static volatile io.grpc.MethodDescriptor getAddMethod;
+
+ @io.grpc.stub.annotations.RpcMethod(
+ fullMethodName = SERVICE_NAME + '/' + "Add",
+ requestType = pb.ReplicationOuterClass.Subscription.class,
+ responseType = pb.ReplicationOuterClass.ReplicationStatus.class,
+ methodType = io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ public static io.grpc.MethodDescriptor getAddMethod() {
+ io.grpc.MethodDescriptor getAddMethod;
+ if ((getAddMethod = replicatorGrpc.getAddMethod) == null) {
+ synchronized (replicatorGrpc.class) {
+ if ((getAddMethod = replicatorGrpc.getAddMethod) == null) {
+ replicatorGrpc.getAddMethod = getAddMethod =
+ io.grpc.MethodDescriptor.newBuilder()
+ .setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Add"))
+ .setSampledToLocalTracing(true)
+ .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.Subscription.getDefaultInstance()))
+ .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.ReplicationStatus.getDefaultInstance()))
+ .setSchemaDescriptor(new replicatorMethodDescriptorSupplier("Add"))
+ .build();
+ }
+ }
+ }
+ return getAddMethod;
+ }
+
+ private static volatile io.grpc.MethodDescriptor getStatusMethod;
+
+ @io.grpc.stub.annotations.RpcMethod(
+ fullMethodName = SERVICE_NAME + '/' + "Status",
+ requestType = pb.ReplicationOuterClass.Subscription.class,
+ responseType = pb.ReplicationOuterClass.ReplicationStatus.class,
+ methodType = io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ public static io.grpc.MethodDescriptor getStatusMethod() {
+ io.grpc.MethodDescriptor getStatusMethod;
+ if ((getStatusMethod = replicatorGrpc.getStatusMethod) == null) {
+ synchronized (replicatorGrpc.class) {
+ if ((getStatusMethod = replicatorGrpc.getStatusMethod) == null) {
+ replicatorGrpc.getStatusMethod = getStatusMethod =
+ io.grpc.MethodDescriptor.newBuilder()
+ .setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Status"))
+ .setSampledToLocalTracing(true)
+ .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.Subscription.getDefaultInstance()))
+ .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.ReplicationStatus.getDefaultInstance()))
+ .setSchemaDescriptor(new replicatorMethodDescriptorSupplier("Status"))
+ .build();
+ }
+ }
+ }
+ return getStatusMethod;
+ }
+
+ private static volatile io.grpc.MethodDescriptor getGetSubscriptionUpdateMethod;
+
+ @io.grpc.stub.annotations.RpcMethod(
+ fullMethodName = SERVICE_NAME + '/' + "GetSubscriptionUpdate",
+ requestType = pb.ReplicationOuterClass.Subscription.class,
+ responseType = pb.ReplicationOuterClass.SubscriptionUpdate.class,
+ methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
+ public static io.grpc.MethodDescriptor getGetSubscriptionUpdateMethod() {
+ io.grpc.MethodDescriptor getGetSubscriptionUpdateMethod;
+ if ((getGetSubscriptionUpdateMethod = replicatorGrpc.getGetSubscriptionUpdateMethod) == null) {
+ synchronized (replicatorGrpc.class) {
+ if ((getGetSubscriptionUpdateMethod = replicatorGrpc.getGetSubscriptionUpdateMethod) == null) {
+ replicatorGrpc.getGetSubscriptionUpdateMethod = getGetSubscriptionUpdateMethod =
+ io.grpc.MethodDescriptor.newBuilder()
+ .setType(io.grpc.MethodDescriptor.MethodType.UNARY)
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetSubscriptionUpdate"))
+ .setSampledToLocalTracing(true)
+ .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.Subscription.getDefaultInstance()))
+ .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.SubscriptionUpdate.getDefaultInstance()))
+ .setSchemaDescriptor(new replicatorMethodDescriptorSupplier("GetSubscriptionUpdate"))
+ .build();
+ }
+ }
+ }
+ return getGetSubscriptionUpdateMethod;
+ }
+
+ private static volatile io.grpc.MethodDescriptor getSubmitReplicationMethod;
+
+ @io.grpc.stub.annotations.RpcMethod(
+ fullMethodName = SERVICE_NAME + '/' + "SubmitReplication",
+ requestType = pb.ReplicationOuterClass.SignedSubscription.class,
+ responseType = pb.ReplicationOuterClass.ReplicationStatus.class,
+ methodType = io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ public static io.grpc.MethodDescriptor getSubmitReplicationMethod() {
+ io.grpc.MethodDescriptor getSubmitReplicationMethod;
+ if ((getSubmitReplicationMethod = replicatorGrpc.getSubmitReplicationMethod) == null) {
+ synchronized (replicatorGrpc.class) {
+ if ((getSubmitReplicationMethod = replicatorGrpc.getSubmitReplicationMethod) == null) {
+ replicatorGrpc.getSubmitReplicationMethod = getSubmitReplicationMethod =
+ io.grpc.MethodDescriptor.newBuilder()
+ .setType(io.grpc.MethodDescriptor.MethodType.SERVER_STREAMING)
+ .setFullMethodName(generateFullMethodName(SERVICE_NAME, "SubmitReplication"))
+ .setSampledToLocalTracing(true)
+ .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.SignedSubscription.getDefaultInstance()))
+ .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
+ pb.ReplicationOuterClass.ReplicationStatus.getDefaultInstance()))
+ .setSchemaDescriptor(new replicatorMethodDescriptorSupplier("SubmitReplication"))
+ .build();
+ }
+ }
+ }
+ return getSubmitReplicationMethod;
+ }
+
+ /**
+ * Creates a new async stub that supports all call types for the service
+ */
+ public static replicatorStub newStub(io.grpc.Channel channel) {
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public replicatorStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorStub(channel, callOptions);
+ }
+ };
+ return replicatorStub.newStub(factory, channel);
+ }
+
+ /**
+ * Creates a new blocking-style stub that supports unary and streaming output calls on the service
+ */
+ public static replicatorBlockingStub newBlockingStub(
+ io.grpc.Channel channel) {
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public replicatorBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorBlockingStub(channel, callOptions);
+ }
+ };
+ return replicatorBlockingStub.newStub(factory, channel);
+ }
+
+ /**
+ * Creates a new ListenableFuture-style stub that supports unary calls on the service
+ */
+ public static replicatorFutureStub newFutureStub(
+ io.grpc.Channel channel) {
+ io.grpc.stub.AbstractStub.StubFactory factory =
+ new io.grpc.stub.AbstractStub.StubFactory() {
+ @java.lang.Override
+ public replicatorFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorFutureStub(channel, callOptions);
+ }
+ };
+ return replicatorFutureStub.newStub(factory, channel);
+ }
+
+ /**
+ *
+ * The replicator provides replication services.
+ *
+ */
+ public static abstract class replicatorImplBase implements io.grpc.BindableService {
+
+ /**
+ *
+ * Add is used to add a replication to this server, changing it's status from reserved to active.
+ *
+ */
+ public void add(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncUnimplementedUnaryCall(getAddMethod(), responseObserver);
+ }
+
+ /**
+ *
+ * Status returns an updating stream of the replication status on the server.
+ *
+ */
+ public void status(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncUnimplementedUnaryCall(getStatusMethod(), responseObserver);
+ }
+
+ /**
+ *
+ * GetSubscriptionUpdate returns the latest version of subscribed replication
+ *
+ */
+ public void getSubscriptionUpdate(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncUnimplementedUnaryCall(getGetSubscriptionUpdateMethod(), responseObserver);
+ }
+
+ /**
+ *
+ * SubmitReplication is used by client agents to start replications, after they
+ * have uploaded the files and retrieved the cid, and collected servers to replicate too.
+ *
+ */
+ public void submitReplication(pb.ReplicationOuterClass.SignedSubscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncUnimplementedUnaryCall(getSubmitReplicationMethod(), responseObserver);
+ }
+
+ @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
+ return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
+ .addMethod(
+ getAddMethod(),
+ asyncServerStreamingCall(
+ new MethodHandlers<
+ pb.ReplicationOuterClass.Subscription,
+ pb.ReplicationOuterClass.ReplicationStatus>(
+ this, METHODID_ADD)))
+ .addMethod(
+ getStatusMethod(),
+ asyncServerStreamingCall(
+ new MethodHandlers<
+ pb.ReplicationOuterClass.Subscription,
+ pb.ReplicationOuterClass.ReplicationStatus>(
+ this, METHODID_STATUS)))
+ .addMethod(
+ getGetSubscriptionUpdateMethod(),
+ asyncUnaryCall(
+ new MethodHandlers<
+ pb.ReplicationOuterClass.Subscription,
+ pb.ReplicationOuterClass.SubscriptionUpdate>(
+ this, METHODID_GET_SUBSCRIPTION_UPDATE)))
+ .addMethod(
+ getSubmitReplicationMethod(),
+ asyncServerStreamingCall(
+ new MethodHandlers<
+ pb.ReplicationOuterClass.SignedSubscription,
+ pb.ReplicationOuterClass.ReplicationStatus>(
+ this, METHODID_SUBMIT_REPLICATION)))
+ .build();
+ }
+ }
+
+ /**
+ *
+ * The replicator provides replication services.
+ *
+ */
+ public static final class replicatorStub extends io.grpc.stub.AbstractAsyncStub {
+ private replicatorStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ super(channel, callOptions);
+ }
+
+ @java.lang.Override
+ protected replicatorStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorStub(channel, callOptions);
+ }
+
+ /**
+ *
+ * Add is used to add a replication to this server, changing it's status from reserved to active.
+ *
+ */
+ public void add(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncServerStreamingCall(
+ getChannel().newCall(getAddMethod(), getCallOptions()), request, responseObserver);
+ }
+
+ /**
+ *
+ * Status returns an updating stream of the replication status on the server.
+ *
+ */
+ public void status(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncServerStreamingCall(
+ getChannel().newCall(getStatusMethod(), getCallOptions()), request, responseObserver);
+ }
+
+ /**
+ *
+ * GetSubscriptionUpdate returns the latest version of subscribed replication
+ *
+ */
+ public void getSubscriptionUpdate(pb.ReplicationOuterClass.Subscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncUnaryCall(
+ getChannel().newCall(getGetSubscriptionUpdateMethod(), getCallOptions()), request, responseObserver);
+ }
+
+ /**
+ *
+ * SubmitReplication is used by client agents to start replications, after they
+ * have uploaded the files and retrieved the cid, and collected servers to replicate too.
+ *
+ */
+ public void submitReplication(pb.ReplicationOuterClass.SignedSubscription request,
+ io.grpc.stub.StreamObserver responseObserver) {
+ asyncServerStreamingCall(
+ getChannel().newCall(getSubmitReplicationMethod(), getCallOptions()), request, responseObserver);
+ }
+ }
+
+ /**
+ *
+ * The replicator provides replication services.
+ *
+ */
+ public static final class replicatorBlockingStub extends io.grpc.stub.AbstractBlockingStub {
+ private replicatorBlockingStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ super(channel, callOptions);
+ }
+
+ @java.lang.Override
+ protected replicatorBlockingStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorBlockingStub(channel, callOptions);
+ }
+
+ /**
+ *
+ * Add is used to add a replication to this server, changing it's status from reserved to active.
+ *
+ */
+ public java.util.Iterator add(
+ pb.ReplicationOuterClass.Subscription request) {
+ return blockingServerStreamingCall(
+ getChannel(), getAddMethod(), getCallOptions(), request);
+ }
+
+ /**
+ *
+ * Status returns an updating stream of the replication status on the server.
+ *
+ */
+ public java.util.Iterator status(
+ pb.ReplicationOuterClass.Subscription request) {
+ return blockingServerStreamingCall(
+ getChannel(), getStatusMethod(), getCallOptions(), request);
+ }
+
+ /**
+ *
+ * GetSubscriptionUpdate returns the latest version of subscribed replication
+ *
+ */
+ public pb.ReplicationOuterClass.SubscriptionUpdate getSubscriptionUpdate(pb.ReplicationOuterClass.Subscription request) {
+ return blockingUnaryCall(
+ getChannel(), getGetSubscriptionUpdateMethod(), getCallOptions(), request);
+ }
+
+ /**
+ *
+ * SubmitReplication is used by client agents to start replications, after they
+ * have uploaded the files and retrieved the cid, and collected servers to replicate too.
+ *
+ */
+ public java.util.Iterator submitReplication(
+ pb.ReplicationOuterClass.SignedSubscription request) {
+ return blockingServerStreamingCall(
+ getChannel(), getSubmitReplicationMethod(), getCallOptions(), request);
+ }
+ }
+
+ /**
+ *
+ * The replicator provides replication services.
+ *
+ */
+ public static final class replicatorFutureStub extends io.grpc.stub.AbstractFutureStub {
+ private replicatorFutureStub(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ super(channel, callOptions);
+ }
+
+ @java.lang.Override
+ protected replicatorFutureStub build(
+ io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
+ return new replicatorFutureStub(channel, callOptions);
+ }
+
+ /**
+ *
+ * GetSubscriptionUpdate returns the latest version of subscribed replication
+ *
+ */
+ public com.google.common.util.concurrent.ListenableFuture getSubscriptionUpdate(
+ pb.ReplicationOuterClass.Subscription request) {
+ return futureUnaryCall(
+ getChannel().newCall(getGetSubscriptionUpdateMethod(), getCallOptions()), request);
+ }
+ }
+
+ private static final int METHODID_ADD = 0;
+ private static final int METHODID_STATUS = 1;
+ private static final int METHODID_GET_SUBSCRIPTION_UPDATE = 2;
+ private static final int METHODID_SUBMIT_REPLICATION = 3;
+
+ private static final class MethodHandlers implements
+ io.grpc.stub.ServerCalls.UnaryMethod,
+ io.grpc.stub.ServerCalls.ServerStreamingMethod,
+ io.grpc.stub.ServerCalls.ClientStreamingMethod,
+ io.grpc.stub.ServerCalls.BidiStreamingMethod {
+ private final replicatorImplBase serviceImpl;
+ private final int methodId;
+
+ MethodHandlers(replicatorImplBase serviceImpl, int methodId) {
+ this.serviceImpl = serviceImpl;
+ this.methodId = methodId;
+ }
+
+ @java.lang.Override
+ @java.lang.SuppressWarnings("unchecked")
+ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) {
+ switch (methodId) {
+ case METHODID_ADD:
+ serviceImpl.add((pb.ReplicationOuterClass.Subscription) request,
+ (io.grpc.stub.StreamObserver) responseObserver);
+ break;
+ case METHODID_STATUS:
+ serviceImpl.status((pb.ReplicationOuterClass.Subscription) request,
+ (io.grpc.stub.StreamObserver) responseObserver);
+ break;
+ case METHODID_GET_SUBSCRIPTION_UPDATE:
+ serviceImpl.getSubscriptionUpdate((pb.ReplicationOuterClass.Subscription) request,
+ (io.grpc.stub.StreamObserver) responseObserver);
+ break;
+ case METHODID_SUBMIT_REPLICATION:
+ serviceImpl.submitReplication((pb.ReplicationOuterClass.SignedSubscription) request,
+ (io.grpc.stub.StreamObserver) responseObserver);
+ break;
+ default:
+ throw new AssertionError();
+ }
+ }
+
+ @java.lang.Override
+ @java.lang.SuppressWarnings("unchecked")
+ public io.grpc.stub.StreamObserver invoke(
+ io.grpc.stub.StreamObserver responseObserver) {
+ switch (methodId) {
+ default:
+ throw new AssertionError();
+ }
+ }
+ }
+
+ private static abstract class replicatorBaseDescriptorSupplier
+ implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
+ replicatorBaseDescriptorSupplier() {}
+
+ @java.lang.Override
+ public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
+ return pb.ReplicationOuterClass.getDescriptor();
+ }
+
+ @java.lang.Override
+ public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() {
+ return getFileDescriptor().findServiceByName("replicator");
+ }
+ }
+
+ private static final class replicatorFileDescriptorSupplier
+ extends replicatorBaseDescriptorSupplier {
+ replicatorFileDescriptorSupplier() {}
+ }
+
+ private static final class replicatorMethodDescriptorSupplier
+ extends replicatorBaseDescriptorSupplier
+ implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
+ private final String methodName;
+
+ replicatorMethodDescriptorSupplier(String methodName) {
+ this.methodName = methodName;
+ }
+
+ @java.lang.Override
+ public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() {
+ return getServiceDescriptor().findMethodByName(methodName);
+ }
+ }
+
+ private static volatile io.grpc.ServiceDescriptor serviceDescriptor;
+
+ public static io.grpc.ServiceDescriptor getServiceDescriptor() {
+ io.grpc.ServiceDescriptor result = serviceDescriptor;
+ if (result == null) {
+ synchronized (replicatorGrpc.class) {
+ result = serviceDescriptor;
+ if (result == null) {
+ serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
+ .setSchemaDescriptor(new replicatorFileDescriptorSupplier())
+ .addMethod(getAddMethod())
+ .addMethod(getStatusMethod())
+ .addMethod(getGetSubscriptionUpdateMethod())
+ .addMethod(getSubmitReplicationMethod())
+ .build();
+ }
+ }
+ }
+ return result;
+ }
+}
diff --git a/js/admin_grpc_pb.js b/js/admin_grpc_pb.js
index 3a30924..b092e3f 100644
--- a/js/admin_grpc_pb.js
+++ b/js/admin_grpc_pb.js
@@ -52,7 +52,7 @@ function deserialize_pb_RefCountResponse(buffer_arg) {
// AdminAPI facilitates administrative management of TemporalX via a localhost gRPC API
var AdminAPIService = exports.AdminAPIService = {
// ManageGC is used to manage TemporalX's garbage collection process
- manageGC: {
+manageGC: {
path: '/pb.AdminAPI/ManageGC',
requestStream: false,
responseStream: false,
@@ -64,7 +64,7 @@ var AdminAPIService = exports.AdminAPIService = {
responseDeserialize: deserialize_pb_ManageGCResponse,
},
// RefCount is used to analyze the counter store and pull reference count information
- refCount: {
+refCount: {
path: '/pb.AdminAPI/RefCount',
requestStream: false,
responseStream: false,
diff --git a/js/file_grpc_pb.js b/js/file_grpc_pb.js
index 80d91cd..634fab0 100644
--- a/js/file_grpc_pb.js
+++ b/js/file_grpc_pb.js
@@ -53,7 +53,7 @@ function deserialize_pb_UploadRequest(buffer_arg) {
// FileAPI provides a gRPC api to upload/download files as UnixFS objects
var FileAPIService = exports.FileAPIService = {
// UploadFile allows uploading a file as a UnixFS object (equivalent to ipfs add)
- uploadFile: {
+uploadFile: {
path: '/pb.FileAPI/UploadFile',
requestStream: true,
responseStream: false,
@@ -65,7 +65,7 @@ var FileAPIService = exports.FileAPIService = {
responseDeserialize: deserialize_pb_PutResponse,
},
// DownloadFile allows downloading a UnixFS object (equivalent to ipfs get)
- downloadFile: {
+downloadFile: {
path: '/pb.FileAPI/DownloadFile',
requestStream: false,
responseStream: true,
diff --git a/js/node_grpc_pb.js b/js/node_grpc_pb.js
index 5c39b2c..c7fcca1 100644
--- a/js/node_grpc_pb.js
+++ b/js/node_grpc_pb.js
@@ -163,7 +163,7 @@ function deserialize_pb_PersistResponse(buffer_arg) {
// NodeAPI provide an API to control the underlying custom ipfs node
var NodeAPIService = exports.NodeAPIService = {
// ConnMgmt provides control over libp2p connections
- connMgmt: {
+connMgmt: {
path: '/pb.NodeAPI/ConnMgmt',
requestStream: false,
responseStream: false,
@@ -175,7 +175,7 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_ConnMgmtResponse,
},
// Extras provide control over node extras capabilities
- extras: {
+extras: {
path: '/pb.NodeAPI/Extras',
requestStream: false,
responseStream: false,
@@ -187,9 +187,9 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_Empty,
},
// P2P allows control of generalized p2p streams for tcp/udp based protocol.
- // By using this RPC, we can tunnel traffic similar to ssh tunneling
- // except using libp2p as the transport layer, and and tcp/udp port.
- p2P: {
+// By using this RPC, we can tunnel traffic similar to ssh tunneling
+// except using libp2p as the transport layer, and and tcp/udp port.
+p2P: {
path: '/pb.NodeAPI/P2P',
requestStream: false,
responseStream: false,
@@ -201,7 +201,7 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_P2PResponse,
},
// Blockstore allows low-level management of the underlying blockstore
- blockstore: {
+blockstore: {
path: '/pb.NodeAPI/Blockstore',
requestStream: false,
responseStream: false,
@@ -213,7 +213,7 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_BlockstoreResponse,
},
// Dag is a unidirectional rpc allowing manipulation of low-level ipld objects
- dag: {
+dag: {
path: '/pb.NodeAPI/Dag',
requestStream: false,
responseStream: false,
@@ -225,7 +225,7 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_DagResponse,
},
// Keystore is a unidirectional RPC allowing management of ipfs keystores
- keystore: {
+keystore: {
path: '/pb.NodeAPI/Keystore',
requestStream: false,
responseStream: false,
@@ -237,7 +237,7 @@ var NodeAPIService = exports.NodeAPIService = {
responseDeserialize: deserialize_pb_KeystoreResponse,
},
// Persist is used to retrieve data from the network and make it available locally
- persist: {
+persist: {
path: '/pb.NodeAPI/Persist',
requestStream: false,
responseStream: false,
diff --git a/js/pubsub_grpc_pb.js b/js/pubsub_grpc_pb.js
index 96bfb0e..dfc19c5 100644
--- a/js/pubsub_grpc_pb.js
+++ b/js/pubsub_grpc_pb.js
@@ -31,8 +31,8 @@ function deserialize_pb_PubSubResponse(buffer_arg) {
// `ipfs pubsub` subset of commands.
var PubSubAPIService = exports.PubSubAPIService = {
// PubSub allows controlling libp2p pubsub topics and subscriptions using
- // a bidirectional streaming API
- pubSub: {
+// a bidirectional streaming API
+pubSub: {
path: '/pb.PubSubAPI/PubSub',
requestStream: true,
responseStream: true,
diff --git a/js/replication_grpc_pb.js b/js/replication_grpc_pb.js
new file mode 100644
index 0000000..65b57f8
--- /dev/null
+++ b/js/replication_grpc_pb.js
@@ -0,0 +1,105 @@
+// GENERATED CODE -- DO NOT EDIT!
+
+'use strict';
+var grpc = require('grpc');
+var replication_pb = require('./replication_pb.js');
+
+function serialize_pb_ReplicationStatus(arg) {
+ if (!(arg instanceof replication_pb.ReplicationStatus)) {
+ throw new Error('Expected argument of type pb.ReplicationStatus');
+ }
+ return Buffer.from(arg.serializeBinary());
+}
+
+function deserialize_pb_ReplicationStatus(buffer_arg) {
+ return replication_pb.ReplicationStatus.deserializeBinary(new Uint8Array(buffer_arg));
+}
+
+function serialize_pb_SignedSubscription(arg) {
+ if (!(arg instanceof replication_pb.SignedSubscription)) {
+ throw new Error('Expected argument of type pb.SignedSubscription');
+ }
+ return Buffer.from(arg.serializeBinary());
+}
+
+function deserialize_pb_SignedSubscription(buffer_arg) {
+ return replication_pb.SignedSubscription.deserializeBinary(new Uint8Array(buffer_arg));
+}
+
+function serialize_pb_Subscription(arg) {
+ if (!(arg instanceof replication_pb.Subscription)) {
+ throw new Error('Expected argument of type pb.Subscription');
+ }
+ return Buffer.from(arg.serializeBinary());
+}
+
+function deserialize_pb_Subscription(buffer_arg) {
+ return replication_pb.Subscription.deserializeBinary(new Uint8Array(buffer_arg));
+}
+
+function serialize_pb_SubscriptionUpdate(arg) {
+ if (!(arg instanceof replication_pb.SubscriptionUpdate)) {
+ throw new Error('Expected argument of type pb.SubscriptionUpdate');
+ }
+ return Buffer.from(arg.serializeBinary());
+}
+
+function deserialize_pb_SubscriptionUpdate(buffer_arg) {
+ return replication_pb.SubscriptionUpdate.deserializeBinary(new Uint8Array(buffer_arg));
+}
+
+
+// The replicator provides replication services.
+var replicatorService = exports.replicatorService = {
+ // Add is used to add a replication to this server, changing it's status from reserved to active.
+add: {
+ path: '/pb.replicator/Add',
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.ReplicationStatus,
+ requestSerialize: serialize_pb_Subscription,
+ requestDeserialize: deserialize_pb_Subscription,
+ responseSerialize: serialize_pb_ReplicationStatus,
+ responseDeserialize: deserialize_pb_ReplicationStatus,
+ },
+ // Status returns an updating stream of the replication status on the server.
+status: {
+ path: '/pb.replicator/Status',
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.ReplicationStatus,
+ requestSerialize: serialize_pb_Subscription,
+ requestDeserialize: deserialize_pb_Subscription,
+ responseSerialize: serialize_pb_ReplicationStatus,
+ responseDeserialize: deserialize_pb_ReplicationStatus,
+ },
+ // GetSubscriptionUpdate returns the latest version of subscribed replication
+getSubscriptionUpdate: {
+ path: '/pb.replicator/GetSubscriptionUpdate',
+ requestStream: false,
+ responseStream: false,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.SubscriptionUpdate,
+ requestSerialize: serialize_pb_Subscription,
+ requestDeserialize: deserialize_pb_Subscription,
+ responseSerialize: serialize_pb_SubscriptionUpdate,
+ responseDeserialize: deserialize_pb_SubscriptionUpdate,
+ },
+ // SubmitReplication is used by client agents to start replications, after they
+// have uploaded the files and retrieved the cid, and collected servers to replicate too.
+submitReplication: {
+ path: '/pb.replicator/SubmitReplication',
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.SignedSubscription,
+ responseType: replication_pb.ReplicationStatus,
+ requestSerialize: serialize_pb_SignedSubscription,
+ requestDeserialize: deserialize_pb_SignedSubscription,
+ responseSerialize: serialize_pb_ReplicationStatus,
+ responseDeserialize: deserialize_pb_ReplicationStatus,
+ },
+};
+
+exports.replicatorClient = grpc.makeGenericClientConstructor(replicatorService);
diff --git a/js/replication_pb.js b/js/replication_pb.js
new file mode 100644
index 0000000..b7be4a2
--- /dev/null
+++ b/js/replication_pb.js
@@ -0,0 +1,1811 @@
+// source: replication.proto
+/**
+ * @fileoverview
+ * @enhanceable
+ * @suppress {messageConventions} JS Compiler reports an error if a variable or
+ * field starts with 'MSG_' and isn't a translatable message.
+ * @public
+ */
+// GENERATED CODE -- DO NOT EDIT!
+
+var jspb = require('google-protobuf');
+var goog = jspb;
+var global = Function('return this')();
+
+goog.exportSymbol('proto.pb.AddrInfo', null, global);
+goog.exportSymbol('proto.pb.Replication', null, global);
+goog.exportSymbol('proto.pb.ReplicationStatus', null, global);
+goog.exportSymbol('proto.pb.ServerSource', null, global);
+goog.exportSymbol('proto.pb.SignedSubscription', null, global);
+goog.exportSymbol('proto.pb.Subscription', null, global);
+goog.exportSymbol('proto.pb.SubscriptionUpdate', null, global);
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.Replication = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.pb.Replication.repeatedFields_, null);
+};
+goog.inherits(proto.pb.Replication, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.Replication.displayName = 'proto.pb.Replication';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.ServerSource = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.pb.ServerSource, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.ServerSource.displayName = 'proto.pb.ServerSource';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.AddrInfo = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, proto.pb.AddrInfo.repeatedFields_, null);
+};
+goog.inherits(proto.pb.AddrInfo, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.AddrInfo.displayName = 'proto.pb.AddrInfo';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.Subscription = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.pb.Subscription, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.Subscription.displayName = 'proto.pb.Subscription';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.ReplicationStatus = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.pb.ReplicationStatus, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.ReplicationStatus.displayName = 'proto.pb.ReplicationStatus';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.SubscriptionUpdate = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.pb.SubscriptionUpdate, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.SubscriptionUpdate.displayName = 'proto.pb.SubscriptionUpdate';
+}
+/**
+ * Generated by JsPbCodeGenerator.
+ * @param {Array=} opt_data Optional initial data array, typically from a
+ * server response, or constructed directly in Javascript. The array is used
+ * in place and becomes part of the constructed object. It is not cloned.
+ * If no data is provided, the constructed object will be empty, but still
+ * valid.
+ * @extends {jspb.Message}
+ * @constructor
+ */
+proto.pb.SignedSubscription = function(opt_data) {
+ jspb.Message.initialize(this, opt_data, 0, -1, null, null);
+};
+goog.inherits(proto.pb.SignedSubscription, jspb.Message);
+if (goog.DEBUG && !COMPILED) {
+ /**
+ * @public
+ * @override
+ */
+ proto.pb.SignedSubscription.displayName = 'proto.pb.SignedSubscription';
+}
+
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.pb.Replication.repeatedFields_ = [2,3];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.Replication.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.Replication.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.Replication} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.Replication.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ header: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ cidsBytesList: msg.getCidsBytesList_asB64(),
+ serversList: jspb.Message.toObjectList(msg.getServersList(),
+ proto.pb.ServerSource.toObject, includeInstance),
+ replicationFactor: jspb.Message.getFieldWithDefault(msg, 4, 0),
+ refreshIntervalSeconds: jspb.Message.getFieldWithDefault(msg, 5, 0),
+ serverDownDelaySeconds: jspb.Message.getFieldWithDefault(msg, 6, 0)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.Replication}
+ */
+proto.pb.Replication.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.Replication;
+ return proto.pb.Replication.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.Replication} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.Replication}
+ */
+proto.pb.Replication.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setHeader(value);
+ break;
+ case 2:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.addCidsBytes(value);
+ break;
+ case 3:
+ var value = new proto.pb.ServerSource;
+ reader.readMessage(value,proto.pb.ServerSource.deserializeBinaryFromReader);
+ msg.addServers(value);
+ break;
+ case 4:
+ var value = /** @type {number} */ (reader.readInt32());
+ msg.setReplicationFactor(value);
+ break;
+ case 5:
+ var value = /** @type {number} */ (reader.readInt32());
+ msg.setRefreshIntervalSeconds(value);
+ break;
+ case 6:
+ var value = /** @type {number} */ (reader.readInt32());
+ msg.setServerDownDelaySeconds(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.Replication.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.Replication.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.Replication} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.Replication.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getHeader();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getCidsBytesList_asU8();
+ if (f.length > 0) {
+ writer.writeRepeatedBytes(
+ 2,
+ f
+ );
+ }
+ f = message.getServersList();
+ if (f.length > 0) {
+ writer.writeRepeatedMessage(
+ 3,
+ f,
+ proto.pb.ServerSource.serializeBinaryToWriter
+ );
+ }
+ f = message.getReplicationFactor();
+ if (f !== 0) {
+ writer.writeInt32(
+ 4,
+ f
+ );
+ }
+ f = message.getRefreshIntervalSeconds();
+ if (f !== 0) {
+ writer.writeInt32(
+ 5,
+ f
+ );
+ }
+ f = message.getServerDownDelaySeconds();
+ if (f !== 0) {
+ writer.writeInt32(
+ 6,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional string header = 1;
+ * @return {string}
+ */
+proto.pb.Replication.prototype.getHeader = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/**
+ * @param {string} value
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.setHeader = function(value) {
+ return jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * repeated bytes cids_bytes = 2;
+ * @return {!(Array|Array)}
+ */
+proto.pb.Replication.prototype.getCidsBytesList = function() {
+ return /** @type {!(Array|Array)} */ (jspb.Message.getRepeatedField(this, 2));
+};
+
+
+/**
+ * repeated bytes cids_bytes = 2;
+ * This is a type-conversion wrapper around `getCidsBytesList()`
+ * @return {!Array}
+ */
+proto.pb.Replication.prototype.getCidsBytesList_asB64 = function() {
+ return /** @type {!Array} */ (jspb.Message.bytesListAsB64(
+ this.getCidsBytesList()));
+};
+
+
+/**
+ * repeated bytes cids_bytes = 2;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getCidsBytesList()`
+ * @return {!Array}
+ */
+proto.pb.Replication.prototype.getCidsBytesList_asU8 = function() {
+ return /** @type {!Array} */ (jspb.Message.bytesListAsU8(
+ this.getCidsBytesList()));
+};
+
+
+/**
+ * @param {!(Array|Array)} value
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.setCidsBytesList = function(value) {
+ return jspb.Message.setField(this, 2, value || []);
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @param {number=} opt_index
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.addCidsBytes = function(value, opt_index) {
+ return jspb.Message.addToRepeatedField(this, 2, value, opt_index);
+};
+
+
+/**
+ * Clears the list making it empty but non-null.
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.clearCidsBytesList = function() {
+ return this.setCidsBytesList([]);
+};
+
+
+/**
+ * repeated ServerSource servers = 3;
+ * @return {!Array}
+ */
+proto.pb.Replication.prototype.getServersList = function() {
+ return /** @type{!Array} */ (
+ jspb.Message.getRepeatedWrapperField(this, proto.pb.ServerSource, 3));
+};
+
+
+/**
+ * @param {!Array} value
+ * @return {!proto.pb.Replication} returns this
+*/
+proto.pb.Replication.prototype.setServersList = function(value) {
+ return jspb.Message.setRepeatedWrapperField(this, 3, value);
+};
+
+
+/**
+ * @param {!proto.pb.ServerSource=} opt_value
+ * @param {number=} opt_index
+ * @return {!proto.pb.ServerSource}
+ */
+proto.pb.Replication.prototype.addServers = function(opt_value, opt_index) {
+ return jspb.Message.addToRepeatedWrapperField(this, 3, opt_value, proto.pb.ServerSource, opt_index);
+};
+
+
+/**
+ * Clears the list making it empty but non-null.
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.clearServersList = function() {
+ return this.setServersList([]);
+};
+
+
+/**
+ * optional int32 replication_factor = 4;
+ * @return {number}
+ */
+proto.pb.Replication.prototype.getReplicationFactor = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.setReplicationFactor = function(value) {
+ return jspb.Message.setProto3IntField(this, 4, value);
+};
+
+
+/**
+ * optional int32 refresh_interval_seconds = 5;
+ * @return {number}
+ */
+proto.pb.Replication.prototype.getRefreshIntervalSeconds = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 5, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.setRefreshIntervalSeconds = function(value) {
+ return jspb.Message.setProto3IntField(this, 5, value);
+};
+
+
+/**
+ * optional int32 server_down_delay_seconds = 6;
+ * @return {number}
+ */
+proto.pb.Replication.prototype.getServerDownDelaySeconds = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 6, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.Replication} returns this
+ */
+proto.pb.Replication.prototype.setServerDownDelaySeconds = function(value) {
+ return jspb.Message.setProto3IntField(this, 6, value);
+};
+
+
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.ServerSource.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.ServerSource.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.ServerSource} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.ServerSource.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ addrInfo: (f = msg.getAddrInfo()) && proto.pb.AddrInfo.toObject(includeInstance, f)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.ServerSource}
+ */
+proto.pb.ServerSource.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.ServerSource;
+ return proto.pb.ServerSource.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.ServerSource} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.ServerSource}
+ */
+proto.pb.ServerSource.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new proto.pb.AddrInfo;
+ reader.readMessage(value,proto.pb.AddrInfo.deserializeBinaryFromReader);
+ msg.setAddrInfo(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.ServerSource.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.ServerSource.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.ServerSource} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.ServerSource.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getAddrInfo();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ proto.pb.AddrInfo.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional AddrInfo addr_info = 1;
+ * @return {?proto.pb.AddrInfo}
+ */
+proto.pb.ServerSource.prototype.getAddrInfo = function() {
+ return /** @type{?proto.pb.AddrInfo} */ (
+ jspb.Message.getWrapperField(this, proto.pb.AddrInfo, 1));
+};
+
+
+/**
+ * @param {?proto.pb.AddrInfo|undefined} value
+ * @return {!proto.pb.ServerSource} returns this
+*/
+proto.pb.ServerSource.prototype.setAddrInfo = function(value) {
+ return jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+/**
+ * Clears the message field making it undefined.
+ * @return {!proto.pb.ServerSource} returns this
+ */
+proto.pb.ServerSource.prototype.clearAddrInfo = function() {
+ return this.setAddrInfo(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.pb.ServerSource.prototype.hasAddrInfo = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+
+/**
+ * List of repeated fields within this message type.
+ * @private {!Array}
+ * @const
+ */
+proto.pb.AddrInfo.repeatedFields_ = [2];
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.AddrInfo.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.AddrInfo.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.AddrInfo} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.AddrInfo.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ idBytes: msg.getIdBytes_asB64(),
+ addrsBytesList: msg.getAddrsBytesList_asB64(),
+ grpcPort: jspb.Message.getFieldWithDefault(msg, 3, 0)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.AddrInfo}
+ */
+proto.pb.AddrInfo.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.AddrInfo;
+ return proto.pb.AddrInfo.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.AddrInfo} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.AddrInfo}
+ */
+proto.pb.AddrInfo.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.setIdBytes(value);
+ break;
+ case 2:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.addAddrsBytes(value);
+ break;
+ case 3:
+ var value = /** @type {number} */ (reader.readInt32());
+ msg.setGrpcPort(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.AddrInfo.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.AddrInfo.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.AddrInfo} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.AddrInfo.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getIdBytes_asU8();
+ if (f.length > 0) {
+ writer.writeBytes(
+ 1,
+ f
+ );
+ }
+ f = message.getAddrsBytesList_asU8();
+ if (f.length > 0) {
+ writer.writeRepeatedBytes(
+ 2,
+ f
+ );
+ }
+ f = message.getGrpcPort();
+ if (f !== 0) {
+ writer.writeInt32(
+ 3,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional bytes id_bytes = 1;
+ * @return {!(string|Uint8Array)}
+ */
+proto.pb.AddrInfo.prototype.getIdBytes = function() {
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/**
+ * optional bytes id_bytes = 1;
+ * This is a type-conversion wrapper around `getIdBytes()`
+ * @return {string}
+ */
+proto.pb.AddrInfo.prototype.getIdBytes_asB64 = function() {
+ return /** @type {string} */ (jspb.Message.bytesAsB64(
+ this.getIdBytes()));
+};
+
+
+/**
+ * optional bytes id_bytes = 1;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getIdBytes()`
+ * @return {!Uint8Array}
+ */
+proto.pb.AddrInfo.prototype.getIdBytes_asU8 = function() {
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
+ this.getIdBytes()));
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @return {!proto.pb.AddrInfo} returns this
+ */
+proto.pb.AddrInfo.prototype.setIdBytes = function(value) {
+ return jspb.Message.setProto3BytesField(this, 1, value);
+};
+
+
+/**
+ * repeated bytes addrs_bytes = 2;
+ * @return {!(Array|Array)}
+ */
+proto.pb.AddrInfo.prototype.getAddrsBytesList = function() {
+ return /** @type {!(Array|Array)} */ (jspb.Message.getRepeatedField(this, 2));
+};
+
+
+/**
+ * repeated bytes addrs_bytes = 2;
+ * This is a type-conversion wrapper around `getAddrsBytesList()`
+ * @return {!Array}
+ */
+proto.pb.AddrInfo.prototype.getAddrsBytesList_asB64 = function() {
+ return /** @type {!Array} */ (jspb.Message.bytesListAsB64(
+ this.getAddrsBytesList()));
+};
+
+
+/**
+ * repeated bytes addrs_bytes = 2;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getAddrsBytesList()`
+ * @return {!Array}
+ */
+proto.pb.AddrInfo.prototype.getAddrsBytesList_asU8 = function() {
+ return /** @type {!Array} */ (jspb.Message.bytesListAsU8(
+ this.getAddrsBytesList()));
+};
+
+
+/**
+ * @param {!(Array|Array)} value
+ * @return {!proto.pb.AddrInfo} returns this
+ */
+proto.pb.AddrInfo.prototype.setAddrsBytesList = function(value) {
+ return jspb.Message.setField(this, 2, value || []);
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @param {number=} opt_index
+ * @return {!proto.pb.AddrInfo} returns this
+ */
+proto.pb.AddrInfo.prototype.addAddrsBytes = function(value, opt_index) {
+ return jspb.Message.addToRepeatedField(this, 2, value, opt_index);
+};
+
+
+/**
+ * Clears the list making it empty but non-null.
+ * @return {!proto.pb.AddrInfo} returns this
+ */
+proto.pb.AddrInfo.prototype.clearAddrsBytesList = function() {
+ return this.setAddrsBytesList([]);
+};
+
+
+/**
+ * optional int32 grpc_port = 3;
+ * @return {number}
+ */
+proto.pb.AddrInfo.prototype.getGrpcPort = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.AddrInfo} returns this
+ */
+proto.pb.AddrInfo.prototype.setGrpcPort = function(value) {
+ return jspb.Message.setProto3IntField(this, 3, value);
+};
+
+
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.Subscription.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.Subscription.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.Subscription} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.Subscription.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ topic: jspb.Message.getFieldWithDefault(msg, 1, ""),
+ authorIdBytes: msg.getAuthorIdBytes_asB64(),
+ remove: jspb.Message.getBooleanFieldWithDefault(msg, 3, false)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.Subscription}
+ */
+proto.pb.Subscription.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.Subscription;
+ return proto.pb.Subscription.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.Subscription} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.Subscription}
+ */
+proto.pb.Subscription.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {string} */ (reader.readString());
+ msg.setTopic(value);
+ break;
+ case 2:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.setAuthorIdBytes(value);
+ break;
+ case 3:
+ var value = /** @type {boolean} */ (reader.readBool());
+ msg.setRemove(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.Subscription.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.Subscription.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.Subscription} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.Subscription.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getTopic();
+ if (f.length > 0) {
+ writer.writeString(
+ 1,
+ f
+ );
+ }
+ f = message.getAuthorIdBytes_asU8();
+ if (f.length > 0) {
+ writer.writeBytes(
+ 2,
+ f
+ );
+ }
+ f = message.getRemove();
+ if (f) {
+ writer.writeBool(
+ 3,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional string topic = 1;
+ * @return {string}
+ */
+proto.pb.Subscription.prototype.getTopic = function() {
+ return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 1, ""));
+};
+
+
+/**
+ * @param {string} value
+ * @return {!proto.pb.Subscription} returns this
+ */
+proto.pb.Subscription.prototype.setTopic = function(value) {
+ return jspb.Message.setProto3StringField(this, 1, value);
+};
+
+
+/**
+ * optional bytes author_id_bytes = 2;
+ * @return {!(string|Uint8Array)}
+ */
+proto.pb.Subscription.prototype.getAuthorIdBytes = function() {
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/**
+ * optional bytes author_id_bytes = 2;
+ * This is a type-conversion wrapper around `getAuthorIdBytes()`
+ * @return {string}
+ */
+proto.pb.Subscription.prototype.getAuthorIdBytes_asB64 = function() {
+ return /** @type {string} */ (jspb.Message.bytesAsB64(
+ this.getAuthorIdBytes()));
+};
+
+
+/**
+ * optional bytes author_id_bytes = 2;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getAuthorIdBytes()`
+ * @return {!Uint8Array}
+ */
+proto.pb.Subscription.prototype.getAuthorIdBytes_asU8 = function() {
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
+ this.getAuthorIdBytes()));
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @return {!proto.pb.Subscription} returns this
+ */
+proto.pb.Subscription.prototype.setAuthorIdBytes = function(value) {
+ return jspb.Message.setProto3BytesField(this, 2, value);
+};
+
+
+/**
+ * optional bool remove = 3;
+ * @return {boolean}
+ */
+proto.pb.Subscription.prototype.getRemove = function() {
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 3, false));
+};
+
+
+/**
+ * @param {boolean} value
+ * @return {!proto.pb.Subscription} returns this
+ */
+proto.pb.Subscription.prototype.setRemove = function(value) {
+ return jspb.Message.setProto3BooleanField(this, 3, value);
+};
+
+
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.ReplicationStatus.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.ReplicationStatus.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.ReplicationStatus} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.ReplicationStatus.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ ok: jspb.Message.getBooleanFieldWithDefault(msg, 1, false),
+ isActive: jspb.Message.getBooleanFieldWithDefault(msg, 2, false),
+ currentVersion: jspb.Message.getFieldWithDefault(msg, 3, 0),
+ targetVersion: jspb.Message.getFieldWithDefault(msg, 4, 0)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.ReplicationStatus}
+ */
+proto.pb.ReplicationStatus.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.ReplicationStatus;
+ return proto.pb.ReplicationStatus.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.ReplicationStatus} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.ReplicationStatus}
+ */
+proto.pb.ReplicationStatus.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {boolean} */ (reader.readBool());
+ msg.setOk(value);
+ break;
+ case 2:
+ var value = /** @type {boolean} */ (reader.readBool());
+ msg.setIsActive(value);
+ break;
+ case 3:
+ var value = /** @type {number} */ (reader.readInt64());
+ msg.setCurrentVersion(value);
+ break;
+ case 4:
+ var value = /** @type {number} */ (reader.readInt64());
+ msg.setTargetVersion(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.ReplicationStatus.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.ReplicationStatus.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.ReplicationStatus} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.ReplicationStatus.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getOk();
+ if (f) {
+ writer.writeBool(
+ 1,
+ f
+ );
+ }
+ f = message.getIsActive();
+ if (f) {
+ writer.writeBool(
+ 2,
+ f
+ );
+ }
+ f = message.getCurrentVersion();
+ if (f !== 0) {
+ writer.writeInt64(
+ 3,
+ f
+ );
+ }
+ f = message.getTargetVersion();
+ if (f !== 0) {
+ writer.writeInt64(
+ 4,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional bool ok = 1;
+ * @return {boolean}
+ */
+proto.pb.ReplicationStatus.prototype.getOk = function() {
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 1, false));
+};
+
+
+/**
+ * @param {boolean} value
+ * @return {!proto.pb.ReplicationStatus} returns this
+ */
+proto.pb.ReplicationStatus.prototype.setOk = function(value) {
+ return jspb.Message.setProto3BooleanField(this, 1, value);
+};
+
+
+/**
+ * optional bool is_active = 2;
+ * @return {boolean}
+ */
+proto.pb.ReplicationStatus.prototype.getIsActive = function() {
+ return /** @type {boolean} */ (jspb.Message.getBooleanFieldWithDefault(this, 2, false));
+};
+
+
+/**
+ * @param {boolean} value
+ * @return {!proto.pb.ReplicationStatus} returns this
+ */
+proto.pb.ReplicationStatus.prototype.setIsActive = function(value) {
+ return jspb.Message.setProto3BooleanField(this, 2, value);
+};
+
+
+/**
+ * optional int64 current_version = 3;
+ * @return {number}
+ */
+proto.pb.ReplicationStatus.prototype.getCurrentVersion = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 3, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.ReplicationStatus} returns this
+ */
+proto.pb.ReplicationStatus.prototype.setCurrentVersion = function(value) {
+ return jspb.Message.setProto3IntField(this, 3, value);
+};
+
+
+/**
+ * optional int64 target_version = 4;
+ * @return {number}
+ */
+proto.pb.ReplicationStatus.prototype.getTargetVersion = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 4, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.ReplicationStatus} returns this
+ */
+proto.pb.ReplicationStatus.prototype.setTargetVersion = function(value) {
+ return jspb.Message.setProto3IntField(this, 4, value);
+};
+
+
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.SubscriptionUpdate.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.SubscriptionUpdate.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.SubscriptionUpdate} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.SubscriptionUpdate.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ version: jspb.Message.getFieldWithDefault(msg, 1, 0),
+ replicationBytes: msg.getReplicationBytes_asB64(),
+ signature: msg.getSignature_asB64()
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.SubscriptionUpdate}
+ */
+proto.pb.SubscriptionUpdate.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.SubscriptionUpdate;
+ return proto.pb.SubscriptionUpdate.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.SubscriptionUpdate} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.SubscriptionUpdate}
+ */
+proto.pb.SubscriptionUpdate.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = /** @type {number} */ (reader.readInt64());
+ msg.setVersion(value);
+ break;
+ case 2:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.setReplicationBytes(value);
+ break;
+ case 3:
+ var value = /** @type {!Uint8Array} */ (reader.readBytes());
+ msg.setSignature(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.SubscriptionUpdate.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.SubscriptionUpdate.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.SubscriptionUpdate} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.SubscriptionUpdate.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getVersion();
+ if (f !== 0) {
+ writer.writeInt64(
+ 1,
+ f
+ );
+ }
+ f = message.getReplicationBytes_asU8();
+ if (f.length > 0) {
+ writer.writeBytes(
+ 2,
+ f
+ );
+ }
+ f = message.getSignature_asU8();
+ if (f.length > 0) {
+ writer.writeBytes(
+ 3,
+ f
+ );
+ }
+};
+
+
+/**
+ * optional int64 version = 1;
+ * @return {number}
+ */
+proto.pb.SubscriptionUpdate.prototype.getVersion = function() {
+ return /** @type {number} */ (jspb.Message.getFieldWithDefault(this, 1, 0));
+};
+
+
+/**
+ * @param {number} value
+ * @return {!proto.pb.SubscriptionUpdate} returns this
+ */
+proto.pb.SubscriptionUpdate.prototype.setVersion = function(value) {
+ return jspb.Message.setProto3IntField(this, 1, value);
+};
+
+
+/**
+ * optional bytes replication_bytes = 2;
+ * @return {!(string|Uint8Array)}
+ */
+proto.pb.SubscriptionUpdate.prototype.getReplicationBytes = function() {
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 2, ""));
+};
+
+
+/**
+ * optional bytes replication_bytes = 2;
+ * This is a type-conversion wrapper around `getReplicationBytes()`
+ * @return {string}
+ */
+proto.pb.SubscriptionUpdate.prototype.getReplicationBytes_asB64 = function() {
+ return /** @type {string} */ (jspb.Message.bytesAsB64(
+ this.getReplicationBytes()));
+};
+
+
+/**
+ * optional bytes replication_bytes = 2;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getReplicationBytes()`
+ * @return {!Uint8Array}
+ */
+proto.pb.SubscriptionUpdate.prototype.getReplicationBytes_asU8 = function() {
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
+ this.getReplicationBytes()));
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @return {!proto.pb.SubscriptionUpdate} returns this
+ */
+proto.pb.SubscriptionUpdate.prototype.setReplicationBytes = function(value) {
+ return jspb.Message.setProto3BytesField(this, 2, value);
+};
+
+
+/**
+ * optional bytes signature = 3;
+ * @return {!(string|Uint8Array)}
+ */
+proto.pb.SubscriptionUpdate.prototype.getSignature = function() {
+ return /** @type {!(string|Uint8Array)} */ (jspb.Message.getFieldWithDefault(this, 3, ""));
+};
+
+
+/**
+ * optional bytes signature = 3;
+ * This is a type-conversion wrapper around `getSignature()`
+ * @return {string}
+ */
+proto.pb.SubscriptionUpdate.prototype.getSignature_asB64 = function() {
+ return /** @type {string} */ (jspb.Message.bytesAsB64(
+ this.getSignature()));
+};
+
+
+/**
+ * optional bytes signature = 3;
+ * Note that Uint8Array is not supported on all browsers.
+ * @see http://caniuse.com/Uint8Array
+ * This is a type-conversion wrapper around `getSignature()`
+ * @return {!Uint8Array}
+ */
+proto.pb.SubscriptionUpdate.prototype.getSignature_asU8 = function() {
+ return /** @type {!Uint8Array} */ (jspb.Message.bytesAsU8(
+ this.getSignature()));
+};
+
+
+/**
+ * @param {!(string|Uint8Array)} value
+ * @return {!proto.pb.SubscriptionUpdate} returns this
+ */
+proto.pb.SubscriptionUpdate.prototype.setSignature = function(value) {
+ return jspb.Message.setProto3BytesField(this, 3, value);
+};
+
+
+
+
+
+if (jspb.Message.GENERATE_TO_OBJECT) {
+/**
+ * Creates an object representation of this proto.
+ * Field names that are reserved in JavaScript and will be renamed to pb_name.
+ * Optional fields that are not set will be set to undefined.
+ * To access a reserved field use, foo.pb_, eg, foo.pb_default.
+ * For the list of reserved names please see:
+ * net/proto2/compiler/js/internal/generator.cc#kKeyword.
+ * @param {boolean=} opt_includeInstance Deprecated. whether to include the
+ * JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @return {!Object}
+ */
+proto.pb.SignedSubscription.prototype.toObject = function(opt_includeInstance) {
+ return proto.pb.SignedSubscription.toObject(opt_includeInstance, this);
+};
+
+
+/**
+ * Static version of the {@see toObject} method.
+ * @param {boolean|undefined} includeInstance Deprecated. Whether to include
+ * the JSPB instance for transitional soy proto support:
+ * http://goto/soy-param-migration
+ * @param {!proto.pb.SignedSubscription} msg The msg instance to transform.
+ * @return {!Object}
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.SignedSubscription.toObject = function(includeInstance, msg) {
+ var f, obj = {
+ subPart: (f = msg.getSubPart()) && proto.pb.Subscription.toObject(includeInstance, f),
+ updatePart: (f = msg.getUpdatePart()) && proto.pb.SubscriptionUpdate.toObject(includeInstance, f)
+ };
+
+ if (includeInstance) {
+ obj.$jspbMessageInstance = msg;
+ }
+ return obj;
+};
+}
+
+
+/**
+ * Deserializes binary data (in protobuf wire format).
+ * @param {jspb.ByteSource} bytes The bytes to deserialize.
+ * @return {!proto.pb.SignedSubscription}
+ */
+proto.pb.SignedSubscription.deserializeBinary = function(bytes) {
+ var reader = new jspb.BinaryReader(bytes);
+ var msg = new proto.pb.SignedSubscription;
+ return proto.pb.SignedSubscription.deserializeBinaryFromReader(msg, reader);
+};
+
+
+/**
+ * Deserializes binary data (in protobuf wire format) from the
+ * given reader into the given message object.
+ * @param {!proto.pb.SignedSubscription} msg The message object to deserialize into.
+ * @param {!jspb.BinaryReader} reader The BinaryReader to use.
+ * @return {!proto.pb.SignedSubscription}
+ */
+proto.pb.SignedSubscription.deserializeBinaryFromReader = function(msg, reader) {
+ while (reader.nextField()) {
+ if (reader.isEndGroup()) {
+ break;
+ }
+ var field = reader.getFieldNumber();
+ switch (field) {
+ case 1:
+ var value = new proto.pb.Subscription;
+ reader.readMessage(value,proto.pb.Subscription.deserializeBinaryFromReader);
+ msg.setSubPart(value);
+ break;
+ case 2:
+ var value = new proto.pb.SubscriptionUpdate;
+ reader.readMessage(value,proto.pb.SubscriptionUpdate.deserializeBinaryFromReader);
+ msg.setUpdatePart(value);
+ break;
+ default:
+ reader.skipField();
+ break;
+ }
+ }
+ return msg;
+};
+
+
+/**
+ * Serializes the message to binary data (in protobuf wire format).
+ * @return {!Uint8Array}
+ */
+proto.pb.SignedSubscription.prototype.serializeBinary = function() {
+ var writer = new jspb.BinaryWriter();
+ proto.pb.SignedSubscription.serializeBinaryToWriter(this, writer);
+ return writer.getResultBuffer();
+};
+
+
+/**
+ * Serializes the given message to binary data (in protobuf wire
+ * format), writing to the given BinaryWriter.
+ * @param {!proto.pb.SignedSubscription} message
+ * @param {!jspb.BinaryWriter} writer
+ * @suppress {unusedLocalVariables} f is only used for nested messages
+ */
+proto.pb.SignedSubscription.serializeBinaryToWriter = function(message, writer) {
+ var f = undefined;
+ f = message.getSubPart();
+ if (f != null) {
+ writer.writeMessage(
+ 1,
+ f,
+ proto.pb.Subscription.serializeBinaryToWriter
+ );
+ }
+ f = message.getUpdatePart();
+ if (f != null) {
+ writer.writeMessage(
+ 2,
+ f,
+ proto.pb.SubscriptionUpdate.serializeBinaryToWriter
+ );
+ }
+};
+
+
+/**
+ * optional Subscription sub_part = 1;
+ * @return {?proto.pb.Subscription}
+ */
+proto.pb.SignedSubscription.prototype.getSubPart = function() {
+ return /** @type{?proto.pb.Subscription} */ (
+ jspb.Message.getWrapperField(this, proto.pb.Subscription, 1));
+};
+
+
+/**
+ * @param {?proto.pb.Subscription|undefined} value
+ * @return {!proto.pb.SignedSubscription} returns this
+*/
+proto.pb.SignedSubscription.prototype.setSubPart = function(value) {
+ return jspb.Message.setWrapperField(this, 1, value);
+};
+
+
+/**
+ * Clears the message field making it undefined.
+ * @return {!proto.pb.SignedSubscription} returns this
+ */
+proto.pb.SignedSubscription.prototype.clearSubPart = function() {
+ return this.setSubPart(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.pb.SignedSubscription.prototype.hasSubPart = function() {
+ return jspb.Message.getField(this, 1) != null;
+};
+
+
+/**
+ * optional SubscriptionUpdate update_part = 2;
+ * @return {?proto.pb.SubscriptionUpdate}
+ */
+proto.pb.SignedSubscription.prototype.getUpdatePart = function() {
+ return /** @type{?proto.pb.SubscriptionUpdate} */ (
+ jspb.Message.getWrapperField(this, proto.pb.SubscriptionUpdate, 2));
+};
+
+
+/**
+ * @param {?proto.pb.SubscriptionUpdate|undefined} value
+ * @return {!proto.pb.SignedSubscription} returns this
+*/
+proto.pb.SignedSubscription.prototype.setUpdatePart = function(value) {
+ return jspb.Message.setWrapperField(this, 2, value);
+};
+
+
+/**
+ * Clears the message field making it undefined.
+ * @return {!proto.pb.SignedSubscription} returns this
+ */
+proto.pb.SignedSubscription.prototype.clearUpdatePart = function() {
+ return this.setUpdatePart(undefined);
+};
+
+
+/**
+ * Returns whether this field is set.
+ * @return {boolean}
+ */
+proto.pb.SignedSubscription.prototype.hasUpdatePart = function() {
+ return jspb.Message.getField(this, 2) != null;
+};
+
+
+goog.object.extend(exports, proto.pb);
diff --git a/js/status_grpc_pb.js b/js/status_grpc_pb.js
index 83106ef..8d36595 100644
--- a/js/status_grpc_pb.js
+++ b/js/status_grpc_pb.js
@@ -42,7 +42,7 @@ function deserialize_pb_VersionResponse(buffer_arg) {
// provides utilities to retrieve api status information from
var StatusAPIService = exports.StatusAPIService = {
// Version is used to retrieve api version information
- version: {
+version: {
path: '/pb.StatusAPI/Version',
requestStream: false,
responseStream: false,
@@ -54,7 +54,7 @@ var StatusAPIService = exports.StatusAPIService = {
responseDeserialize: deserialize_pb_VersionResponse,
},
// Status is used to retrieve api status information.
- status: {
+status: {
path: '/pb.StatusAPI/Status',
requestStream: false,
responseStream: false,
diff --git a/py/replication_pb2.py b/py/replication_pb2.py
new file mode 100644
index 0000000..bca1934
--- /dev/null
+++ b/py/replication_pb2.py
@@ -0,0 +1,464 @@
+# -*- coding: utf-8 -*-
+# Generated by the protocol buffer compiler. DO NOT EDIT!
+# source: replication.proto
+
+import sys
+_b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1'))
+from google.protobuf import descriptor as _descriptor
+from google.protobuf import message as _message
+from google.protobuf import reflection as _reflection
+from google.protobuf import symbol_database as _symbol_database
+# @@protoc_insertion_point(imports)
+
+_sym_db = _symbol_database.Default()
+
+
+
+
+DESCRIPTOR = _descriptor.FileDescriptor(
+ name='replication.proto',
+ package='pb',
+ syntax='proto3',
+ serialized_options=None,
+ serialized_pb=_b('\n\x11replication.proto\x12\x02pb\"\xb5\x01\n\x0bReplication\x12\x0e\n\x06header\x18\x01 \x01(\t\x12\x12\n\ncids_bytes\x18\x02 \x03(\x0c\x12!\n\x07servers\x18\x03 \x03(\x0b\x32\x10.pb.ServerSource\x12\x1a\n\x12replication_factor\x18\x04 \x01(\x05\x12 \n\x18refresh_interval_seconds\x18\x05 \x01(\x05\x12!\n\x19server_down_delay_seconds\x18\x06 \x01(\x05\"/\n\x0cServerSource\x12\x1f\n\taddr_info\x18\x01 \x01(\x0b\x32\x0c.pb.AddrInfo\"D\n\x08\x41\x64\x64rInfo\x12\x10\n\x08id_bytes\x18\x01 \x01(\x0c\x12\x13\n\x0b\x61\x64\x64rs_bytes\x18\x02 \x03(\x0c\x12\x11\n\tgrpc_port\x18\x03 \x01(\x05\"F\n\x0cSubscription\x12\r\n\x05topic\x18\x01 \x01(\t\x12\x17\n\x0f\x61uthor_id_bytes\x18\x02 \x01(\x0c\x12\x0e\n\x06remove\x18\x03 \x01(\x08\"c\n\x11ReplicationStatus\x12\n\n\x02ok\x18\x01 \x01(\x08\x12\x11\n\tis_active\x18\x02 \x01(\x08\x12\x17\n\x0f\x63urrent_version\x18\x03 \x01(\x03\x12\x16\n\x0etarget_version\x18\x04 \x01(\x03\"S\n\x12SubscriptionUpdate\x12\x0f\n\x07version\x18\x01 \x01(\x03\x12\x19\n\x11replication_bytes\x18\x02 \x01(\x0c\x12\x11\n\tsignature\x18\x03 \x01(\x0c\"e\n\x12SignedSubscription\x12\"\n\x08sub_part\x18\x01 \x01(\x0b\x32\x10.pb.Subscription\x12+\n\x0bupdate_part\x18\x02 \x01(\x0b\x32\x16.pb.SubscriptionUpdate2\xfc\x01\n\nreplicator\x12\x30\n\x03\x41\x64\x64\x12\x10.pb.Subscription\x1a\x15.pb.ReplicationStatus0\x01\x12\x33\n\x06Status\x12\x10.pb.Subscription\x1a\x15.pb.ReplicationStatus0\x01\x12\x41\n\x15GetSubscriptionUpdate\x12\x10.pb.Subscription\x1a\x16.pb.SubscriptionUpdate\x12\x44\n\x11SubmitReplication\x12\x16.pb.SignedSubscription\x1a\x15.pb.ReplicationStatus0\x01\x62\x06proto3')
+)
+
+
+
+
+_REPLICATION = _descriptor.Descriptor(
+ name='Replication',
+ full_name='pb.Replication',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='header', full_name='pb.Replication.header', index=0,
+ number=1, type=9, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b("").decode('utf-8'),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='cids_bytes', full_name='pb.Replication.cids_bytes', index=1,
+ number=2, type=12, cpp_type=9, label=3,
+ has_default_value=False, default_value=[],
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='servers', full_name='pb.Replication.servers', index=2,
+ number=3, type=11, cpp_type=10, label=3,
+ has_default_value=False, default_value=[],
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='replication_factor', full_name='pb.Replication.replication_factor', index=3,
+ number=4, type=5, cpp_type=1, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='refresh_interval_seconds', full_name='pb.Replication.refresh_interval_seconds', index=4,
+ number=5, type=5, cpp_type=1, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='server_down_delay_seconds', full_name='pb.Replication.server_down_delay_seconds', index=5,
+ number=6, type=5, cpp_type=1, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=26,
+ serialized_end=207,
+)
+
+
+_SERVERSOURCE = _descriptor.Descriptor(
+ name='ServerSource',
+ full_name='pb.ServerSource',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='addr_info', full_name='pb.ServerSource.addr_info', index=0,
+ number=1, type=11, cpp_type=10, label=1,
+ has_default_value=False, default_value=None,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=209,
+ serialized_end=256,
+)
+
+
+_ADDRINFO = _descriptor.Descriptor(
+ name='AddrInfo',
+ full_name='pb.AddrInfo',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='id_bytes', full_name='pb.AddrInfo.id_bytes', index=0,
+ number=1, type=12, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b(""),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='addrs_bytes', full_name='pb.AddrInfo.addrs_bytes', index=1,
+ number=2, type=12, cpp_type=9, label=3,
+ has_default_value=False, default_value=[],
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='grpc_port', full_name='pb.AddrInfo.grpc_port', index=2,
+ number=3, type=5, cpp_type=1, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=258,
+ serialized_end=326,
+)
+
+
+_SUBSCRIPTION = _descriptor.Descriptor(
+ name='Subscription',
+ full_name='pb.Subscription',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='topic', full_name='pb.Subscription.topic', index=0,
+ number=1, type=9, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b("").decode('utf-8'),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='author_id_bytes', full_name='pb.Subscription.author_id_bytes', index=1,
+ number=2, type=12, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b(""),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='remove', full_name='pb.Subscription.remove', index=2,
+ number=3, type=8, cpp_type=7, label=1,
+ has_default_value=False, default_value=False,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=328,
+ serialized_end=398,
+)
+
+
+_REPLICATIONSTATUS = _descriptor.Descriptor(
+ name='ReplicationStatus',
+ full_name='pb.ReplicationStatus',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='ok', full_name='pb.ReplicationStatus.ok', index=0,
+ number=1, type=8, cpp_type=7, label=1,
+ has_default_value=False, default_value=False,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='is_active', full_name='pb.ReplicationStatus.is_active', index=1,
+ number=2, type=8, cpp_type=7, label=1,
+ has_default_value=False, default_value=False,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='current_version', full_name='pb.ReplicationStatus.current_version', index=2,
+ number=3, type=3, cpp_type=2, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='target_version', full_name='pb.ReplicationStatus.target_version', index=3,
+ number=4, type=3, cpp_type=2, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=400,
+ serialized_end=499,
+)
+
+
+_SUBSCRIPTIONUPDATE = _descriptor.Descriptor(
+ name='SubscriptionUpdate',
+ full_name='pb.SubscriptionUpdate',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='version', full_name='pb.SubscriptionUpdate.version', index=0,
+ number=1, type=3, cpp_type=2, label=1,
+ has_default_value=False, default_value=0,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='replication_bytes', full_name='pb.SubscriptionUpdate.replication_bytes', index=1,
+ number=2, type=12, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b(""),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='signature', full_name='pb.SubscriptionUpdate.signature', index=2,
+ number=3, type=12, cpp_type=9, label=1,
+ has_default_value=False, default_value=_b(""),
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=501,
+ serialized_end=584,
+)
+
+
+_SIGNEDSUBSCRIPTION = _descriptor.Descriptor(
+ name='SignedSubscription',
+ full_name='pb.SignedSubscription',
+ filename=None,
+ file=DESCRIPTOR,
+ containing_type=None,
+ fields=[
+ _descriptor.FieldDescriptor(
+ name='sub_part', full_name='pb.SignedSubscription.sub_part', index=0,
+ number=1, type=11, cpp_type=10, label=1,
+ has_default_value=False, default_value=None,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ _descriptor.FieldDescriptor(
+ name='update_part', full_name='pb.SignedSubscription.update_part', index=1,
+ number=2, type=11, cpp_type=10, label=1,
+ has_default_value=False, default_value=None,
+ message_type=None, enum_type=None, containing_type=None,
+ is_extension=False, extension_scope=None,
+ serialized_options=None, file=DESCRIPTOR),
+ ],
+ extensions=[
+ ],
+ nested_types=[],
+ enum_types=[
+ ],
+ serialized_options=None,
+ is_extendable=False,
+ syntax='proto3',
+ extension_ranges=[],
+ oneofs=[
+ ],
+ serialized_start=586,
+ serialized_end=687,
+)
+
+_REPLICATION.fields_by_name['servers'].message_type = _SERVERSOURCE
+_SERVERSOURCE.fields_by_name['addr_info'].message_type = _ADDRINFO
+_SIGNEDSUBSCRIPTION.fields_by_name['sub_part'].message_type = _SUBSCRIPTION
+_SIGNEDSUBSCRIPTION.fields_by_name['update_part'].message_type = _SUBSCRIPTIONUPDATE
+DESCRIPTOR.message_types_by_name['Replication'] = _REPLICATION
+DESCRIPTOR.message_types_by_name['ServerSource'] = _SERVERSOURCE
+DESCRIPTOR.message_types_by_name['AddrInfo'] = _ADDRINFO
+DESCRIPTOR.message_types_by_name['Subscription'] = _SUBSCRIPTION
+DESCRIPTOR.message_types_by_name['ReplicationStatus'] = _REPLICATIONSTATUS
+DESCRIPTOR.message_types_by_name['SubscriptionUpdate'] = _SUBSCRIPTIONUPDATE
+DESCRIPTOR.message_types_by_name['SignedSubscription'] = _SIGNEDSUBSCRIPTION
+_sym_db.RegisterFileDescriptor(DESCRIPTOR)
+
+Replication = _reflection.GeneratedProtocolMessageType('Replication', (_message.Message,), {
+ 'DESCRIPTOR' : _REPLICATION,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.Replication)
+ })
+_sym_db.RegisterMessage(Replication)
+
+ServerSource = _reflection.GeneratedProtocolMessageType('ServerSource', (_message.Message,), {
+ 'DESCRIPTOR' : _SERVERSOURCE,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.ServerSource)
+ })
+_sym_db.RegisterMessage(ServerSource)
+
+AddrInfo = _reflection.GeneratedProtocolMessageType('AddrInfo', (_message.Message,), {
+ 'DESCRIPTOR' : _ADDRINFO,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.AddrInfo)
+ })
+_sym_db.RegisterMessage(AddrInfo)
+
+Subscription = _reflection.GeneratedProtocolMessageType('Subscription', (_message.Message,), {
+ 'DESCRIPTOR' : _SUBSCRIPTION,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.Subscription)
+ })
+_sym_db.RegisterMessage(Subscription)
+
+ReplicationStatus = _reflection.GeneratedProtocolMessageType('ReplicationStatus', (_message.Message,), {
+ 'DESCRIPTOR' : _REPLICATIONSTATUS,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.ReplicationStatus)
+ })
+_sym_db.RegisterMessage(ReplicationStatus)
+
+SubscriptionUpdate = _reflection.GeneratedProtocolMessageType('SubscriptionUpdate', (_message.Message,), {
+ 'DESCRIPTOR' : _SUBSCRIPTIONUPDATE,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.SubscriptionUpdate)
+ })
+_sym_db.RegisterMessage(SubscriptionUpdate)
+
+SignedSubscription = _reflection.GeneratedProtocolMessageType('SignedSubscription', (_message.Message,), {
+ 'DESCRIPTOR' : _SIGNEDSUBSCRIPTION,
+ '__module__' : 'replication_pb2'
+ # @@protoc_insertion_point(class_scope:pb.SignedSubscription)
+ })
+_sym_db.RegisterMessage(SignedSubscription)
+
+
+
+_REPLICATOR = _descriptor.ServiceDescriptor(
+ name='replicator',
+ full_name='pb.replicator',
+ file=DESCRIPTOR,
+ index=0,
+ serialized_options=None,
+ serialized_start=690,
+ serialized_end=942,
+ methods=[
+ _descriptor.MethodDescriptor(
+ name='Add',
+ full_name='pb.replicator.Add',
+ index=0,
+ containing_service=None,
+ input_type=_SUBSCRIPTION,
+ output_type=_REPLICATIONSTATUS,
+ serialized_options=None,
+ ),
+ _descriptor.MethodDescriptor(
+ name='Status',
+ full_name='pb.replicator.Status',
+ index=1,
+ containing_service=None,
+ input_type=_SUBSCRIPTION,
+ output_type=_REPLICATIONSTATUS,
+ serialized_options=None,
+ ),
+ _descriptor.MethodDescriptor(
+ name='GetSubscriptionUpdate',
+ full_name='pb.replicator.GetSubscriptionUpdate',
+ index=2,
+ containing_service=None,
+ input_type=_SUBSCRIPTION,
+ output_type=_SUBSCRIPTIONUPDATE,
+ serialized_options=None,
+ ),
+ _descriptor.MethodDescriptor(
+ name='SubmitReplication',
+ full_name='pb.replicator.SubmitReplication',
+ index=3,
+ containing_service=None,
+ input_type=_SIGNEDSUBSCRIPTION,
+ output_type=_REPLICATIONSTATUS,
+ serialized_options=None,
+ ),
+])
+_sym_db.RegisterServiceDescriptor(_REPLICATOR)
+
+DESCRIPTOR.services_by_name['replicator'] = _REPLICATOR
+
+# @@protoc_insertion_point(module_scope)
diff --git a/py/replication_pb2_grpc.py b/py/replication_pb2_grpc.py
new file mode 100644
index 0000000..abab33e
--- /dev/null
+++ b/py/replication_pb2_grpc.py
@@ -0,0 +1,98 @@
+# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
+import grpc
+
+import replication_pb2 as replication__pb2
+
+
+class replicatorStub(object):
+ """The replicator provides replication services.
+ """
+
+ def __init__(self, channel):
+ """Constructor.
+
+ Args:
+ channel: A grpc.Channel.
+ """
+ self.Add = channel.unary_stream(
+ '/pb.replicator/Add',
+ request_serializer=replication__pb2.Subscription.SerializeToString,
+ response_deserializer=replication__pb2.ReplicationStatus.FromString,
+ )
+ self.Status = channel.unary_stream(
+ '/pb.replicator/Status',
+ request_serializer=replication__pb2.Subscription.SerializeToString,
+ response_deserializer=replication__pb2.ReplicationStatus.FromString,
+ )
+ self.GetSubscriptionUpdate = channel.unary_unary(
+ '/pb.replicator/GetSubscriptionUpdate',
+ request_serializer=replication__pb2.Subscription.SerializeToString,
+ response_deserializer=replication__pb2.SubscriptionUpdate.FromString,
+ )
+ self.SubmitReplication = channel.unary_stream(
+ '/pb.replicator/SubmitReplication',
+ request_serializer=replication__pb2.SignedSubscription.SerializeToString,
+ response_deserializer=replication__pb2.ReplicationStatus.FromString,
+ )
+
+
+class replicatorServicer(object):
+ """The replicator provides replication services.
+ """
+
+ def Add(self, request, context):
+ """Add is used to add a replication to this server, changing it's status from reserved to active.
+ """
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
+ context.set_details('Method not implemented!')
+ raise NotImplementedError('Method not implemented!')
+
+ def Status(self, request, context):
+ """Status returns an updating stream of the replication status on the server.
+ """
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
+ context.set_details('Method not implemented!')
+ raise NotImplementedError('Method not implemented!')
+
+ def GetSubscriptionUpdate(self, request, context):
+ """GetSubscriptionUpdate returns the latest version of subscribed replication
+ """
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
+ context.set_details('Method not implemented!')
+ raise NotImplementedError('Method not implemented!')
+
+ def SubmitReplication(self, request, context):
+ """SubmitReplication is used by client agents to start replications, after they
+ have uploaded the files and retrieved the cid, and collected servers to replicate too.
+ """
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
+ context.set_details('Method not implemented!')
+ raise NotImplementedError('Method not implemented!')
+
+
+def add_replicatorServicer_to_server(servicer, server):
+ rpc_method_handlers = {
+ 'Add': grpc.unary_stream_rpc_method_handler(
+ servicer.Add,
+ request_deserializer=replication__pb2.Subscription.FromString,
+ response_serializer=replication__pb2.ReplicationStatus.SerializeToString,
+ ),
+ 'Status': grpc.unary_stream_rpc_method_handler(
+ servicer.Status,
+ request_deserializer=replication__pb2.Subscription.FromString,
+ response_serializer=replication__pb2.ReplicationStatus.SerializeToString,
+ ),
+ 'GetSubscriptionUpdate': grpc.unary_unary_rpc_method_handler(
+ servicer.GetSubscriptionUpdate,
+ request_deserializer=replication__pb2.Subscription.FromString,
+ response_serializer=replication__pb2.SubscriptionUpdate.SerializeToString,
+ ),
+ 'SubmitReplication': grpc.unary_stream_rpc_method_handler(
+ servicer.SubmitReplication,
+ request_deserializer=replication__pb2.SignedSubscription.FromString,
+ response_serializer=replication__pb2.ReplicationStatus.SerializeToString,
+ ),
+ }
+ generic_handler = grpc.method_handlers_generic_handler(
+ 'pb.replicator', rpc_method_handlers)
+ server.add_generic_rpc_handlers((generic_handler,))
diff --git a/ts/replication_pb.d.ts b/ts/replication_pb.d.ts
new file mode 100644
index 0000000..4409d04
--- /dev/null
+++ b/ts/replication_pb.d.ts
@@ -0,0 +1,229 @@
+// package: pb
+// file: replication.proto
+
+import * as jspb from "google-protobuf";
+
+export class Replication extends jspb.Message {
+ getHeader(): string;
+ setHeader(value: string): void;
+
+ clearCidsBytesList(): void;
+ getCidsBytesList(): Array;
+ getCidsBytesList_asU8(): Array;
+ getCidsBytesList_asB64(): Array;
+ setCidsBytesList(value: Array): void;
+ addCidsBytes(value: Uint8Array | string, index?: number): Uint8Array | string;
+
+ clearServersList(): void;
+ getServersList(): Array;
+ setServersList(value: Array): void;
+ addServers(value?: ServerSource, index?: number): ServerSource;
+
+ getReplicationFactor(): number;
+ setReplicationFactor(value: number): void;
+
+ getRefreshIntervalSeconds(): number;
+ setRefreshIntervalSeconds(value: number): void;
+
+ getServerDownDelaySeconds(): number;
+ setServerDownDelaySeconds(value: number): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): Replication.AsObject;
+ static toObject(includeInstance: boolean, msg: Replication): Replication.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: Replication, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): Replication;
+ static deserializeBinaryFromReader(message: Replication, reader: jspb.BinaryReader): Replication;
+}
+
+export namespace Replication {
+ export type AsObject = {
+ header: string,
+ cidsBytesList: Array,
+ serversList: Array,
+ replicationFactor: number,
+ refreshIntervalSeconds: number,
+ serverDownDelaySeconds: number,
+ }
+}
+
+export class ServerSource extends jspb.Message {
+ hasAddrInfo(): boolean;
+ clearAddrInfo(): void;
+ getAddrInfo(): AddrInfo | undefined;
+ setAddrInfo(value?: AddrInfo): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): ServerSource.AsObject;
+ static toObject(includeInstance: boolean, msg: ServerSource): ServerSource.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: ServerSource, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): ServerSource;
+ static deserializeBinaryFromReader(message: ServerSource, reader: jspb.BinaryReader): ServerSource;
+}
+
+export namespace ServerSource {
+ export type AsObject = {
+ addrInfo?: AddrInfo.AsObject,
+ }
+}
+
+export class AddrInfo extends jspb.Message {
+ getIdBytes(): Uint8Array | string;
+ getIdBytes_asU8(): Uint8Array;
+ getIdBytes_asB64(): string;
+ setIdBytes(value: Uint8Array | string): void;
+
+ clearAddrsBytesList(): void;
+ getAddrsBytesList(): Array;
+ getAddrsBytesList_asU8(): Array;
+ getAddrsBytesList_asB64(): Array;
+ setAddrsBytesList(value: Array): void;
+ addAddrsBytes(value: Uint8Array | string, index?: number): Uint8Array | string;
+
+ getGrpcPort(): number;
+ setGrpcPort(value: number): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): AddrInfo.AsObject;
+ static toObject(includeInstance: boolean, msg: AddrInfo): AddrInfo.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: AddrInfo, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): AddrInfo;
+ static deserializeBinaryFromReader(message: AddrInfo, reader: jspb.BinaryReader): AddrInfo;
+}
+
+export namespace AddrInfo {
+ export type AsObject = {
+ idBytes: Uint8Array | string,
+ addrsBytesList: Array,
+ grpcPort: number,
+ }
+}
+
+export class Subscription extends jspb.Message {
+ getTopic(): string;
+ setTopic(value: string): void;
+
+ getAuthorIdBytes(): Uint8Array | string;
+ getAuthorIdBytes_asU8(): Uint8Array;
+ getAuthorIdBytes_asB64(): string;
+ setAuthorIdBytes(value: Uint8Array | string): void;
+
+ getRemove(): boolean;
+ setRemove(value: boolean): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): Subscription.AsObject;
+ static toObject(includeInstance: boolean, msg: Subscription): Subscription.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: Subscription, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): Subscription;
+ static deserializeBinaryFromReader(message: Subscription, reader: jspb.BinaryReader): Subscription;
+}
+
+export namespace Subscription {
+ export type AsObject = {
+ topic: string,
+ authorIdBytes: Uint8Array | string,
+ remove: boolean,
+ }
+}
+
+export class ReplicationStatus extends jspb.Message {
+ getOk(): boolean;
+ setOk(value: boolean): void;
+
+ getIsActive(): boolean;
+ setIsActive(value: boolean): void;
+
+ getCurrentVersion(): number;
+ setCurrentVersion(value: number): void;
+
+ getTargetVersion(): number;
+ setTargetVersion(value: number): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): ReplicationStatus.AsObject;
+ static toObject(includeInstance: boolean, msg: ReplicationStatus): ReplicationStatus.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: ReplicationStatus, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): ReplicationStatus;
+ static deserializeBinaryFromReader(message: ReplicationStatus, reader: jspb.BinaryReader): ReplicationStatus;
+}
+
+export namespace ReplicationStatus {
+ export type AsObject = {
+ ok: boolean,
+ isActive: boolean,
+ currentVersion: number,
+ targetVersion: number,
+ }
+}
+
+export class SubscriptionUpdate extends jspb.Message {
+ getVersion(): number;
+ setVersion(value: number): void;
+
+ getReplicationBytes(): Uint8Array | string;
+ getReplicationBytes_asU8(): Uint8Array;
+ getReplicationBytes_asB64(): string;
+ setReplicationBytes(value: Uint8Array | string): void;
+
+ getSignature(): Uint8Array | string;
+ getSignature_asU8(): Uint8Array;
+ getSignature_asB64(): string;
+ setSignature(value: Uint8Array | string): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): SubscriptionUpdate.AsObject;
+ static toObject(includeInstance: boolean, msg: SubscriptionUpdate): SubscriptionUpdate.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: SubscriptionUpdate, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): SubscriptionUpdate;
+ static deserializeBinaryFromReader(message: SubscriptionUpdate, reader: jspb.BinaryReader): SubscriptionUpdate;
+}
+
+export namespace SubscriptionUpdate {
+ export type AsObject = {
+ version: number,
+ replicationBytes: Uint8Array | string,
+ signature: Uint8Array | string,
+ }
+}
+
+export class SignedSubscription extends jspb.Message {
+ hasSubPart(): boolean;
+ clearSubPart(): void;
+ getSubPart(): Subscription | undefined;
+ setSubPart(value?: Subscription): void;
+
+ hasUpdatePart(): boolean;
+ clearUpdatePart(): void;
+ getUpdatePart(): SubscriptionUpdate | undefined;
+ setUpdatePart(value?: SubscriptionUpdate): void;
+
+ serializeBinary(): Uint8Array;
+ toObject(includeInstance?: boolean): SignedSubscription.AsObject;
+ static toObject(includeInstance: boolean, msg: SignedSubscription): SignedSubscription.AsObject;
+ static extensions: {[key: number]: jspb.ExtensionFieldInfo};
+ static extensionsBinary: {[key: number]: jspb.ExtensionFieldBinaryInfo};
+ static serializeBinaryToWriter(message: SignedSubscription, writer: jspb.BinaryWriter): void;
+ static deserializeBinary(bytes: Uint8Array): SignedSubscription;
+ static deserializeBinaryFromReader(message: SignedSubscription, reader: jspb.BinaryReader): SignedSubscription;
+}
+
+export namespace SignedSubscription {
+ export type AsObject = {
+ subPart?: Subscription.AsObject,
+ updatePart?: SubscriptionUpdate.AsObject,
+ }
+}
+
diff --git a/ts/replication_pb_service.d.ts b/ts/replication_pb_service.d.ts
new file mode 100644
index 0000000..5a3e345
--- /dev/null
+++ b/ts/replication_pb_service.d.ts
@@ -0,0 +1,96 @@
+// package: pb
+// file: replication.proto
+
+import * as replication_pb from "./replication_pb";
+import {grpc} from "@improbable-eng/grpc-web";
+
+type replicatorAdd = {
+ readonly methodName: string;
+ readonly service: typeof replicator;
+ readonly requestStream: false;
+ readonly responseStream: true;
+ readonly requestType: typeof replication_pb.Subscription;
+ readonly responseType: typeof replication_pb.ReplicationStatus;
+};
+
+type replicatorStatus = {
+ readonly methodName: string;
+ readonly service: typeof replicator;
+ readonly requestStream: false;
+ readonly responseStream: true;
+ readonly requestType: typeof replication_pb.Subscription;
+ readonly responseType: typeof replication_pb.ReplicationStatus;
+};
+
+type replicatorGetSubscriptionUpdate = {
+ readonly methodName: string;
+ readonly service: typeof replicator;
+ readonly requestStream: false;
+ readonly responseStream: false;
+ readonly requestType: typeof replication_pb.Subscription;
+ readonly responseType: typeof replication_pb.SubscriptionUpdate;
+};
+
+type replicatorSubmitReplication = {
+ readonly methodName: string;
+ readonly service: typeof replicator;
+ readonly requestStream: false;
+ readonly responseStream: true;
+ readonly requestType: typeof replication_pb.SignedSubscription;
+ readonly responseType: typeof replication_pb.ReplicationStatus;
+};
+
+export class replicator {
+ static readonly serviceName: string;
+ static readonly Add: replicatorAdd;
+ static readonly Status: replicatorStatus;
+ static readonly GetSubscriptionUpdate: replicatorGetSubscriptionUpdate;
+ static readonly SubmitReplication: replicatorSubmitReplication;
+}
+
+export type ServiceError = { message: string, code: number; metadata: grpc.Metadata }
+export type Status = { details: string, code: number; metadata: grpc.Metadata }
+
+interface UnaryResponse {
+ cancel(): void;
+}
+interface ResponseStream {
+ cancel(): void;
+ on(type: 'data', handler: (message: T) => void): ResponseStream;
+ on(type: 'end', handler: (status?: Status) => void): ResponseStream;
+ on(type: 'status', handler: (status: Status) => void): ResponseStream;
+}
+interface RequestStream {
+ write(message: T): RequestStream;
+ end(): void;
+ cancel(): void;
+ on(type: 'end', handler: (status?: Status) => void): RequestStream;
+ on(type: 'status', handler: (status: Status) => void): RequestStream;
+}
+interface BidirectionalStream {
+ write(message: ReqT): BidirectionalStream;
+ end(): void;
+ cancel(): void;
+ on(type: 'data', handler: (message: ResT) => void): BidirectionalStream;
+ on(type: 'end', handler: (status?: Status) => void): BidirectionalStream;
+ on(type: 'status', handler: (status: Status) => void): BidirectionalStream;
+}
+
+export class replicatorClient {
+ readonly serviceHost: string;
+
+ constructor(serviceHost: string, options?: grpc.RpcOptions);
+ add(requestMessage: replication_pb.Subscription, metadata?: grpc.Metadata): ResponseStream;
+ status(requestMessage: replication_pb.Subscription, metadata?: grpc.Metadata): ResponseStream;
+ getSubscriptionUpdate(
+ requestMessage: replication_pb.Subscription,
+ metadata: grpc.Metadata,
+ callback: (error: ServiceError|null, responseMessage: replication_pb.SubscriptionUpdate|null) => void
+ ): UnaryResponse;
+ getSubscriptionUpdate(
+ requestMessage: replication_pb.Subscription,
+ callback: (error: ServiceError|null, responseMessage: replication_pb.SubscriptionUpdate|null) => void
+ ): UnaryResponse;
+ submitReplication(requestMessage: replication_pb.SignedSubscription, metadata?: grpc.Metadata): ResponseStream;
+}
+
diff --git a/ts/replication_pb_service.js b/ts/replication_pb_service.js
new file mode 100644
index 0000000..e59a2d4
--- /dev/null
+++ b/ts/replication_pb_service.js
@@ -0,0 +1,205 @@
+// package: pb
+// file: replication.proto
+
+var replication_pb = require("./replication_pb");
+var grpc = require("@improbable-eng/grpc-web").grpc;
+
+var replicator = (function () {
+ function replicator() {}
+ replicator.serviceName = "pb.replicator";
+ return replicator;
+}());
+
+replicator.Add = {
+ methodName: "Add",
+ service: replicator,
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.ReplicationStatus
+};
+
+replicator.Status = {
+ methodName: "Status",
+ service: replicator,
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.ReplicationStatus
+};
+
+replicator.GetSubscriptionUpdate = {
+ methodName: "GetSubscriptionUpdate",
+ service: replicator,
+ requestStream: false,
+ responseStream: false,
+ requestType: replication_pb.Subscription,
+ responseType: replication_pb.SubscriptionUpdate
+};
+
+replicator.SubmitReplication = {
+ methodName: "SubmitReplication",
+ service: replicator,
+ requestStream: false,
+ responseStream: true,
+ requestType: replication_pb.SignedSubscription,
+ responseType: replication_pb.ReplicationStatus
+};
+
+exports.replicator = replicator;
+
+function replicatorClient(serviceHost, options) {
+ this.serviceHost = serviceHost;
+ this.options = options || {};
+}
+
+replicatorClient.prototype.add = function add(requestMessage, metadata) {
+ var listeners = {
+ data: [],
+ end: [],
+ status: []
+ };
+ var client = grpc.invoke(replicator.Add, {
+ request: requestMessage,
+ host: this.serviceHost,
+ metadata: metadata,
+ transport: this.options.transport,
+ debug: this.options.debug,
+ onMessage: function (responseMessage) {
+ listeners.data.forEach(function (handler) {
+ handler(responseMessage);
+ });
+ },
+ onEnd: function (status, statusMessage, trailers) {
+ listeners.status.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners.end.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners = null;
+ }
+ });
+ return {
+ on: function (type, handler) {
+ listeners[type].push(handler);
+ return this;
+ },
+ cancel: function () {
+ listeners = null;
+ client.close();
+ }
+ };
+};
+
+replicatorClient.prototype.status = function status(requestMessage, metadata) {
+ var listeners = {
+ data: [],
+ end: [],
+ status: []
+ };
+ var client = grpc.invoke(replicator.Status, {
+ request: requestMessage,
+ host: this.serviceHost,
+ metadata: metadata,
+ transport: this.options.transport,
+ debug: this.options.debug,
+ onMessage: function (responseMessage) {
+ listeners.data.forEach(function (handler) {
+ handler(responseMessage);
+ });
+ },
+ onEnd: function (status, statusMessage, trailers) {
+ listeners.status.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners.end.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners = null;
+ }
+ });
+ return {
+ on: function (type, handler) {
+ listeners[type].push(handler);
+ return this;
+ },
+ cancel: function () {
+ listeners = null;
+ client.close();
+ }
+ };
+};
+
+replicatorClient.prototype.getSubscriptionUpdate = function getSubscriptionUpdate(requestMessage, metadata, callback) {
+ if (arguments.length === 2) {
+ callback = arguments[1];
+ }
+ var client = grpc.unary(replicator.GetSubscriptionUpdate, {
+ request: requestMessage,
+ host: this.serviceHost,
+ metadata: metadata,
+ transport: this.options.transport,
+ debug: this.options.debug,
+ onEnd: function (response) {
+ if (callback) {
+ if (response.status !== grpc.Code.OK) {
+ var err = new Error(response.statusMessage);
+ err.code = response.status;
+ err.metadata = response.trailers;
+ callback(err, null);
+ } else {
+ callback(null, response.message);
+ }
+ }
+ }
+ });
+ return {
+ cancel: function () {
+ callback = null;
+ client.close();
+ }
+ };
+};
+
+replicatorClient.prototype.submitReplication = function submitReplication(requestMessage, metadata) {
+ var listeners = {
+ data: [],
+ end: [],
+ status: []
+ };
+ var client = grpc.invoke(replicator.SubmitReplication, {
+ request: requestMessage,
+ host: this.serviceHost,
+ metadata: metadata,
+ transport: this.options.transport,
+ debug: this.options.debug,
+ onMessage: function (responseMessage) {
+ listeners.data.forEach(function (handler) {
+ handler(responseMessage);
+ });
+ },
+ onEnd: function (status, statusMessage, trailers) {
+ listeners.status.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners.end.forEach(function (handler) {
+ handler({ code: status, details: statusMessage, metadata: trailers });
+ });
+ listeners = null;
+ }
+ });
+ return {
+ on: function (type, handler) {
+ listeners[type].push(handler);
+ return this;
+ },
+ cancel: function () {
+ listeners = null;
+ client.close();
+ }
+ };
+};
+
+exports.replicatorClient = replicatorClient;
+