Skip to content

Commit

Permalink
[ISSUE-203][BUG] fix rss.master.address not work in rss-worker's conf…
Browse files Browse the repository at this point in the history
…iguration file issue (#204)
  • Loading branch information
dxheming authored Jun 30, 2022
1 parent 909e8b2 commit 7f6e228
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
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

0 comments on commit 7f6e228

Please sign in to comment.