umustafi commented on code in PR #3899:
URL: https://github.com/apache/gobblin/pull/3899#discussion_r1540239719


##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/orchestration/DagManagementTaskStreamImpl.java:
##########
@@ -53,18 +75,29 @@ public class DagManagementTaskStreamImpl implements 
DagManagement, DagTaskStream
 
   @Inject(optional=true)
   protected Optional<DagActionStore> dagActionStore;
-  protected Optional<ReminderSettingDagProcLeaseArbiter> 
reminderSettingDagProcLeaseArbiter;
+  @Inject
+  @Named(ConfigurationKeys.EXECUTOR_LEASE_ARBITER_NAME)
+  protected InstrumentedLeaseArbiter dagActionExecutionLeaseArbiter;
+  protected Optional<DagActionReminderScheduler> dagActionReminderScheduler;
+  @Inject
+  @Named(InjectionNames.MULTI_ACTIVE_EXECUTION_ENABLED)
+  private final boolean isMultiActiveExecutionEnabled;
   @Inject
   private static final int MAX_HOUSEKEEPING_THREAD_DELAY = 180;
   private final BlockingQueue<DagActionStore.DagAction> dagActionQueue = new 
LinkedBlockingQueue<>();
+  private final String MISSING_OPTIONAL_ERROR_MESSAGE = 
String.format("Multi-active execution enabled but required "
+      + "instance %s is absent.", 
DagActionReminderScheduler.class.getSimpleName());
 
-  // TODO: need to pass reference to DagProcLeaseArbiter without creating a 
circular reference in Guice
   @Inject
   public DagManagementTaskStreamImpl(Config config, Optional<DagActionStore> 
dagActionStore,
-      Optional<ReminderSettingDagProcLeaseArbiter> 
reminderSettingDagProcLeaseArbiter) {
+      @Named(ConfigurationKeys.EXECUTOR_LEASE_ARBITER_NAME) 
InstrumentedLeaseArbiter dagActionExecutionLeaseArbiter,
+      Optional<DagActionReminderScheduler> dagActionReminderScheduler,
+      @Named(InjectionNames.MULTI_ACTIVE_EXECUTION_ENABLED) boolean 
isMultiActiveExecutionEnabled) {

Review Comment:
   We should only need it on the ctor param for how I defined it. I added these 
while debugging the optional guice binding with annotations but no longer 
needed. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to