Skip to content

Commit

Permalink
Fix create worker process timeout #13771
Browse files Browse the repository at this point in the history
  • Loading branch information
“shenghui361” committed Jul 11, 2021
1 parent cf79c78 commit f3e40ba
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 9 additions & 0 deletions core/common/src/main/java/alluxio/conf/PropertyKey.java
Original file line number Diff line number Diff line change
Expand Up @@ -3508,6 +3508,13 @@ public String toString() {
.setConsistencyCheckLevel(ConsistencyCheckLevel.WARN)
.setScope(Scope.WORKER)
.build();
public static final PropertyKey WORKER_REGISTRY_GET_TIMEOUT_MS =
new Builder(Name.WORKER_REGISTRY_GET_TIMEOUT_MS)
.setDefaultValue("600000")
.setDescription("The timeout of getting a worker from the registry.")
.setConsistencyCheckLevel(ConsistencyCheckLevel.IGNORE)
.setScope(Scope.WORKER)
.build();

//
// Proxy related properties
Expand Down Expand Up @@ -5935,6 +5942,8 @@ public static final class Name {
"alluxio.worker.ufs.instream.cache.enabled";
public static final String WORKER_UFS_INSTREAM_CACHE_MAX_SIZE =
"alluxio.worker.ufs.instream.cache.max.size";
public static final String WORKER_REGISTRY_GET_TIMEOUT_MS =
"alluxio.worker.registry.get.timeout";

//
// Proxy related properties
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ public final class AlluxioWorkerProcess implements WorkerProcess {
// registered at worker registry, so the maximum timeout here is set to the multiply of
// the number of factories by the default timeout of getting a worker from the registry.
CommonUtils.invokeAll(callables,
(long) callables.size() * 10 * Constants.DEFAULT_REGISTRY_GET_TIMEOUT_MS);
(long) callables.size() * ServerConfiguration.getLong(PropertyKey.WORKER_REGISTRY_GET_TIMEOUT_MS));

// Setup web server
mWebServer =
Expand Down

0 comments on commit f3e40ba

Please sign in to comment.