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

[ISSUE-203][BUG] fix rss.master.address not work in rss-worker's configuration file issue #204

Merged
merged 4 commits into from Jun 30, 2022
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
Original file line number Diff line number Diff line change
Expand Up @@ -979,7 +979,9 @@ private[deploy] object Worker extends Logging {
// much as possible. Therefore, if the user manually specifies the address of the Master when
// starting the Worker, we should set it in the parameters and automatically calculate what the
// address of the Master should be used in the end.
conf.set("rss.master.address", RpcAddress.fromRssURL(workerArgs.master).toString)
if (workerArgs.master != null) {
conf.set("rss.master.address", RpcAddress.fromRssURL(workerArgs.master).toString)
}

val metricsSystem = MetricsSystem.createMetricsSystem("worker", conf, WorkerSource.ServletPath)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class WorkerArguments(args: Array[String], conf: RssConf) {
var port = 0
// var master: String = null
// for local testing.
var master: String = s"rss://$host:9097"
var master: String = null
var propertiesFile: String = null

parse(args.toList)
Expand Down Expand Up @@ -58,9 +58,6 @@ class WorkerArguments(args: Array[String], conf: RssConf) {
parse(tail)

case Nil =>
if (master == null) { // No positional argument was given
printUsageAndExit(1)
}

case _ =>
printUsageAndExit(1)
Expand Down