-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Support joining nodes to an existing cluster #3372
Changes from 1 commit
abfd438
e06f6f4
3f90891
9db3a77
cb718b9
43f0407
5486d3e
ad8948b
a7fa5eb
f3fcfeb
5ea8342
fb8a4db
33730da
9e43397
b86fecf
80248f9
72e2e1a
17a9bb0
a9314d6
54e1165
790733d
85db9c4
29b11a2
c1fc83e
84a8d7d
b78ac4b
29011c5
eb7d181
47b8de7
e904416
9dd66fa
3c308e3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
Useful for troubleshooting but too verbose for regular use.
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,17 +37,18 @@ type Config struct { | |
HeartbeatTimeout toml.Duration `toml:"heartbeat-timeout"` | ||
LeaderLeaseTimeout toml.Duration `toml:"leader-lease-timeout"` | ||
CommitTimeout toml.Duration `toml:"commit-timeout"` | ||
ClusterTracing bool `toml:"cluster-tracing"` | ||
|
||
// The join command-line argument | ||
join string | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is this unexported? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It's set as a command-line arg. It it's public, There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you do There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'll try. But the |
||
} | ||
|
||
func (c Config) SetJoin(join string) { | ||
func (c *Config) SetJoin(join string) { | ||
c.join = join | ||
} | ||
|
||
func NewConfig() Config { | ||
return Config{ | ||
func NewConfig() *Config { | ||
return &Config{ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why return a pointer? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The config needs to be modified if |
||
Hostname: DefaultHostname, | ||
BindAddress: DefaultBindAddress, | ||
RetentionAutoCreate: true, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps it will become apparent later, but why this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needed to set a private
join
value on the config if it's specified via the command-line.