Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add separate config files for cross dc #530

Merged
merged 2 commits into from
Feb 1, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 27 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -139,9 +139,34 @@ clean:
rm -Rf $(BUILD)

install-schema: bins
./cadence-cassandra-tool --ep 127.0.0.1 create -k "cadence" --rf 1
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence update-schema -d ./schema/cadence/versioned
./cadence-cassandra-tool --ep 127.0.0.1 create -k "cadence_visibility" --rf 1
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence_visibility --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility update-schema -d ./schema/visibility/versioned

start: bins
./cadence start

install-schema-cdc: bins
@echo Setting up cadence_active key space
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence_active --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_active setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_active update-schema -d ./schema/cadence/versioned
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence_visibility_active --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility_active setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility_active update-schema -d ./schema/visibility/versioned
@echo Setting up cadence_standby key space
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence_standby --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_standby setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_standby update-schema -d ./schema/cadence/versioned
./cadence-cassandra-tool --ep 127.0.0.1 create -k cadence_visibility_standby --rf 1
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility_standby setup-schema -v 0.0
./cadence-cassandra-tool -ep 127.0.0.1 -k cadence_visibility_standby update-schema -d ./schema/visibility/versioned

start-cdc-active: bins
./cadence --zone active start

start-cdc-standby: bins
./cadence --zone standby start
54 changes: 54 additions & 0 deletions config/development_active.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
cassandra:
hosts: "127.0.0.1"
keyspace: "cadence_active"
visibilityKeyspace: "cadence_visibility_active"
consistency: "One"
numHistoryShards: 4

ringpop:
name: cadence_active
bootstrapMode: hosts
bootstrapHosts: ["127.0.0.1:7933", "127.0.0.1:7934", "127.0.0.1:7935"]
maxJoinDuration: 30s

services:
frontend:
rpc:
port: 7933
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence_active"
pprof:
port: 7936

matching:
rpc:
port: 7935
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence_active"
pprof:
port: 7938

history:
rpc:
port: 7934
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence_active"
pprof:
port: 7937

clustersInfo:
initialFailoverVersion: 0
failoverVersionIncrement: 10
currentClusterName: "active"
clusterNames:
- "active"
- "standby"
54 changes: 54 additions & 0 deletions config/development_standby.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
cassandra:
hosts: "127.0.0.1"
keyspace: "cadence_standby"
visibilityKeyspace: "cadence_visibility_standby"
consistency: "One"
numHistoryShards: 4

ringpop:
name: cadence_standby
bootstrapMode: hosts
bootstrapHosts: ["127.0.0.1:8933", "127.0.0.1:8934", "127.0.0.1:8935"]
maxJoinDuration: 30s

services:
frontend:
rpc:
port: 8933
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence"
pprof:
port: 8936

matching:
rpc:
port: 8935
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence"
pprof:
port: 8938

history:
rpc:
port: 8934
bindOnLocalHost: true
metrics:
statsd:
hostPort: "127.0.0.1:8125"
prefix: "cadence"
pprof:
port: 8937

clustersInfo:
initialFailoverVersion: 1
failoverVersionIncrement: 10
currentClusterName: "standby"
clusterNames:
- "active"
- "standby"