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

[FEATURE] TaskUtil: Add 'force' flag to cleanup task callback #677

Merged
merged 14 commits into from
Nov 15, 2023

Conversation

d3xter666
Copy link
Contributor

JIRA: CPOUI5FOUNDATION-751
@ui5/builder PR that depends on this change: SAP/ui5-builder#953

When cleaning up after tasks run, it can happen in couple cases:

  • When the project is build
  • When there's a SIGTERM signal
  • (Maybe) on some error

We need to be able to distinguish between those cases as in some places we rely on graceful termination and cleanup. Especially, after the project has been build successfully. On the other hand when the user presses Ctrl + C, for example, we need to enforce the termination.

This cahnge provides this context.

@coveralls
Copy link

coveralls commented Nov 10, 2023

Coverage Status

coverage: 95.955%. remained the same
when pulling bdb51e2 on internal-pass-args-to-cleanup
into 36ef967 on main.

@d3xter666 d3xter666 requested review from RandomByte and a team November 10, 2023 08:56
d3xter666 and others added 2 commits November 10, 2023 15:44
Co-authored-by: Merlin Beutlberger <m.beutlberger@sap.com>
RandomByte
RandomByte previously approved these changes Nov 14, 2023
@RandomByte
Copy link
Member

Maybe we should have this as a [FEATURE] in the changelog?

@RandomByte
Copy link
Member

We should also update the JSDoc in TaskUtil: https://github.com/SAP/ui5-project/blob/main/lib/build/helpers/TaskUtil.js#L175

@d3xter666 d3xter666 changed the title [INTERNAL] Provide arguments for tasks' cleanup [FEATURE] Provide arguments for tasks' cleanup Nov 14, 2023
@d3xter666
Copy link
Contributor Author

d3xter666 commented Nov 14, 2023

RandomByte
RandomByte previously approved these changes Nov 14, 2023
@RandomByte RandomByte changed the title [FEATURE] Provide arguments for tasks' cleanup [FEATURE] TaskUtil: Add 'force' flag to cleanup task callback Nov 14, 2023
lib/build/helpers/TaskUtil.js Outdated Show resolved Hide resolved
lib/build/helpers/TaskUtil.js Outdated Show resolved Hide resolved
lib/build/helpers/TaskUtil.js Outdated Show resolved Hide resolved
lib/build/helpers/TaskUtil.js Outdated Show resolved Hide resolved
d3xter666 and others added 4 commits November 14, 2023 18:48
Co-authored-by: Günter Klatt <57760635+KlattG@users.noreply.github.com>
Co-authored-by: Günter Klatt <57760635+KlattG@users.noreply.github.com>
Co-authored-by: Günter Klatt <57760635+KlattG@users.noreply.github.com>
@d3xter666 d3xter666 requested a review from matz3 November 15, 2023 07:21
@d3xter666 d3xter666 merged commit a0a21b7 into main Nov 15, 2023
17 checks passed
@d3xter666 d3xter666 deleted the internal-pass-args-to-cleanup branch November 15, 2023 09:52
d3xter666 added a commit to SAP/ui5-builder that referenced this pull request Nov 17, 2023
…953)

fixes: SAP/ui5-tooling#894
JIRA: CPOUI5FOUNDATION-751
depends on: SAP/ui5-project#677

Workerpool needs to wait for all the active tasks to complete before
terminating.

---------

Co-authored-by: Merlin Beutlberger <m.beutlberger@sap.com>
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