Skip to content

Commit

Permalink
Address comments
Browse files Browse the repository at this point in the history
  • Loading branch information
vancexu committed Feb 9, 2018
1 parent fa16809 commit c3ae1db
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions tools/cassandra/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,21 @@ How
---
- Run make bins
- You should see an executable `cadence-cassandra-tool`
- Make sure you already created cadence and visibility keyspaces (see `keyspace.cql` in schema)

Setting up initial cassandra schema on a new cluster
Setting up cassandra schema on a new cluster using Makefile
----------------------------------------------------
```
make install-schema
```

Setting up schema on a new cluster manually
----------------------------------------------------
```
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence setup-schema -v 0.0 -- this sets up just the schema version tables with initial version of 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence update-schema -d ./schema/cadence/versioned -- upgrades your schema to the latest version
./cadence-cassandra-tool -ep 127.0.0.1 -k visibility setup-schema -v 0.0 -- this sets up just the schema version tables with initial version of 0.0 for visibility
./cadence-cassandra-tool -ep 127.0.0.1 -k visibility update-schema -d ./schema/visibility/versioned -- upgrades your schema to the latest version for visibility
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility setup-schema -v 0.0 -- this sets up just the schema version tables with initial version of 0.0 for visibility
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility update-schema -d ./schema/visibility/versioned -- upgrades your schema to the latest version for visibility
```

Updating schema on an existing cluster
Expand All @@ -26,6 +31,6 @@ You can only upgrade to a new version after the initial setup done above.
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence update-schema -d ./schema/cadence/versioned -v x.x -y -- executes a dryrun of upgrade to version x.x
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence update-schema -d ./schema/cadence/versioned -v x.x -- actually executes the upgrade to version x.x
./cadence-cassandra-tool -ep 127.0.0.1 -k visibility update-schema -d ./schema/visibility/versioned -v x.x -y -- executes a dryrun of upgrade to version x.x
./cadence-cassandra-tool -ep 127.0.0.1 -k visibility update-schema -d ./schema/visibility/versioned -v x.x -- actually executes the upgrade to version x.x
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility update-schema -d ./schema/visibility/versioned -v x.x -y -- executes a dryrun of upgrade to version x.x
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility update-schema -d ./schema/visibility/versioned -v x.x -- actually executes the upgrade to version x.x
```

0 comments on commit c3ae1db

Please sign in to comment.