sefe / sefe/dorc

Remove sync-over-async pattern from GitHub Actions integration

Open
#587 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement performance
Dominant language
C#
Stars
5
Forks
3
Avg merge
1d 22h
Merged PRs (30d)
14

Description

Background

PR #584 introduced GitHub Actions support. Several code paths use .GetAwaiter().GetResult() to block on async HTTP calls, risking thread-pool starvation and deadlocks.

Affected Code

  1. GitHubActionsBuildServerClient.GetBuildDefinitions() — blocks on HttpClient.GetAsync() in a foreach loop
  2. GitHubDeployableBuild.IsValid() — blocks on ValidateBuildAsync()
  3. RequestsManager.RequestDetail() — blocks on BuildServerDetailAsync()

Why Deferred

Same pattern exists in pre-existing Azure DevOps code paths. Fixing requires making IBuildServerClient.GetBuildDefinitions, IDeployableBuild.IsValid, and RequestsManager.RequestDetail fully async, plus updating all callers.

Recommended Approach

  1. IBuildServerClient.GetBuildDefinitionsGetBuildDefinitionsAsync returning Task<>
  2. IDeployableBuild.IsValidIsValidAsync returning Task<bool>
  3. RequestsManager.RequestDetailRequestDetailAsync
  4. Update all controller/service callers to await

Identified in multi-model review of PR #584 (Finding #7)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the implementations and callers of IBuildServerClient.GetBuildDefinitions, IDeployableBuild.IsValid, and RequestsManager.RequestDetail, including the GitHub Actions and pre-existing Azure DevOps paths. The work is done when these interfaces and their callers are fully async, return the specified Task-based results, and no longer block on the listed async operations.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, github-actions
Domain
backend, devops
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.