You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@gobblin.apache.org by GitBox <gi...@apache.org> on 2022/09/08 20:37:39 UTC
[GitHub] [gobblin] arjun4084346 commented on a diff in pull request #3550: avoid double quota increase for adhoc flows
arjun4084346 commented on code in PR #3550:
URL: https://github.com/apache/gobblin/pull/3550#discussion_r966398733
##########
gobblin-service/src/main/java/org/apache/gobblin/service/modules/scheduler/GobblinServiceJobScheduler.java:
##########
@@ -335,7 +335,9 @@ public AddSpecResponse onAddSpec(Spec addedSpec) {
if (quotaManager.isPresent()) {
// QuotaManager has idempotent checks for a dagNode, so this check won't double add quotas for a flow in the DagManager
try {
+ // todo : we should probably check quota for all of the start nodes
quotaManager.get().checkQuota(dag.getNodes().get(0));
+ ((FlowSpec) addedSpec).getConfigAsProperties().setProperty(ServiceConfigKeys.GOBBLIN_SERVICE_ADHOC_FLOW, "true");
Review Comment:
Actually, the FlowSpec created by `createFlowSpecForConfig` will be persisted in the spec store. If we add the config there, it will be persisted permanently in the spec store. And then we will not be able to distinguish if it is a scheduled run or the adhoc run of a "schedule with runImmediately=true" kind of flows.
cc @ZihanLi58
--
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: dev-unsubscribe@gobblin.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org