lhotari opened a new pull request #10001:
URL: https://github.com/apache/pulsar/pull/10001
### Motivation
Maven repository caching has several issues in Pulsar CI:
- caching doesn't work for dependencies a build that builds all modules if a
cache entry has been published
from a build that was built for core-modules
- the GitHub Actions cache restores the complete ~/m2/repository directory
for a cache key at once
and doesn't do lookups for individual files.
- cache step is run for document only changes. This might lead to an empty
cache entry when the document build updates the cache entry.
- Pulsar build artifacts in ~/.m2/repository/org/apache/pulsar get cached.
This consumes unnecessary bandwidth and could lead to surprises unless every
build rebuilds all Pulsar libraries. It's better to exclude the files from the
Maven dependency cache entries since they aren't needed there.
### Modifications
- exclude ~/.m2/repository/org/apache/pulsar from caching since
- exclude syntax needs special care. The exclusion pattern must be
defined at the same sub-directory level as the inclusion pattern. this is
explained as a workaround in actions/cache issue 364
- use separate caches for builds that build only the core-modules and other
builds that build all modules
- skip cache steps when there are document-only changes
- remove the unnecessary build container used for running some unit tests.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]