Package dev.galasa.framework.spi
Interface IFrameworkRuns
- All Known Implementing Classes:
FrameworkRuns
public interface IFrameworkRuns
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionvoidaddRunRasAction(IRun run, RunRasAction rasActionToAdd) voidclearRunInterrupt(String runName) Clears all interrupt-related properties for a run with the given name from the DSS.booleangetAllGroupedRuns(@NotNull String groupName) getCpsPropertiesAndOverridesUsedByTestRun(String runName, List<String> namespaces) Returns a map of CPS properties and overrides that were used by a test run with the given run name.booleanmarkRunCancelling(String runName, TestRunLifecycleStatus currentStatus) Marks the specified run as finished in the DSS.voidmarkRunFinished(String runName, String result) booleanmarkRunInterrupted(String runName, String interruptReason) boolean@NotNull IRunsubmitRun(String type, String requestor, String bundleName, String testName, String groupName, String mavenRepository, String obr, String stream, boolean local, boolean trace, Set<String> tags, Properties overrides, IFrameworkRuns.SharedEnvironmentPhase sharedEnvironmentPhase, String sharedEnvironmentRunName, String language, String submissionId)
-
Method Details
-
getActiveRuns
- Throws:
FrameworkException
-
getQueuedRuns
- Throws:
FrameworkException
-
getAllRuns
- Throws:
FrameworkException
-
getAllGroupedRuns
@NotNull @NotNull List<IRun> getAllGroupedRuns(@NotNull @NotNull String groupName) throws FrameworkException - Throws:
FrameworkException
-
getActiveRunNames
- Throws:
FrameworkException
-
delete
- Throws:
DynamicStatusStoreException
-
getRun
- Throws:
DynamicStatusStoreException
-
reset
- Throws:
DynamicStatusStoreException
-
markRunInterrupted
boolean markRunInterrupted(String runName, String interruptReason) throws DynamicStatusStoreException - Throws:
DynamicStatusStoreException
-
clearRunInterrupt
Clears all interrupt-related properties for a run with the given name from the DSS.- Parameters:
runName- the run to remove interrupt properties for- Throws:
DynamicStatusStoreException- if there was an issue accessing the DSS
-
markRunFinished
- Throws:
DynamicStatusStoreException
-
markRunCancelling
boolean markRunCancelling(String runName, TestRunLifecycleStatus currentStatus) throws DynamicStatusStoreException Marks the specified run as finished in the DSS. Only if the state of the test run is as we expect. Other processes may have moved the status of the test run without us knowing.- Parameters:
runName-currentStatus- The current status of the test run, the status we want to change it from- Returns:
- True if the test was marked as finished, false if not. For example, someother process marked it as starting or building ahead of us marking it as finished here.
- Throws:
DynamicStatusStoreException
-
addRunRasAction
- Throws:
DynamicStatusStoreException
-
getCpsPropertiesAndOverridesUsedByTestRun
Map<String,String> getCpsPropertiesAndOverridesUsedByTestRun(String runName, List<String> namespaces) throws FrameworkException Returns a map of CPS properties and overrides that were used by a test run with the given run name. The returned map combines the current CPS properties from the given namespaces with the overrides associated with the given test run, so any overrides that were used will take precedence. If no test run with the given run name exists, then the current CPS properties from the provided namespaces will be returned.- Parameters:
runName- the name of the existing test run to get the CPS properties that were usednamespaces- a list of CPS namespaces to get CPS properties from- Returns:
- a map of CPS properties combined with any overrides for the given test run
- Throws:
FrameworkException- if there was an issue accessing the CPS or the DSS
-