Browse Source

docs: clean a bunch of stuff up

pull/640/head
Zach Ramsay 7 years ago
parent
commit
e509e8f354
15 changed files with 46 additions and 75 deletions
  1. +8
    -8
      docs/abci-cli.rst
  2. +3
    -4
      docs/app-architecture.rst
  3. +1
    -1
      docs/app-development.rst
  4. +2
    -2
      docs/block-structure.rst
  5. +3
    -6
      docs/byzantine-consensus-algorithm.rst
  6. +3
    -13
      docs/deploy-testnets.rst
  7. +0
    -2
      docs/genesis.rst
  8. +8
    -7
      docs/getting-started.rst
  9. +2
    -2
      docs/index.rst
  10. +1
    -6
      docs/install-from-source.rst
  11. +4
    -4
      docs/light-client-protocol.rst
  12. +2
    -2
      docs/secure-p2p.rst
  13. +1
    -1
      docs/specification.rst
  14. +3
    -12
      docs/using-tendermint.rst
  15. +5
    -5
      docs/validators.rst

+ 8
- 8
docs/abci-cli.rst View File

@ -48,7 +48,7 @@ Now run ``abci-cli --help`` to see the list of commands:
--help, -h show help --help, -h show help
--version, -v print the version --version, -v print the version
First Example - Dummy
Dummy - First Example
--------------------- ---------------------
The ``abci-cli`` tool lets us send ABCI messages to our application, to The ``abci-cli`` tool lets us send ABCI messages to our application, to
@ -148,7 +148,7 @@ but if we do ``deliver_tx "abc=efg"`` it will store ``(abc, efg)``.
Similarly, you could put the commands in a file and run Similarly, you could put the commands in a file and run
``abci-cli --verbose batch < myfile``. ``abci-cli --verbose batch < myfile``.
Another Example - Counter
Counter - Another Example
------------------------- -------------------------
Now that we've got the hang of it, let's try another application, the Now that we've got the hang of it, let's try another application, the
@ -238,20 +238,20 @@ To run the Node JS version, ``cd`` to ``example/js`` and run
window, run the console and those previous ABCI commands. You should get window, run the console and those previous ABCI commands. You should get
the same results as for the Go version. the same results as for the Go version.
Bounties
--------
Want to write the counter app in your favorite language?! We'd be happy Want to write the counter app in your favorite language?! We'd be happy
to add you to our `ecosystem <https://tendermint.com/ecosystem>`__! to add you to our `ecosystem <https://tendermint.com/ecosystem>`__!
We're also offering `bounties <https://tendermint.com/bounties>`__ for We're also offering `bounties <https://tendermint.com/bounties>`__ for
implementations in new languages! implementations in new languages!
Notes
-----
The ``abci-cli`` is designed strictly for testing and debugging. In a The ``abci-cli`` is designed strictly for testing and debugging. In a
real deployment, the role of sending messages is taken by Tendermint, real deployment, the role of sending messages is taken by Tendermint,
which connects to the app using three separate connections, each with which connects to the app using three separate connections, each with
its own pattern of messages. its own pattern of messages.
For more information, see the `application developers For more information, see the `application developers
guide </docs/guides/app-development>`__. For examples of running an ABCI
app with Tendermint, see the `introductory
guide </docs/getting-started/first-abci-app>`__.
guide <./app-development.html>`__. For examples of running an ABCI
app with Tendermint, see the `getting started
guide <./getting-started.html>`__.

+ 3
- 4
docs/app-architecture.rst View File

@ -58,7 +58,7 @@ Tendermint Core RPC
The concept is that the ABCI app is completely hidden from the outside The concept is that the ABCI app is completely hidden from the outside
world and only communicated through a tested and secured `interface world and only communicated through a tested and secured `interface
exposed by the tendermint core </docs/specs/rpc>`__. This interface
exposed by the tendermint core <./rpc.html>`__. This interface
exposes a lot of data on the block header and consensus process, which exposes a lot of data on the block header and consensus process, which
is quite useful for externally verifying the system. It also includes is quite useful for externally verifying the system. It also includes
3(!) methods to broadcast a transaction (propose it for the blockchain, 3(!) methods to broadcast a transaction (propose it for the blockchain,
@ -122,7 +122,6 @@ the number of validators, one should be able to scale our read
performance to quite an extent (until the replication process drains too performance to quite an extent (until the replication process drains too
many resources from the validator nodes). many resources from the validator nodes).
Example Code
------------
- `TMChat <https://github.com/wolfposd/TMChat>`__
`TMChat <https://github.com/wolfposd/TMChat>`__ is an example of an ABCI
application.

+ 1
- 1
docs/app-development.rst View File

@ -110,7 +110,7 @@ TSP
If GRPC is not available in your language, or you require higher If GRPC is not available in your language, or you require higher
performance, or otherwise enjoy programming, you may implement your own performance, or otherwise enjoy programming, you may implement your own
ABCI server using the Tendermint Socket Protocol, known affectionaltely
ABCI server using the Tendermint Socket Protocol, known affectionately
as Teaspoon. The first step is still to auto-generate the relevant data as Teaspoon. The first step is still to auto-generate the relevant data
types and codec in your language using ``protoc``. Messages coming over types and codec in your language using ``protoc``. Messages coming over
the socket are Protobuf3 encoded, but additionally length-prefixed to the socket are Protobuf3 encoded, but additionally length-prefixed to


+ 2
- 2
docs/block-structure.rst View File

@ -120,8 +120,8 @@ Vote Sign Bytes
^^^^^^^^^^^^^^^ ^^^^^^^^^^^^^^^
The ``sign-bytes`` of a vote is produced by taking a The ``sign-bytes`` of a vote is produced by taking a
```stable-json`` <https://github.com/substack/json-stable-stringify>`__-like
deterministic JSON ```wire`` </docs/specs/wire-protocol>`__ encoding of
`stable-json <https://github.com/substack/json-stable-stringify>`__-like
deterministic JSON `wire <./wire-protocol.html>`__ encoding of
the vote (excluding the ``Signature`` field), and wrapping it with the vote (excluding the ``Signature`` field), and wrapping it with
``{"chain_id":"my_chain","vote":...}``. ``{"chain_id":"my_chain","vote":...}``.


+ 3
- 6
docs/byzantine-consensus-algorithm.rst View File

@ -1,9 +1,6 @@
Byzantine Consensus Algorithm Byzantine Consensus Algorithm
============================= =============================
*The draft 0.6 whitepaper is outdated. The new algorithm is detailed
below. See `revisions <#revisions>`__*
Terms Terms
----- -----
@ -23,7 +20,7 @@ Terms
for something. for something.
- A vote *at* ``(H,R)`` is a vote signed with the bytes for ``H`` and - A vote *at* ``(H,R)`` is a vote signed with the bytes for ``H`` and
``R`` included in its ``R`` included in its
```sign-bytes`` </docs/specs/block-structure#vote-sign-bytes>`__.
`sign-bytes <block-structure.html#vote-sign-bytes>`__.
- *+2/3* is short for "more than 2/3" - *+2/3* is short for "more than 2/3"
- *1/3+* is short for "1/3 or more" - *1/3+* is short for "1/3 or more"
- A set of +2/3 of prevotes for a particular block or ``<nil>`` at - A set of +2/3 of prevotes for a particular block or ``<nil>`` at
@ -261,7 +258,7 @@ in the commit-set) are each justified in the JSet with no duplicitous
vote signatures (by the committers). vote signatures (by the committers).
- **Lemma**: When a fork is detected by the existence of two - **Lemma**: When a fork is detected by the existence of two
conflicting `commits </docs/specs/validators#commiting-a-block>`__,
conflicting `commits <./validators.html#commiting-a-block>`__,
the union of the JSets for both commits (if they can be compiled) the union of the JSets for both commits (if they can be compiled)
must include double-signing by at least 1/3+ of the validator set. must include double-signing by at least 1/3+ of the validator set.
**Proof**: The commit cannot be at the same round, because that would **Proof**: The commit cannot be at the same round, because that would
@ -304,7 +301,7 @@ Censorship Attacks
~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~
Due to the definition of a block Due to the definition of a block
`commit </docs/specs/validators#commiting-a-block>`__, any 1/3+
`commit <validators.html#commiting-a-block>`__, any 1/3+
coalition of validators can halt the blockchain by not broadcasting coalition of validators can halt the blockchain by not broadcasting
their votes. Such a coalition can also censor particular transactions by their votes. Such a coalition can also censor particular transactions by
rejecting blocks that include these transactions, though this would rejecting blocks that include these transactions, though this would


+ 3
- 13
docs/deploy-testnets.rst View File

@ -34,7 +34,7 @@ Here are the steps to setting up a testnet manually:
After a few seconds, all the nodes should connect to eachother and start After a few seconds, all the nodes should connect to eachother and start
making blocks! For more information, see the Tendermint Networks section making blocks! For more information, see the Tendermint Networks section
of `the guide to using Tendermint </docs/guides/using-tendermint>`__.
of `the guide to using Tendermint <using-tendermint.html>`__.
Automated Deployments Automated Deployments
--------------------- ---------------------
@ -43,15 +43,5 @@ While the manual deployment is easy enough, an automated deployment is
always better. For this, we have the `mintnet-kubernetes always better. For this, we have the `mintnet-kubernetes
tool <https://github.com/tendermint/tools/tree/master/mintnet-kubernetes>`__, tool <https://github.com/tendermint/tools/tree/master/mintnet-kubernetes>`__,
which allows us to automate the deployment of a Tendermint network on an which allows us to automate the deployment of a Tendermint network on an
already provisioned kubernetes cluster.
For more details, see the `mintnet-kubernetes
directory <https://github.com/tendermint/tools/tree/master/mintnet-kubernetes>`__,
and check out `Google Cloud Platform <https://cloud.google.com/>`__ for
simple provisioning of kubernetes clusters.
Next Steps
----------
Done trying out the testnet? Continue
`onwards </docs/getting-started/next-steps>`__.
already provisioned kubernetes cluster. And for simple provisioning of kubernetes
cluster, check out the `Google Cloud Platform <https://cloud.google.com/>`__.

+ 0
- 2
docs/genesis.rst View File

@ -30,8 +30,6 @@ Fields
Sample genesis.json Sample genesis.json
~~~~~~~~~~~~~~~~~~~ ~~~~~~~~~~~~~~~~~~~
This example is from the Basecoin mintnet example:
.. code:: json .. code:: json
{ {


+ 8
- 7
docs/getting-started.rst View File

@ -52,7 +52,7 @@ application written in Javascript.
Now, let's run some apps! Now, let's run some apps!
A First Example - Dummy
Dummy - A First Example
----------------------- -----------------------
The dummy app is a `Merkle The dummy app is a `Merkle
@ -80,7 +80,7 @@ If you have used Tendermint, you may want to reset the data for a new
blockchain by running ``tendermint unsafe_reset_all``. Then you can run blockchain by running ``tendermint unsafe_reset_all``. Then you can run
``tendermint node`` to start Tendermint, and connect to the app. For ``tendermint node`` to start Tendermint, and connect to the app. For
more details, see `the guide on using more details, see `the guide on using
Tendermint <using-tendermint.rst>`__.
Tendermint <./using-tendermint.html>`__.
You should see Tendermint making blocks! We can get the status of our You should see Tendermint making blocks! We can get the status of our
Tendermint node as follows: Tendermint node as follows:
@ -149,7 +149,7 @@ Now if we query for ``name``, we should get ``satoshi``, or
Try some other transactions and queries to make sure everything is Try some other transactions and queries to make sure everything is
working! working!
Another Example - Counter
Counter - Another Example
------------------------- -------------------------
Now that we've got the hang of it, let's try another application, the Now that we've got the hang of it, let's try another application, the
@ -214,9 +214,9 @@ But if we send a ``1``, it works again:
{"jsonrpc":"2.0","id":"","result":[98,{"check_tx":{},"deliver_tx":{}}],"error":""} {"jsonrpc":"2.0","id":"","result":[98,{"check_tx":{},"deliver_tx":{}}],"error":""}
For more details on the ``broadcast_tx`` API, see `the guide on using For more details on the ``broadcast_tx`` API, see `the guide on using
Tendermint <using-tendermint.rst>`__.
Tendermint <./using-tendermint.html>`__.
Example in Another Language - CounterJS
CounterJS - Example in Another Language
--------------------------------------- ---------------------------------------
We also want to run applications in another language - in this case, We also want to run applications in another language - in this case,
@ -258,7 +258,7 @@ like before - the results should be the same:
Neat, eh? Neat, eh?
A More Interesting Example - Basecoin
Basecoin - A More Interesting Example
------------------------------------- -------------------------------------
We saved the best for last; the `Cosmos SDK <https://github.com/cosmos/cosmos-sdk>`__ is a general purpose framework for building cryptocurrencies. Unlike the``dummy`` and ``counter``, which are strictly for example purposes. The reference implementation of Cosmos SDK is ``basecoin``, which demonstrates how to use the building blocks of the Cosmos SDK. We saved the best for last; the `Cosmos SDK <https://github.com/cosmos/cosmos-sdk>`__ is a general purpose framework for building cryptocurrencies. Unlike the``dummy`` and ``counter``, which are strictly for example purposes. The reference implementation of Cosmos SDK is ``basecoin``, which demonstrates how to use the building blocks of the Cosmos SDK.
@ -268,7 +268,8 @@ that supports inter-blockchain communication. For more details on how
basecoin works and how to use it, see our `basecoin basecoin works and how to use it, see our `basecoin
guide <https://github.com/cosmos/cosmos-sdk/blob/develop/docs/guide/basecoin-basics.md>`__ guide <https://github.com/cosmos/cosmos-sdk/blob/develop/docs/guide/basecoin-basics.md>`__
In this tutorial you learned how to run applications using Tendermint on a single node. You saw how applications could be written in different
In this tutorial you learned how to run applications using Tendermint
on a single node. You saw how applications could be written in different
languages, and how to send transactions and query for the latest state. languages, and how to send transactions and query for the latest state.
But the true power of Tendermint comes from its ability to securely and But the true power of Tendermint comes from its ability to securely and
efficiently run an application across a distributed network of nodes, efficiently run an application across a distributed network of nodes,


+ 2
- 2
docs/index.rst View File

@ -11,7 +11,7 @@ Tendermint 101:
.. maxdepth set to 2 for sexiness .. maxdepth set to 2 for sexiness
.. but use 4 to upgrade documentation .. but use 4 to upgrade documentation
.. toctree:: .. toctree::
:maxdepth: 4
:maxdepth: 2
introduction.rst introduction.rst
install-from-source.rst install-from-source.rst
@ -22,7 +22,7 @@ Tendermint 101:
Tendermint 102: Tendermint 102:
.. toctree:: .. toctree::
:maxdepth: 4
:maxdepth: 2
abci-cli.rst abci-cli.rst
app-architecture.rst app-architecture.rst


+ 1
- 6
docs/install-from-source.rst View File

@ -2,7 +2,7 @@ Install from Source
=================== ===================
This page provides instructions on installing Tendermint from source. To This page provides instructions on installing Tendermint from source. To
download pre-built binaries, see the `Download page </download>`__.
download pre-built binaries, see the `Download page <https://tendermint.com/download>`__.
Install Go Install Go
---------- ----------
@ -100,8 +100,3 @@ To start a one-node blockchain with a simple in-process application:
tendermint init tendermint init
tendermint node --proxy_app=dummy tendermint node --proxy_app=dummy
See the `App Development </docs/guides/app-development>`__ guide for
more details on building applications, and the `Using
Tendermint </docs/guides/using-tendermint>`__ guide for more details
about using the ``tendermint`` program.

+ 4
- 4
docs/light-client-protocol.rst View File

@ -12,18 +12,18 @@ Overview
-------- --------
The objective of the light client protocol is to get a The objective of the light client protocol is to get a
`commit </docs/specs/validators#committing-a-block>`__ for a recent
`block hash </docs/specs/block-structure#block-hash>`__ where the commit
`commit <./validators.html#committing-a-block>`__ for a recent
`block hash <./block-structure.html#block-hash>`__ where the commit
includes a majority of signatures from the last known validator set. includes a majority of signatures from the last known validator set.
From there, all the application state is verifiable with `merkle From there, all the application state is verifiable with `merkle
proofs </docs/specs/merkle-trees#iavl-tree>`__.
proofs <./merkle-trees#iavl-tree>`__.
Properties Properties
---------- ----------
- You get the full collateralized security benefits of Tendermint; No - You get the full collateralized security benefits of Tendermint; No
need to wait for confirmations. need to wait for confirmations.
- You get the full speed benefits of Tendermint; Transactions commit
- You get the full speed benefits of Tendermint; transactions commit
instantly. instantly.
- You can get the most recent version of the application state - You can get the most recent version of the application state
non-interactively (without committing anything to the blockchain). non-interactively (without committing anything to the blockchain).


+ 2
- 2
docs/secure-p2p.rst View File

@ -62,8 +62,8 @@ such as the Web-of-Trust or Certificate Authorities. In our case, we can
use the blockchain itself as a certificate authority to ensure that we use the blockchain itself as a certificate authority to ensure that we
are connected to at least one validator. are connected to at least one validator.
Links
-----
Additional Reading
------------------
- `Implementation <https://github.com/tendermint/go-p2p/blob/master/secret_connection.go#L49>`__ - `Implementation <https://github.com/tendermint/go-p2p/blob/master/secret_connection.go#L49>`__
- `Original STS paper by Whitfield Diffie, Paul C. van Oorschot and - `Original STS paper by Whitfield Diffie, Paul C. van Oorschot and


+ 1
- 1
docs/specification.rst View File

@ -2,7 +2,7 @@
Specification Specification
############# #############
Here you'll details of the Tendermint specification. See `the spec repo <https://github.com/tendermint/spec>`__ for upcoming material. Tendermint's types are produced by `godoc <https://godoc.org/github.com/tendermint/tendermint/types>`__
Here you'll find details of the Tendermint specification. See `the spec repo <https://github.com/tendermint/spec>`__ for upcoming material. Tendermint's types are produced by `godoc <https://godoc.org/github.com/tendermint/tendermint/types>`__
.. toctree:: .. toctree::
:maxdepth: 2 :maxdepth: 2


+ 3
- 12
docs/using-tendermint.rst View File

@ -2,7 +2,7 @@ Using Tendermint
================ ================
This is a guide to using the ``tendermint`` program from the command This is a guide to using the ``tendermint`` program from the command
line. It assumes only that you `have tendermint installed </download>`__
line. It assumes only that you have the ``tendermint`` binary installed
and have some rudimentary idea of what Tendermint and ABCI are. and have some rudimentary idea of what Tendermint and ABCI are.
You can see the help menu with ``tendermint --help``, and the version You can see the help menu with ``tendermint --help``, and the version
@ -117,7 +117,7 @@ Configuration
------------- -------------
Tendermint uses a ``config.toml`` for configutation. For details, see Tendermint uses a ``config.toml`` for configutation. For details, see
`the documentation </docs/specs/configuration>`__.
`the documentation <./configuration.html>`__.
Notable options include the socket address of the application Notable options include the socket address of the application
(``proxy_app``), the listenting address of the tendermint peer (``proxy_app``), the listenting address of the tendermint peer
@ -342,7 +342,7 @@ failing, you need at least four validator nodes (> 2/3).
Updating validators in a live network is supported but must be Updating validators in a live network is supported but must be
explicitly programmed by the application developer. See the `application explicitly programmed by the application developer. See the `application
developers guide </docs/guides/app-development#Handshake>`__ for more
developers guide <./app-development.html#Handshake>`__ for more
details. details.
Local Network Local Network
@ -354,12 +354,3 @@ the listening addresses of the various sockets don't conflict.
Additionally, you must set ``addrbook_strict=false`` in the Additionally, you must set ``addrbook_strict=false`` in the
``config.toml``, otherwise Tendermint's p2p library will deny making ``config.toml``, otherwise Tendermint's p2p library will deny making
connections to peers with the same IP address. connections to peers with the same IP address.
More
----
Got a couple nodes talking to each other using the dummy app? Try a more
sophisticated app like
`Ethermint <https://github.com/tendermint/ethermint>`__, or learn more
about building your own in the `Application Developer's
Guide </docs/guides/app-development>`__.

+ 5
- 5
docs/validators.rst View File

@ -25,7 +25,7 @@ Becoming a Validator
There are two ways to become validator. There are two ways to become validator.
1. They can be pre-established in the `genesis 1. They can be pre-established in the `genesis
state </docs/specs/genesis>`__
state <./genesis.html>`__
2. The `ABCI app responds to the EndBlock 2. The `ABCI app responds to the EndBlock
message <https://github.com/tendermint/abci>`__ with changes to the message <https://github.com/tendermint/abci>`__ with changes to the
existing validator set. existing validator set.
@ -36,9 +36,9 @@ Committing a Block
*+2/3 is short for "more than 2/3"* *+2/3 is short for "more than 2/3"*
A block is committed when +2/3 of the validator set sign `precommit A block is committed when +2/3 of the validator set sign `precommit
votes </docs/specs/block-structure#vote>`__ for that block at the same
`round </docs/specs/consensus>`__. The +2/3 set of precommit votes is
called a `*commit* </docs/specs/block-structure#commit>`__. While any
votes <./block-structure.html#vote>`__ for that block at the same
``round``. The +2/3 set of precommit votes is
called a `*commit* <./block-structure.html#commit>`__. While any
+2/3 set of precommits for the same block at the same height&round can +2/3 set of precommits for the same block at the same height&round can
serve as validation, the canonical commit is included in the next block serve as validation, the canonical commit is included in the next block
(see `LastCommit </docs/specs/block-structure>`__.
(see `LastCommit <./block-structure.html>`__).

Loading…
Cancel
Save