Skip to content

Commit

Permalink
Refactor port for gossip-addr 9100->8400
Browse files Browse the repository at this point in the history
  • Loading branch information
iknite committed Feb 19, 2019
1 parent 10aafcf commit 27cc343
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion cmd/start.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func newStartCommand(ctx *cmdContext) *cobra.Command {
f.StringVar(&conf.MgmtAddr, "mgmt-addr", ":8700", "Management endpoint bind address (host:port)")
f.StringVar(&conf.MgmtAddr, "metrics-addr", ":8600", "Metrics export bind address (host:port)")
f.StringSliceVar(&conf.RaftJoinAddr, "join-addr", []string{}, "Raft: Comma-delimited list of nodes ([host]:port), through which a cluster can be joined")
f.StringVar(&conf.GossipAddr, "gossip-addr", ":9100", "Gossip: management endpoint bind address (host:port)")
f.StringVar(&conf.GossipAddr, "gossip-addr", ":8400", "Gossip: management endpoint bind address (host:port)")
f.StringSliceVar(&conf.GossipJoinAddr, "gossip-join-addr", []string{}, "Gossip: Comma-delimited list of nodes ([host]:port), through which a cluster can be joined")

// INFO: testing purposes
Expand Down
6 changes: 3 additions & 3 deletions config.example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ server:
raft: ":8500" # Raft bind address (host:port). internal message passing
raft_join: # Raft: list of nodes ([host]:port), where the node can join the cluster using the mgmt endpoint
- "127.0.0.1:8700"
gossip: ":9100" # Gossip: management endpoint bind address (host:port).
gossip: ":8400" # Gossip: management endpoint bind address (host:port).
gossip_join: # Gossip: list of nodes ([host]:port), through which a cluster can be joined.
- "127.0.0.1:9100"
- "127.0.0.1:8400"
path:
db: "/var/tmp/qed/db" # Set default storage path.
wal: "/var/tmp/qed/wal" # Set raft storage path.
Expand All @@ -69,7 +69,7 @@ agent:
bind: ":9200" # Bind address for TCP/UDP gossip on (host:port)
advertise: "" # Address to advertise to cluster
join: # Comma-delimited list of nodes ([host]:port), through which a cluster can be joined
- "127.0.0.1:9100"
- "127.0.0.1:8400"
alert_urls: # List of Alert servers ([host]:port), through which an agent can post alerts
- "127.0.0.1:8888"
server_urls: # List of QED servers ([host]:port), through which an auditor can make queries
Expand Down
18 changes: 9 additions & 9 deletions deploy/aws/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module "leader" {
http: ":8800"
mgmt: ":8700"
raft: ":8500"
gossip: ":9100"
gossip: ":8400"
CONFIG

}
Expand All @@ -63,11 +63,11 @@ module "follower-1" {
http: ":8800"
mgmt: ":8700"
raft: ":8500"
gossip: ":9100"
gossip: ":8400"
raft_join:
- "${module.leader.private_ip}:8700"
gossip_join:
- "${module.leader.private_ip}:9100"
- "${module.leader.private_ip}:8400"
CONFIG

}
Expand All @@ -92,11 +92,11 @@ module "follower-2" {
http: ":8800"
mgmt: ":8700"
raft: ":8500"
gossip: ":9100"
gossip: ":8400"
raft_join:
- "${module.leader.private_ip}:8700"
gossip_join:
- "${module.leader.private_ip}:9100"
- "${module.leader.private_ip}:8400"
CONFIG
}

Expand Down Expand Up @@ -131,7 +131,7 @@ module "follower-2" {
# bind: ":9300"
# advertise: ""
# join:
# - "${module.leader.private_ip}:9100"
# - "${module.leader.private_ip}:8400"
# server_urls:
# - "${module.leader.private_ip}:8800"
# alert_urls:
Expand Down Expand Up @@ -162,7 +162,7 @@ module "follower-2" {
# bind: ":9200"
# advertise: ""
# join:
# - "${module.leader.private_ip}:9100"
# - "${module.leader.private_ip}:8400"
# server_urls:
# - "${module.leader.private_ip}:8800"
# alert_urls:
Expand All @@ -189,10 +189,10 @@ module "follower-2" {
# path: "/var/tmp/qed/"
# agent:
# node: "auditor"
# bind: ":9100"
# bind: ":8400"
# advertise: ""
# join:
# - "${module.leader.private_ip}:9100"
# - "${module.leader.private_ip}:8400"
# server_urls:
# - "${module.leader.private_ip}:8800"
# alert_urls:
Expand Down
4 changes: 2 additions & 2 deletions docs/advanced_usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ To be production-ready, both services must be developed and deployed separatelly

```bash
# this variables will be used in all the publiser, auditor and monitor examples.
export masterEndpoint="127.0.0.1:9100"
export masterEndpoint="127.0.0.1:8400"
export publisherEndpoint="http://127.0.0.1:8888"
export alertsEndpoint="http://127.0.0.1:8888"
export qedEndpoint="http://127.0.0.1:8800"
Expand All @@ -109,7 +109,7 @@ go run main.go agent \
--alertsUrls $alertsEndpoint \
auditor \
-k my-key \
--bind 127.0.0.1:9100 \
--bind 127.0.0.1:8400 \
--join $masterEndpoint \
--qedUrls $qedEndpoint \
--pubUrls $publisherEndpoint \
Expand Down
2 changes: 1 addition & 1 deletion server/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ func DefaultConfig() *Config {
MgmtAddr: "127.0.0.1:8700",
MetricsAddr: "127.0.0.1:8600",
RaftJoinAddr: []string{},
GossipAddr: "127.0.0.1:9100",
GossipAddr: "127.0.0.1:8400",
GossipJoinAddr: []string{},
DBPath: currentDir + "/db",
RaftPath: currentDir + "/wal",
Expand Down
2 changes: 1 addition & 1 deletion tests/gossip/run_gossip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

qedGossipEndpoint="127.0.0.1:9100"
qedGossipEndpoint="127.0.0.1:8400"
snapshotStoreEndpoint="http://127.0.0.1:8888"
alertsStoreEndpoint="http://127.0.0.1:8888"
qedHTTPEndpoint="http://127.0.0.1:8800"
Expand Down

0 comments on commit 27cc343

Please sign in to comment.