[
https://issues.apache.org/jira/browse/GOBBLIN-2131?focusedWorklogId=930455&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-930455
]
ASF GitHub Bot logged work on GOBBLIN-2131:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 15/Aug/24 16:45
Start Date: 15/Aug/24 16:45
Worklog Time Spent: 10m
Work Description: arjun4084346 commented on code in PR #4024:
URL: https://github.com/apache/gobblin/pull/4024#discussion_r1718687096
##########
gobblin-service/src/main/java/org/apache/gobblin/service/monitoring/DagActionStoreChangeMonitor.java:
##########
@@ -146,15 +148,26 @@ protected void initializeMonitor() {
throw new RuntimeException(String.format("Unable to retrieve dagActions
from the dagActionStore while "
+ "initializing the %s",
DagActionStoreChangeMonitor.class.getCanonicalName()), e);
}
- // TODO: make this multi-threaded to add parallelism
+ final ExecutorService executorService =
Executors.newFixedThreadPool(ConfigUtils.getInt(this.config,ConfigurationKeys.DAG_ACTION_STORE_MONITOR_EXECUTOR_THREADS,1));
+
for (DagActionStore.DagAction action : dagActions) {
try {
- handleDagAction(action, true);
+ executorService.submit(()->handleDagAction(action, true));
} catch (Exception e) {
log.error("Unexpected error initializing from DagActionStore changes,
upon {}", action, e);
this.unexpectedErrors.mark();
}
}
+ try {
+ boolean executedSuccessfully=
executorService.awaitTermination(ConfigUtils.getInt(this.config,ConfigurationKeys.DAG_ACTION_STORE_MONITOR_EXECUTOR_TIMEOUT_SECONDS,30),TimeUnit.SECONDS);
+ if(!executedSuccessfully){
Review Comment:
space, `if (!executedSuccessfully) {`
Issue Time Tracking
-------------------
Worklog Id: (was: 930455)
Time Spent: 50m (was: 40m)
> process all dag actions by multiple threads on initialization
> -------------------------------------------------------------
>
> Key: GOBBLIN-2131
> URL: https://issues.apache.org/jira/browse/GOBBLIN-2131
> Project: Apache Gobblin
> Issue Type: Bug
> Reporter: Aditya Pratap Singh
> Priority: Minor
> Time Spent: 50m
> Remaining Estimate: 0h
>
> process all dag actions by multiple threads on initialization
--
This message was sent by Atlassian Jira
(v8.20.10#820010)