-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NU-1979] Scenario statuses refactor: scenario status and deployment statuses are decoupled #7566
Conversation
created: #7567 |
b48260d
to
dea343a
Compare
6d40677
to
a6fc258
Compare
28b5f28
to
ce37f72
Compare
129b672
to
4d49ac4
Compare
3081df2
to
5a90c77
Compare
325c9fb
to
acf8e43
Compare
a28e6bf
to
28d2486
Compare
28d2486
to
2d7233f
Compare
5cf00fd
to
b0ebb97
Compare
…gerDispatcher dependency
b0ebb97
to
80efd7b
Compare
…entStateDetector use for periodics
cd1bcbd
to
2f2c925
Compare
2f2c925
to
10dc416
Compare
10cd096
to
51a10dd
Compare
51a10dd
to
95a3da2
Compare
...src/main/scala/pl/touk/nussknacker/ui/statistics/UsageStatisticsReportsSettingsService.scala
Show resolved
Hide resolved
designer/server/src/test/scala/pl/touk/nussknacker/test/mock/MockDeploymentManager.scala
Show resolved
Hide resolved
designer/server/src/test/scala/pl/touk/nussknacker/ui/api/AppApiHttpServiceBusinessSpec.scala
Show resolved
Hide resolved
designer/server/src/test/scala/pl/touk/nussknacker/ui/api/AppApiHttpServiceBusinessSpec.scala
Show resolved
Hide resolved
...pl/touk/nussknacker/ui/process/deployment/scenariostatus/InconsistentStateDetectorTest.scala
Show resolved
Hide resolved
...management/src/main/scala/pl/touk/nussknacker/engine/management/FlinkDeploymentManager.scala
Show resolved
Hide resolved
.../src/main/scala/pl/touk/nussknacker/engine/management/FlinkScheduledExecutionPerformer.scala
Show resolved
Hide resolved
acb4d75
to
c7a228d
Compare
@@ -53,7 +53,7 @@ object flinkRestModel { | |||
|
|||
// NOTE: Flink <1.10 compatibility - JobStatus changed package, so we use String here | |||
@JsonCodec(decodeOnly = true) case class JobOverview( | |||
jid: String, | |||
jid: JobID, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't it be better to introduce our own FlinkJobId, wrapping either a String or a UUID, instead of relying on a class from the Flink API? If I skimmed through the PR correctly, do we only need the string representation of the job ID?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This Flink's JobId is quite stable value class. TBH IMO we should remove the whole flink client related code and use Flink's official client for rest API (RestClient
/RestClusterClient
).
Describe your changes
This refactor aimed to distinguish between scenario status and the status of scenario deployments.
Scenario status is the combination of local actions (deploy/cancel) and deployments visible on engine side.
Before the change both things were coupled together. DeploymentManager has returned the scenario status. After the change, DM returns only the status of deployments and the process of resolution this statuses to scenario status is done in the Designers core.
API changes:
DeploymentManager
interfaceDeploymentManager
has onlygetScenarioDeploymentsStatuses
method (previousgetProcessStates
returningList[StatusDetails]
).DeploymentManager.resolve
should be removed - this work is done by Designer itselfDeploymentManagerInconsistentStateHandlerMixIn
mixin should be also removedstateQueryForAllScenariosSupport
was renamed todeploymentsStatusesQueryForAllScenariosSupport
StatusDetails
was renamed toDeploymentStatusDetails
externalDeploymentId
,externalDeploymentId
,attributes
,attributes
were removed fromStatusDetails
Other things that were done:
ProcessState
was renamed toScenarioStatusDto
ScenarioStatusPresenter
and is done close to Resources instead of in domain servicesScenarioStateProvider
was split intoScenarioStatusProvider
andEngineSideDeploymentStatusesProvider
ScenarioDeploymentReconciler
which is invoked periodicallyChecklist before merge