googleapis / googleapis/google-cloud-swift
ci: split docs build
- Dominant language
- Swift
- Stars
- 26
- Forks
- 10
- Avg merge
- 12h 56m
- Merged PRs (30d)
- 211
Description
The docs build takes 2h30m, sometimes 3h. The timeout is 4h, but that is too long to wait for these builds.
We need to split the build, consider these options:
- Curate a split based on package size, e.g. compute and aiplatform can be separated from the other docs.
- Split based on some modulo, for example, this code:
https://github.com/googleapis/google-cloud-swift/blob/fc5393c65e915c5c31ca6d30c7d0cbb4b63df1d6/ci/gcb/scripts/docs.sh#L68-L71
Could so something like (check my syntax):
```sh
args=()
n="${#targets[@]}"
for $((i = 0; i < n; ++n)); do
if [[ $(( i % ${SHARD_COUNT} )) == ${SHARD} ]]; then
args+=(--target "${targets[$i]}")
fi
done
```
And then we create N triggers post-merge, each one for a different shard.
Contributor guide
Assessment
This issue has not been assessed yet.