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

Generate executable releases #7

Open
brunoluiz opened this issue Sep 25, 2024 · 0 comments
Open

Generate executable releases #7

brunoluiz opened this issue Sep 25, 2024 · 0 comments

Comments

@brunoluiz
Copy link

The PGO optimisation seems to work okay, but if the go mod cache is generated in jobs where it is not included, it is not properly cached. With that, on every run, PGO needs to have its dependencies downloaded + compiled during CI. This can add around 20 seconds of build time.

An example of that is when you have the following flow:

                      ┌────────────────────┐                                
                      │                    │                                
                      │ go mod cache warm                                   
                      │                    │                                
             ┌────────┴─────────┬──────────┴─────────┐                      
             │                  │                    │                      
             │                  │                    │                      
             │                  │                    │                      
             │                  │                    │                      
             │                  │                    │                      
     ┌───────▼──────┐     ┌─────▼───────┐     ┌──────▼──────┐               
     │              │     │             │     │             │               
     │     test     │     │    build    │     │    lint     │               
     │              │     │             │     │             │               
     └──────────────┘     └─────────────┘     └─────────────┘               

In this case, when the go mod cache warm runs, it doesn't save the datadog-pgo deps at all. Besides that, there is the build time, as mentioned.

Ideally, this could be solved by either:

  1. Provided as a release, where developers can fetch using releases API
  2. Provided as a Github Action, where a simple setup-datadog-pgo would do all the heavy lifting (download release etc)
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

No branches or pull requests

1 participant