Skip to content

Commit

Permalink
Update javadoc of tests
Browse files Browse the repository at this point in the history
  • Loading branch information
vsinghal85 committed Nov 19, 2024
1 parent 01cac22 commit b596948
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,8 @@


/**
* An {@link RuntimeException} thrown when lease cannot be acquired on provided entity.
* An exception thrown when another {@link FlowSpec} with same flow name and flow group
* is submitted within lease consolidation time.
*/
public class TooSoonToRerunSameFlowException extends RuntimeException {
@Getter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@

import org.apache.commons.io.FileUtils;
import org.apache.gobblin.config.ConfigBuilder;
import org.apache.gobblin.runtime.api.TooSoonToRerunSameFlowException;
import org.apache.gobblin.runtime.spec_catalog.AddSpecResponse;
import org.apache.gobblin.service.modules.flow.FlowUtils;
import org.apache.gobblin.service.modules.flow.SpecCompiler;
Expand Down Expand Up @@ -324,9 +325,9 @@ public void createFlowSpec() throws Throwable {
/*
If another flow has already acquired lease for this flowspec details within
lease consolidation time, then we do not execute this flow, hence do not process and store the spec
and throw RuntimeException
and throw TooSoonToRerunSameFlowException
*/
@Test(expectedExceptions = RuntimeException.class)
@Test(expectedExceptions = TooSoonToRerunSameFlowException.class)
public void onAddSpecForAdhocFlowWhenSimilarExistingFlowIsCurrentlyLaunching() throws IOException {
ConfigBuilder configBuilder = ConfigBuilder.create()
.addPrimitive(ConfigurationKeys.FLOW_GROUP_KEY, "testGroup")
Expand Down

0 comments on commit b596948

Please sign in to comment.