You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README-DEV.md
+21-13
Original file line number
Diff line number
Diff line change
@@ -153,10 +153,12 @@ Please take into account the following when sending a PR:
153
153
154
154
## How To Add a new Module or Transaction
155
155
156
-
- Use [starport](https://github.com/tendermint/starport) command to scaffold the module.
157
-
Consider using a docker container built from the provided [Dockerfile](scripts/Dockerfile) to have a predictable version of starport. See [README.md](scripts/README.md).
156
+
- Use [ignite v0.27.1](https://github.com/ignite/cli) command to scaffold the module.
157
+
Consider using a docker container built from the provided [Dockerfile](scripts/Dockerfile) to have a predictable version of ignite. See [README.md](scripts/README.md).
158
158
- Have a look at the scripts and commands used forgeneration of existing modules, messages and CRUD operations and do itin a similar way
159
159
(for example [PKI module commands](scripts/starport/upgrade-0.44/07.pki_types.sh)).
160
+
Note: On previous scaffolding of modules `starport` cli used instead of `ignite`.
161
+
While generating new module, command structure will the same except it must start with `ignite`.
160
162
- If a new transaction with a new data in state (key-value) and new queries needs to be created, then both message and CRUD commands need to be executed.
161
163
- If just a message to update existing state values need to be created, then a message command is enough.
162
164
- Adjust the generated code
@@ -166,19 +168,18 @@ Please take into account the following when sending a PR:
166
168
- add `(cosmos_proto.scalar) = "cosmos.AddressString"` annotation for all fields with address/account type (such as `signer` or `owner`).
167
169
- fix types if needed in`proto/<module>/<entity>.proto` files
168
170
- Note1: `unit64` will be returned as string if the output is a JSON format. So, it's better to use `uint64` only when it's really `uint64`.
169
-
- Note2: for`uint16` type: use `int32` during starport scaffolding, and add custom validation (annotations above) to check the lower and upper bounds.
170
-
- Note3: for`uint32` type: use `int32` during starport scaffolding, then replace it by `uint32`in .proto files, re-generate the code and fix compilation errors.
171
-
- build proto (for example `starport chain build`). Fix compilation errors if any.
171
+
- Note2: for`uint16` type: use `int32` during ignite scaffolding, and add custom validation (annotations above) to check the lower and upper bounds.
172
+
- Note3: for`uint32` type: use `int32` during ignite scaffolding, then replace it by `uint32`in .proto files, re-generate the code and fix compilation errors.
173
+
- build proto (for example `ignite chain build`). Fix compilation errors if any.
172
174
- generate openapi docs from proto using (`scripts/dcl-swagger-gen.sh`). It's recommended to run from container built from [Dockerfile](scripts/Dockerfile)
173
175
174
176
- **Note1**: colons (`:`) are part of subject-id in PKI module, but colons are not allowed in gRPC REST URLs by default.
175
177
`allow_colon_final_segments=true` should be used as a workaround.
176
178
So, make sure that `runtime.AssumeColonVerbOpt(false)` in `/x/pki/types/query.pb.gw.go`.
177
179
It's usually sufficient to revert the generated changes in`/x/pki/types/query.pb.gw.go`.
178
-
- **Note2**: move `compliance_info.pb.go` and `compliance_history_item.pb.go` to `types/compliance` and adjust the import in other places accordingly.
179
180
It may be easier just to revert changes in all `*.pb.go` files not affected by your changes in`.proto`
180
-
- **Note3**: `starport chain build` needs to be called only if you made manual changes in`.proto` files.
181
-
There is no need to call `starport chain build` again once all errors and adjustments above are done. It's sufficient just to build the project via usual ways (such as `make build`)
181
+
- **Note3**: `ignite chain build` needs to be called only if you made manual changes in`.proto` files.
182
+
There is no need to call `ignite chain build` again once all errors and adjustments above are done. It's sufficient just to build the project via usual ways (such as `make build`)
182
183
- Add static validation for new messages:
183
184
- Call `validator.Validate(msg)` in `ValidateBasic` methods for all generated messages
184
185
- Add additional checks to `ValidateBasic` that do not depend on the state (key-value) and order of transactions
@@ -195,19 +196,19 @@ Please take into account the following when sending a PR:
195
196
196
197
## How To Make Changes in Data Model for Existing Modules
197
198
198
-
- Use [starport](https://github.com/tendermint/starport) command to scaffold the module.
199
-
Consider using the provided [Dockerfile](scripts/Dockerfile) to have a predictable version of starport. See [README.md](scripts/README.md).
199
+
- Use [ignite](https://github.com/ignite/cli) command to scaffold the module.
200
+
Consider using the provided [Dockerfile](scripts/Dockerfile) to have a predictable version of ignite. See [README.md](scripts/README.md).
200
201
- **Never change `.pb` files manually**. Do the changes in`.proto` files.
201
-
- Every time`.proto` files change, re-generate the code (for example `starport chain build`) and fix compilation errors if any.
202
+
- Every time`.proto` files change, re-generate the code (for example `ignite chain build`) and fix compilation errors if any.
202
203
- Update openapi docs from proto using (`scripts/dcl-swagger-gen.sh`). It's recommended to run from container built from [Dockerfile](scripts/Dockerfile).
203
204
- **Note1**: colons (`:`) are part of subject-id in PKI module, but colons are not allowed in gRPC REST URLs by default.
204
205
`allow_colon_final_segments=true` should be used as a workaround.
205
206
So, make sure that `runtime.AssumeColonVerbOpt(false)` in `/x/pki/types/query.pb.gw.go`.
206
207
It's usually sufficient to revert the generated changes in`/x/pki/types/query.pb.gw.go`.
207
208
- **Note2**: move `compliance_info.pb.go` and `compliance_history_item.pb.go` to `types/compliance` and adjust the import in other places accordingly.
208
209
It may be easier just to revert changes in all `*.pb.go` files not affected by your changes in`.proto`
209
-
- **Note3**: `starport chain build` needs to be called only if you made manual changes in`.proto` files.
210
-
There is no need to call `starport chain build` again once all errors and adjustments above are done. It's sufficient just to build the project via usual ways (such as `make build`)
210
+
- **Note3**: `ignite chain build` needs to be called only if you made manual changes in`.proto` files.
211
+
There is no need to call `ignite chain build` again once all errors and adjustments above are done. It's sufficient just to build the project via usual ways (such as `make build`)
211
212
212
213
213
214
## Update Cosmos-sdk Version
@@ -221,6 +222,13 @@ Re-generate cosmos base openapi (service API from cosmos exposed in DCL) using [
221
222
./scripts/cosmos-swagger-gen.sh tx
222
223
```
223
224
225
+
## Update CometBFT Version
226
+
Please note, that we depend on the CometBFT fork https://github.com/zigbee-alliance/cometbft/releases/tag/v0.37.5
227
+
due to hotfixes for https://github.com/tendermint/tendermint/issues/7640 and https://github.com/tendermint/tendermint/issues/7641
228
+
required for Light Client Proxy.
229
+
230
+
Also don't forget to update the link to the CometBFT RPC in [Swagger UI](docs/index.html).
231
+
224
232
## Other
225
233
226
234
For more details, please have a look at [Cosmos SDK tutorial](https://tutorials.cosmos.network/).
Copy file name to clipboardexpand all lines: README.md
+13-13
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ DC Ledger is a public permissioned Ledger which can be used for two main use cas
18
18
19
19
More information about use cases can be found in [DC Ledger Overview](./docs/design/DCL-Overview.pdf) and [Use Case Diagrams](docs/use_cases).
20
20
21
-
DC Ledger is based on [Tendermint](https://tendermint.com/) and [Cosmos SDK](https://cosmos.network/sdk).
21
+
DC Ledger is based on [CometBFT](https://cometbft.com/) and [Cosmos SDK](https://cosmos.network/sdk).
22
22
23
23
DC Ledger is a public permissioned ledger in the following sense:
24
24
@@ -40,7 +40,7 @@ In order to send write transactions to the ledger you need:
40
40
41
41
### Pool of Nodes
42
42
43
-
- A network of Tendermint-based validator nodes (Validators and Observers) maintaining the ledger.
43
+
- A network of CometBFT-based validator nodes (Validators and Observers) maintaining the ledger.
44
44
- Every validator node (`dcld` binary) runs DC Ledger application code (based on Cosmos SDK) implementing the use cases.
45
45
- See the proposed deployment in [deployment](docs/deployment.png) and [deployment-detailed](docs/deployment-detailed.png).
46
46
- See recommended design for DCL MainNet deployment on AWS in [aws deployment](./docs/deployment-design-aws.md)
@@ -54,7 +54,7 @@ In order to send write transactions to the ledger you need:
54
54
-**Private Sentry Node:** a full node to connect other Validator or Sentry nodes only; should not be accessed by clients.
55
55
-**Public Sentry Node:** a full node to connect other external full nodes (possibly observer nodes).
56
56
-**Observer Node (ON):** a full node that doesn't participate in consensus. Should be used to receive read/write requests from the clients.
57
-
-**Light Client Proxy Node**: doesn't contain a full replication of data. Can be used as a proxy to untrusted Full nodes for single-value query requests sent via CLI or Tendermint RPC.
57
+
-**Light Client Proxy Node**: doesn't contain a full replication of data. Can be used as a proxy to untrusted Full nodes for single-value query requests sent via CLI or CometBFT RPC.
58
58
It will verify all state proofs automatically.
59
59
-**Seed Node**: provides a list of peers which a node can connect to.
- Any running node exposes a REST API at port `1317`. See <https://docs.cosmos.network/v0.45/core/grpc_rest.html>.
142
+
- Any running node exposes a REST API at port `1317`. See <https://docs.cosmos.network/v0.47/learn/advanced/grpc_rest>.
143
143
- See [transactions](docs/transactions.md) for a full list of endpoints.
144
144
- REST HTTP(S) queries can be directly used for read requests.
145
145
See [How to read from the Ledger](docs/transactions.md#how-to-read-from-the-ledger).
@@ -150,23 +150,23 @@ See [Run Light Client Proxy](docs/running-light-client-proxy.md) for details how
150
150
### gRPC
151
151
152
152
-**There are no state proofs in gRPC, so gRPC queries should be sent to trusted Validator or Observer nodes only.**
153
-
- Any running node exposes a REST API at port `9090`. See <https://docs.cosmos.network/v0.45/core/grpc_rest.html>.
153
+
- Any running node exposes a REST API at port `9090`. See <https://docs.cosmos.network/v0.47/learn/advanced/grpc_rest>.
154
154
- A client code can be generated for all popular languages from the proto files [proto](proto), see <https://grpc.io/docs/languages/>.
155
155
- The generated client code can be used for read and write requests, i.e. generation and signing of transactions
156
156
See [How to read from the Ledger](docs/transactions.md#how-to-read-from-the-ledger) and [How to write to the Ledger](docs/transactions.md#how-to-write-to-the-ledger) for details.
157
157
158
-
### Tendermint RPC and Light Client
158
+
### CometBFT RPC and Light Client
159
159
160
-
-Tendermint RPC is exposed by every running node at port `26657`. See <https://docs.cosmos.network/v0.45/core/grpc_rest.html#tendermint-rpc>.
161
-
-Tendermint RPC supports state proofs. Tendermint's Light Client library can be used to verify the state proofs.
160
+
-CometBFT RPC is exposed by every running node at port `26657`. See <https://docs.cosmos.network/v0.47/learn/advanced/grpc_rest#cometbft-rpc>.
161
+
-CometBFT RPC supports state proofs. CometBFT's Light Client library can be used to verify the state proofs.
162
162
So, if Light Client API is used, then it's possible to communicate with non-trusted nodes.
163
163
- Please note, that multi-value queries don't have state proofs support and should be sent to trusted nodes only.
164
164
- There are currently no DC Ledger specific API libraries for various platforms and languages,
165
165
but they may be provided in the future.
166
166
- The following libraries can be used as light clients:
- Refer to [this doc](./docs/tendermint-rpc.md) to see how to [subscribe](./docs/tendermint-rpc.md#subscribe) to a Tendermint WebSocket based events and/or [query](./docs/tendermint-rpc.md#querying-application-components) an application components.
169
+
- Refer to [this doc](./docs/cometbtf-rpc.md) to see how to [subscribe](./docs/cometbtf-rpc.md#subscribe) to a CometBFT WebSocket based events and/or [query](./docs/cometbtf-rpc.md#querying-application-components) an application components.
170
170
171
171
172
172
### Instructions
@@ -227,5 +227,5 @@ the following instructions from [how-to.md](docs/how-to.md) can be used for ever
227
227
-[Running Node](docs/running-node.md)
228
228
-[Pool Upgrade](docs/pool-upgrade.md)
229
229
-[Pool Upgrade How To Guide](docs/pool-upgrade-how-to.md)
Copy file name to clipboardexpand all lines: docs/how-to.md
+3-2
Original file line number
Diff line number
Diff line change
@@ -47,7 +47,8 @@ Here is the list of supported settings:
47
47
-`chain-id <chain id>` - unique chain ID of the network you are going to connect to
48
48
-`output <type>` - Output format (text/json)
49
49
-`node <node-ip>` - Address `<host>:<port>` of the node to connect.
50
-
-`broadcast-mode <mode>` - Write transaction broadcast mode to use (one of: `sync`, `async`, `block`. `block` is default).
50
+
-`broadcast-mode <mode>` - Write transaction broadcast mode to use (one of: `sync`, `async`. `sync` is default).
51
+
- Note: In `sync` broadcast mode, to get the actual result of transaction(`dcld tx ..`) one more query call with `txHash` must be executed(`dcld query tx=txHash`)
51
52
52
53
In order to connect the CLI to a DC Ledger Network (Chain), the following parameters should be used:
53
54
@@ -336,5 +337,5 @@ Node will be jailed and removed from the active validator set in the following c
336
337
337
338
Note that jailed node will not be removed from the main index to track validator nodes.
338
339
So it is not possible to create a new node with the same `validator address`.
339
-
In order to unjail the node and return it to the active tendermint validator set the sufficient number of Trustee's approvals is needed
340
+
In order to unjail the node and return it to the active cometbft validator set the sufficient number of Trustee's approvals is needed
Copy file name to clipboardexpand all lines: docs/running-node.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@
7
7
-`Private Sentry` - Full Node to connect other (external) Validator Nodes ([Sentry Node Architecture](https://forum.cosmos.network/t/sentry-node-architecture-overview/454))
8
8
-`Public Sentry` - Full Node to connect other (external) Full Nodes
9
9
-`Observer` - Full Node for serving gRPC / REST / RPC clients
10
-
-`Seed` - Full Node for sharing IP addresses of `Public Sentry` Nodes ([Seed Node](https://docs.tendermint.com/))
10
+
-`Seed` - Full Node for sharing IP addresses of `Public Sentry` Nodes ([Seed Node](https://docs.cometbft.com/))
0 commit comments