Skip to content
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

KS-318 move name, owner to yaml spec #13522

Merged
merged 5 commits into from
Jun 14, 2024
Merged

Conversation

krehermann
Copy link
Contributor

@krehermann krehermann commented Jun 12, 2024

https://smartcontract-it.atlassian.net/browse/KS-318

Requires:

In conjunction with:

The key change is that Job Spec TOML now only needs the embedded WF YAML spec. The name, owner, and content hash are derived and do not need to be duplicated.

After this is merged, we will need to update the job specs to move the name and owner into the YAML and remove WorkflowID, WorkflowName, and WorkflowOwner from the job spec TOML

DeividasK
DeividasK previously approved these changes Jun 12, 2024
// note: i tried to make these private, but translating them to the database seems to require them to be public
WorkflowID string `toml:"-" db:"workflow_id"` // Derived. Do not modify. the CID of the workflow.
WorkflowOwner string `toml:"-" db:"workflow_owner"` // Derived. Do not modify. the owner of the workflow.
WorkflowName string `toml:"-" db:"workflow_name"` // Derived. Do not modify. the name of the workflow.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤔 Are we removing the Owner + Name from the database / job spec? Does any functionality rely on the WorkflowOwner / WorkflowName being exposed at the DB level? (I'm thinking of CLO)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, i'll have to update the RDD.

yes, they will need to change some of there parsing.

they are using the pkgworfklows.ParseWorkflowSpecYaml today. they will be able to get these fields from the result of that, if they need them internally for their own private db purposes.

so instead of reading them from RDD (and forcing duplicated values between top-level RDD fields and embedded YAML tags), they can call a func they are already using and get the values

@krehermann krehermann requested a review from eutopian June 12, 2024 13:00
@krehermann krehermann marked this pull request as ready for review June 12, 2024 20:33
@krehermann krehermann requested review from a team as code owners June 12, 2024 20:33
@krehermann krehermann force-pushed the ks-318/wf-name-owner-yaml branch from ba5944e to f09dcd5 Compare June 12, 2024 21:14
core/services/job/models.go Show resolved Hide resolved
core/services/job/models.go Show resolved Hide resolved
@krehermann krehermann requested a review from HenryNguyen5 June 13, 2024 22:25
@krehermann krehermann enabled auto-merge June 13, 2024 23:56
@krehermann krehermann added this pull request to the merge queue Jun 14, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 14, 2024
@krehermann krehermann added this pull request to the merge queue Jun 14, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jun 14, 2024
@bolekk bolekk added this pull request to the merge queue Jun 14, 2024
Merged via the queue into develop with commit 90924dc Jun 14, 2024
106 checks passed
@bolekk bolekk deleted the ks-318/wf-name-owner-yaml branch June 14, 2024 03:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants