-
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.
Merge branch 'refs/heads/staging' into NU-1694-add-datepicker-to-edit…
…or-table # Conflicts: # designer/client/cypress/e2e/__image_snapshots__/electron/Linux/Process with data should have counts button and modal #3.png
- Loading branch information
Showing
99 changed files
with
1,685 additions
and
612 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
#!/bin/bash -ex | ||
|
||
if [ -z "$NU_INSTALLATION_EXAMPLE_ACCESS_TOKEN" ]; then | ||
echo "NU_INSTALLATION_EXAMPLE_ACCESS_TOKEN variable has to be defined" | ||
exit 1 | ||
fi | ||
|
||
if [ -z "$NUSSKNACKER_VERSION" ]; then | ||
echo "NUSSKNACKER_VERSION variable has to be defined" | ||
exit 1 | ||
fi | ||
|
||
cleanup() { | ||
rm -rf nu-installation-example-repo | ||
} | ||
|
||
cleanup # just for sure | ||
|
||
trap cleanup EXIT | ||
|
||
git clone "https://$NU_INSTALLATION_EXAMPLE_ACCESS_TOKEN@github.com/TouK/nussknacker-installation-example.git" nu-installation-example-repo | ||
cd nu-installation-example-repo | ||
git remote set-url origin "https://$NU_INSTALLATION_EXAMPLE_ACCESS_TOKEN@github.com/TouK/nussknacker-installation-example.git" | ||
|
||
rm -rf ./* | ||
cp -r ../examples/installation/* . | ||
echo "NUSSKNACKER_VERSION=$NUSSKNACKER_VERSION" > .env | ||
|
||
git config user.email "actions@github.com" | ||
git config user.name "GitHub Actions" | ||
git add . | ||
git commit -m "Publishing $NUSSKNACKER_VERSION installation example" | ||
git tag "$NUSSKNACKER_VERSION" | ||
git push -f origin master --tags |
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
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
67 changes: 67 additions & 0 deletions
67
...nager-api/src/main/scala/pl/touk/nussknacker/engine/api/deployment/DeploymentStatus.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,67 @@ | ||
package pl.touk.nussknacker.engine.api.deployment | ||
|
||
import enumeratum.EnumEntry.UpperSnakecase | ||
import enumeratum.{Enum, EnumEntry} | ||
import io.circe.Codec | ||
import io.circe.generic.extras.semiauto.deriveUnwrappedCodec | ||
|
||
// Currently DeploymentStatus are limited set of allowed statuses. Only ProblemDeploymentStatus can have different | ||
// descriptions depending on DM implementation. It makes implementation of logic based on statuses easier. In case | ||
// if we have requirement to make it more flexible, we can relax this restriction. | ||
sealed trait DeploymentStatus extends EnumEntry with UpperSnakecase { | ||
def name: DeploymentStatusName = DeploymentStatusName(entryName) | ||
} | ||
|
||
sealed abstract class NoAttributesDeploymentStatus extends DeploymentStatus | ||
|
||
final case class ProblemDeploymentStatus(description: String) extends DeploymentStatus { | ||
override def name: DeploymentStatusName = ProblemDeploymentStatus.name | ||
} | ||
|
||
object DeploymentStatus extends Enum[DeploymentStatus] { | ||
|
||
override def values = findValues | ||
|
||
object Problem { | ||
|
||
private val DefaultDescription = "There are some problems with deployment." | ||
|
||
val Failed: ProblemDeploymentStatus = ProblemDeploymentStatus(DefaultDescription) | ||
|
||
val FailureDuringDeploymentRequesting: ProblemDeploymentStatus = ProblemDeploymentStatus( | ||
"There were some problems with deployment requesting" | ||
) | ||
|
||
} | ||
|
||
case object DuringDeploy extends NoAttributesDeploymentStatus | ||
case object Running extends NoAttributesDeploymentStatus | ||
case object Finished extends NoAttributesDeploymentStatus | ||
case object Restarting extends NoAttributesDeploymentStatus | ||
case object DuringCancel extends NoAttributesDeploymentStatus | ||
case object Canceled extends NoAttributesDeploymentStatus | ||
|
||
} | ||
|
||
object ProblemDeploymentStatus { | ||
def name: DeploymentStatusName = DeploymentStatusName("PROBLEM") | ||
|
||
def extractDescription(status: DeploymentStatus): Option[String] = | ||
status match { | ||
case problem: ProblemDeploymentStatus => | ||
Some(problem.description) | ||
case _: NoAttributesDeploymentStatus => | ||
None | ||
} | ||
|
||
} | ||
|
||
final case class DeploymentStatusName(value: String) { | ||
override def toString: String = value | ||
} | ||
|
||
object DeploymentStatusName { | ||
|
||
implicit val codec: Codec[DeploymentStatusName] = deriveUnwrappedCodec[DeploymentStatusName] | ||
|
||
} |
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.