docs: remove traces of develop branch (#4022)

* Develop -> Master

- Some places still had develop instead of master.

closes #4107

Signed-off-by: Marko Baricevic <marbar3778@yahoo.com>

* add one more
This commit is contained in:
Marko
2019-09-27 15:16:19 -07:00
committed by Anton Kaliaev
parent b065b8a0c5
commit cb1a0a7333
7 changed files with 49 additions and 19 deletions

View File

@ -66,10 +66,13 @@ $ cd $KVSTORE_HOME
```
Inside the example directory run:
```sh
gradle init --dsl groovy --package io.example --project-name example --type kotlin-application
```
This will create a new project for you. The tree of files should look like:
```sh
$ tree
.
@ -108,13 +111,14 @@ Hello world.
Tendermint Core communicates with the application through the Application
BlockChain Interface (ABCI). All message types are defined in the [protobuf
file](https://github.com/tendermint/tendermint/blob/develop/abci/types/types.proto).
file](https://github.com/tendermint/tendermint/blob/master/abci/types/types.proto).
This allows Tendermint Core to run applications written in any programming
language.
### 1.3.1 Compile .proto files
Add the following piece to the top of the `build.gradle`:
```groovy
buildscript {
repositories {
@ -127,6 +131,7 @@ buildscript {
```
Enable the protobuf plugin in the `plugins` section of the `build.gradle`:
```groovy
plugins {
id 'com.google.protobuf' version '0.8.8'
@ -134,6 +139,7 @@ plugins {
```
Add the following code to `build.gradle`:
```groovy
protobuf {
protoc {
@ -154,8 +160,8 @@ protobuf {
Now we should be ready to compile the `*.proto` files.
Copy the necessary `.proto` files to your project:
```sh
mkdir -p \
$KVSTORE_HOME/src/main/proto/github.com/tendermint/tendermint/abci/types \
@ -174,6 +180,7 @@ cp $GOPATH/src/github.com/gogo/protobuf/gogoproto/gogo.proto \
```
Add these dependencies to `build.gradle`:
```groovy
dependencies {
implementation 'io.grpc:grpc-protobuf:1.22.1'
@ -183,10 +190,13 @@ dependencies {
```
To generate all protobuf-type classes run:
```sh
./gradlew generateProto
```
To verify that everything went smoothly, you can inspect the `build/generated/` directory:
```sh
$ tree build/generated/
build/generated/
@ -215,6 +225,7 @@ The resulting `$KVSTORE_HOME/build/generated/source/proto/main/grpc/types/ABCIAp
contains the abstract class `ABCIApplicationImplBase`, which is an interface we'll need to implement.
Create `$KVSTORE_HOME/src/main/kotlin/io/example/KVStoreApp.kt` file with the following content:
```kotlin
package io.example
@ -223,7 +234,7 @@ import types.ABCIApplicationGrpc
import types.Types.*
class KVStoreApp : ABCIApplicationGrpc.ABCIApplicationImplBase() {
// methods implementation
}
@ -293,6 +304,7 @@ For the underlying key-value store we'll use
[JetBrains Xodus](https://github.com/JetBrains/xodus), which is a transactional schema-less embedded high-performance database written in Java.
`build.gradle`:
```groovy
dependencies {
implementation 'org.jetbrains.xodus:xodus-environment:1.3.91'
@ -329,7 +341,7 @@ class KVStoreApp(
When Tendermint Core has decided on the block, it's transferred to the
application in 3 parts: `BeginBlock`, one `DeliverTx` per transaction and
`EndBlock` in the end. `DeliverTx` are being transferred asynchronously, but the
`EndBlock` in the end. `DeliverTx` are being transferred asynchronously, but the
responses are expected to come in order.
```kotlin
@ -341,6 +353,7 @@ override fun beginBlock(req: RequestBeginBlock, responseObserver: StreamObserver
responseObserver.onCompleted()
}
```
Here we begin a new transaction, which will accumulate the block's transactions and open the corresponding store.
```kotlin
@ -443,6 +456,7 @@ Here we create a special object `Environment`, which knows where to store the ap
Then we create and start the gRPC server to handle Tendermint Core requests.
Create `$KVSTORE_HOME/src/main/kotlin/io/example/GrpcServer.kt` file with the following content:
```kotlin
package io.example