Skip to content

Enable termination of Hidi processes through pressing the breaking key combinations - #1108

Merged
Maggie Kimani (MaggieKimani1) merged 7 commits into
vnextfrom
mk/terminate-process
Dec 19, 2022
Merged

Enable termination of Hidi processes through pressing the breaking key combinations#1108
Maggie Kimani (MaggieKimani1) merged 7 commits into
vnextfrom
mk/terminate-process

Conversation

@MaggieKimani1

@MaggieKimani1Maggie Kimani (MaggieKimani1) commented Dec 14, 2022

Copy link
Copy Markdown
Contributor

Adds logic to enable process termination by getting an IConsole instance which enables us to listen for the breaking combination CTRL+C and using a CancellationToken to register cancellation and abort the process.
Fixes#884
Reference: dotnet/command-line-api#1750 (comment)

@MaggieKimani1Maggie Kimani (MaggieKimani1) changed the title Enable termination of Hidi transform process by pressing the breaking key combinationsEnable termination of Hidi processes through pressing the breaking key combinationsDec 14, 2022
Comment threadsrc/Microsoft.OpenApi.Hidi/Program.cs Outdated
Comment threadsrc/Microsoft.OpenApi.Hidi/Program.cs Outdated
Comment threadsrc/Microsoft.OpenApi.Hidi/OpenApiService.cs Outdated
@sonarqubecloud

Copy link
Copy Markdown

@baywetVincent Biret (baywet) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

thanks for taking in the suggested changes!

@MaggieKimani1
Maggie Kimani (MaggieKimani1) deleted the mk/terminate-process branch December 19, 2022 16:22
Sign up for freeto 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.

[hidi] hidi transform can't be cancelled or aborted. Process needs to be killed manually.

3 participants

@MaggieKimani1@baywet@github-advanced-security