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

[DOCS] review dev CI docs part2 #22850

Merged
merged 15 commits into from
Mar 13, 2024
Prev Previous commit
Next Next commit
add review
  • Loading branch information
tsavina committed Feb 19, 2024
commit 82b97ff136430e29c6d83970f3a97c41dfed52b3
10 changes: 5 additions & 5 deletions docs/dev/ci/github_actions/adding_tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ The step includes:
* a `run` section with commands to be executed.

To add a new step with new tests, navigate to the job and use the above template (or any existing
step in the job) for the new step. Refer to the [Overview of the Reusable Workflows](./reusable_workflows.md) to learn
step in the job) for the new step. Refer to the [Reusable Workflows page](./reusable_workflows.md) to learn
more about workflows and job organization.

### Creating a New Job
Expand Down Expand Up @@ -88,11 +88,11 @@ Refer to the [official GitHub Actions documentation](https://docs.github.com/en/
A job:
* requires a name, provided by the `name` key
* requires a runner to execute `steps` on, provided by the `runs-on` key
* Refer to the [Overview of Runners](./runners.md) to learn more about available runners and how to choose one
* Learn more about [available runners](./runners.md)
* might use Docker to execute `steps` in, configured by the `container` key
* Refer to the [Overview of Docker Images](./docker_images.md) to learn more about the available Docker images and how to choose one
* Learn more about [available Docker images](./docker_images.md)
* might use caches to speed up build and/or tests
* Different types of caches are available. Refer to the [Overview of Caches](./caches.md) to learn more about available caches and how to use them
* Different types of caches are available. Learn more about about [available caches](./caches.md)
tsavina marked this conversation as resolved.
Show resolved Hide resolved
* might use the Smart CI system for conditional execution with the `if` key
* Refer to the [Smart CI Overview](./smart_ci.md) for more information
* requires a series of commands to execute, provided by the `steps` key
Expand All @@ -101,7 +101,7 @@ A job:
* The artifacts can be downloaded using the `actions/download-artifact`, read more about the workflows' structure in the [Overview of the OpenVINO GitHub Actions CI](./overview.md#structure-of-the-workflows)
tsavina marked this conversation as resolved.
Show resolved Hide resolved

If the job can be used in several workflows, it can be transformed into a reusable workflow.
Learn more in the [Overview of Reusable Workflows](./reusable_workflows.md).
Learn more in the [Reusable Workflows page](./reusable_workflows.md).
tsavina marked this conversation as resolved.
Show resolved Hide resolved

## Creating a Workflow

Expand Down
2 changes: 1 addition & 1 deletion docs/dev/ci/github_actions/caches.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ CPU_Functional_Tests:
```

Then it appears in the [repository's cache](https://github.com/openvinotoolkit/openvino/actions/caches):
![gha_cache_example](../../../sphinx_setup/_static/images/ci/gha_cache_example.png)
![gha_cache_example](../../assets/gha_cache_example.png)

The next runs can download the artifact from the repository's cache with `actions/cache/restore`
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe "the following" instead of "next?"

tsavina marked this conversation as resolved.
Show resolved Hide resolved
and use it:
Expand Down
2 changes: 1 addition & 1 deletion docs/dev/ci/github_actions/custom_actions.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ for more information.
* [System Info Print](#system-info-print)
* Smart CI (see details: [feature documentation](./smart_ci.md))

## Set up Python
## Python Setup

This custom action installs the required Python version and environment variables on the runner.
Under the hood it uses the GitHub-provided `actions/setup-python`, and community-provided
Expand Down
25 changes: 14 additions & 11 deletions docs/dev/ci/github_actions/runners.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,20 +62,22 @@ The available configurations are:

* `*` - Not specified in the group name

## How to choose a Runner
## How to Choose a Runner

The configuration of a runner required for a job (building, testing, etc.) stems from the nature of the job: the more memory and/or CPU-intensive it is,
the more robust configuration is required.
The configuration of a runner required for a job (building, testing, other tasks) depends on the
nature of the job. Jobs that are more memory and/or CPU-intensive require a more robust configuration.

The `Build` job in the [`linux.yml`](./../../../../.github/workflows/linux.yml) workflow uses the `aks-linux-16-cores-32gb` group as specified in the `runs-on` key:
The `Build` job in the [`linux.yml`](./../../../../.github/workflows/linux.yml) workflow uses
the `aks-linux-16-cores-32gb` group as specified in the `runs-on` key:
```yaml
Build:
...
runs-on: aks-linux-16-cores-32gb
...
```

This group has machines with 16 core CPU and 32 GB of RAM, which could be utilized in parallel by the build tools used in the `Build` job.
The `aks-linux-16-cores-32gb` group has machines with 16-core CPU and 32 GB of RAM.
These resources are suitable for using in parallel by the build tools in the `Build` job.

The `C++ unit tests` job in the [`linux.yml`](./../../../../.github/workflows/linux.yml) workflow uses the `aks-linux-4-cores-16gb` group:
```yaml
Expand All @@ -87,11 +89,12 @@ CXX_Unit_Tests:
...
```

As the C++ tests could not utilize the large number of cores for parallel execution as the build tools in the `Build` job could,
it would be pointless to use the `aks-linux-16-cores-32gb` group for them.
As the C++ tests can not use a large number of cores for parallel execution like
the build tools in the `Build` job, it is not beneficial to use the `aks-linux-16-cores-32gb` group for them.

The advice is to use runners with more cores/RAM size for the tasks that **could load them**.
Instead, it is advisable to use runners with more cores/RAM for tasks that can load them.

It is possible to experiment with different configurations before deciding, i.e.,
run a job on runners from different groups and observe the gains; if they are significant, e.g., 60 minutes on a 4-core runner vs. 15 minutes on a 16-core runner,
it is better to use those with more cores.
It is possible to experiment with different configurations before making a decision. You can
run a job on runners from different groups and compare the gains. If they are significant,
for example, 60 minutes on a 4-core runner compared to 15 minutes on a 16-core runner,
it is better to use the configuration with more cores.
Loading
Loading