125954ace8
During transaction processing we retrieve the type of msg and based on that we get the applicable handler from the router. This means that the router should only receive messages that it knows how to handle. Instead of using Get interfaces, we should cast to the actual type of transaction and then access the transaction details that way. It's okay to panic here, because if the DummyHandler receives a message that it cannot cast to the expected type it means something is wrong with the router. Instead of retrieving an arbitrary key by chance we should panic. |
||
---|---|---|
baseapp | ||
docs | ||
examples | ||
publish | ||
store | ||
tests | ||
tools | ||
types | ||
version | ||
x | ||
.codecov.yml | ||
.gitignore | ||
CHANGELOG.md | ||
CODEOWNERS | ||
CODE_OF_CONDUCT.md | ||
Dockerfile | ||
LICENSE | ||
Makefile | ||
README.md | ||
Vagrantfile | ||
circle.yml | ||
glide.lock | ||
glide.yaml |
README.md
Cosmos SDK
Branch | Tests | Coverage |
---|---|---|
develop | ||
master |
WARNING: the libraries are still undergoing breaking changes as we get better ideas and start building out the Apps.
Note: Requires Go 1.9+
The Cosmos SDK is a platform for building multi-asset Proof-of-Stake cryptocurrencies, like the Cosmos Hub. It is both a library for building applications and a set of tools for securely interacting with them.
The goals of the SDK are to abstract away the complexities of building a Tendermint ABCI application in Golang and to provide a framework for building interoperable blockchain applications in the Cosmos Network.
It is inspired by capabilities-based security, and informed by years of wrestling with blockchain state machines.
The SDK is fast, safe, and easy-to-use. It is generic enough to be used to implement the state machines of other existing blockchains, like Bitcoin and Ethereum, allowing seamless integration with them and their data structures. It comes with batteries included, is easily extensible, and does not require developers to fork it to access any of its current or extended functionality. It provides both REST and command line interfaces for secure user interactions.
Applications in the Cosmos-SDK are defined in terms of handlers that process messages and read and write to a store. Handlers are given restricted capabilities that determine which parts of the store they can access. The SDK provides common data structures for Accounts, multi-asset Coins, checking signatures, preventing replay, and so on.
For more details on the design goals, see the SDK Guide
Prerequisites
Getting Started
- See the SDK Guide