-
Notifications
You must be signed in to change notification settings - Fork 95
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[NU-1772] Scenario activities BE - phase 3 - periodic deployment acti…
…vities (#6971)
- Loading branch information
Showing
42 changed files
with
787 additions
and
148 deletions.
There are no files selected for viewing
7 changes: 6 additions & 1 deletion
7
...manager-api/src/main/scala/pl/touk/nussknacker/engine/DeploymentManagerDependencies.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
...i/src/main/scala/pl/touk/nussknacker/engine/api/deployment/ScenarioActivityHandling.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package pl.touk.nussknacker.engine.api.deployment | ||
|
||
import pl.touk.nussknacker.engine.api.process.ProcessIdWithName | ||
|
||
import scala.concurrent.Future | ||
|
||
sealed trait ScenarioActivityHandling | ||
|
||
object ScenarioActivityHandling { | ||
|
||
case object AllScenarioActivitiesStoredByNussknacker extends ScenarioActivityHandling | ||
|
||
trait ManagerSpecificScenarioActivitiesStoredByManager extends ScenarioActivityHandling { | ||
|
||
def managerSpecificScenarioActivities( | ||
processIdWithName: ProcessIdWithName | ||
): Future[List[ScenarioActivity]] | ||
|
||
} | ||
|
||
} |
41 changes: 41 additions & 0 deletions
41
...pi/src/main/scala/pl/touk/nussknacker/engine/api/deployment/ScenarioActivityManager.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package pl.touk.nussknacker.engine.api.deployment | ||
|
||
import pl.touk.nussknacker.engine.api.deployment.ScenarioActivityManager.ModificationResult | ||
|
||
import scala.concurrent.Future | ||
|
||
trait ScenarioActivityManager { | ||
|
||
def saveActivity( | ||
scenarioActivity: ScenarioActivity | ||
): Future[Unit] | ||
|
||
def modifyActivity( | ||
scenarioActivityId: ScenarioActivityId, | ||
modify: ScenarioActivity => ScenarioActivity, | ||
): Future[ModificationResult] | ||
|
||
} | ||
|
||
object ScenarioActivityManager { | ||
sealed trait ModificationResult | ||
|
||
object ModificationResult { | ||
case object Success extends ModificationResult | ||
case object Failure extends ModificationResult | ||
} | ||
|
||
} | ||
|
||
object NoOpScenarioActivityManager extends ScenarioActivityManager { | ||
|
||
def saveActivity( | ||
scenarioActivity: ScenarioActivity | ||
): Future[Unit] = Future.unit | ||
|
||
def modifyActivity( | ||
scenarioActivityId: ScenarioActivityId, | ||
modify: ScenarioActivity => ScenarioActivity, | ||
): Future[ModificationResult] = Future.successful(ModificationResult.Success) | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.