Some commands are already implemented in the app, lets try them:
~~~~
inc testbucket mycounter
getcounter testbucket mycounter
additem testbucket myset newitem
getset testbucket myset
~~~~
To stop the app:
~~~~
quit
~~~~
You can also try to disconnect Antidote servers to simulate network partitions, commit some concurrent updates, then reconnect to merge CRDTs:
~~~~bash
# in setup/
./disconnect.sh #to disrupt communication between Antidote1 and Antidote2 nodes
#then update objects while disconnected
./connect.sh #connect Antidote nodes back
~~~~
To stop Antidote Nodes:
```bash
# in setup/
./stop_antidote.sh
```
### Step 5 : Hands On!!!
We now want to build our Bookstore app. The provided sources are divided into 3 files (located in bookstore/src/main/):
*`BookStore.java`: this file contains the command interface and the starting point of the app.
*`DemoCommandsExecutor.java`: this file contains the implementation of the demo commands we have seen in the previous Step. You can use them as examples to implement your own commands.
*`BookCommands.java`: Here is the file where you need to implement Bookstore commands, fill in the methods to add necessary.
### Resources:
Some useful references:
*[Antidote API Javadoc](https://www.javadoc.io/doc/eu.antidotedb/antidote-java-client/0.3.1)