[ 
https://issues.apache.org/jira/browse/GOBBLIN-2002?focusedWorklogId=904949&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-904949
 ]

ASF GitHub Bot logged work on GOBBLIN-2002:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 14/Feb/24 17:27
            Start Date: 14/Feb/24 17:27
    Worklog Time Spent: 10m 
      Work Description: phet commented on code in PR #3878:
URL: https://github.com/apache/gobblin/pull/3878#discussion_r1489796883


##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/orchestration/DagManagementStateStore.java:
##########
@@ -74,16 +78,10 @@ public interface DagManagementStateStore {
    */
   List<Dag<JobExecutionPlan>> getDags() throws IOException;
 
-  /**
-   * Return a list of all dag IDs contained in the dag state store.
-   */
-  Set<String> getDagIds() throws IOException;
-  Set<String> getFailedDagIds() throws IOException;
-
   /**
    * Initialize with the provided set of dags.
    */
-  void initQuotaManageer(Collection<Dag<JobExecutionPlan>> dags) throws 
IOException;
+  void initQuota(Collection<Dag<JobExecutionPlan>> dags) throws IOException;

Review Comment:
   thinking more on this... 
   
   while I'm not against having a method like this `@VisibleForTesting` or even 
kept around in case the need later arises (e.g. `@Alpha / @Experimental`), 
still, if it's actually used as I expect, which is:
   - at host startup
   - in conjunction w/ the list of `Dag`s retrieved from the same DMSS instance
   
   then let's explore encapsulating the entire interaction.  e.g. a new method 
(`selfInitialize` or `autoInitialize`):
   ```
   void uponStartup() throws IOException {
     initQuota(getAllDags())
   }
   ```
   
   (it's still fine even if the DMSS impl makes `initQuota` into a no-op.)
   
   what I'm pulling for is a clearer conceptual interface for those using this 
interface.  so the `GobblinServiceManager` (or whoever initializes the DMSS 
singleton), would simply invoke:
   ```
   this.dmss.uponStartup();  // just `start()`?
   ```
   
   the way it currently does:
   ```
   this.dagManager.setActive(true);
   ```





Issue Time Tracking
-------------------

    Worklog Id:     (was: 904949)
    Time Spent: 2.5h  (was: 2h 20m)

> create MostlyInMemoryDagManagementStateStore to merge UserQuotaManager, 
> DagStateStore and in-memory dag maps used in DagManager
> -------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: GOBBLIN-2002
>                 URL: https://issues.apache.org/jira/browse/GOBBLIN-2002
>             Project: Apache Gobblin
>          Issue Type: Improvement
>            Reporter: Arjun Singh Bora
>            Priority: Major
>          Time Spent: 2.5h
>  Remaining Estimate: 0h
>
> this will help in refactoring DagManager



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to