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

Optimize CI a bit #1390

Merged
merged 9 commits into from
Mar 21, 2022
Merged

Optimize CI a bit #1390

merged 9 commits into from
Mar 21, 2022

Conversation

Goooler
Copy link
Contributor

@Goooler Goooler commented Mar 18, 2022

📝 Description

Mainly for using gradle-build-action to speed up build on CI, and bump action versions by the way.

🔗 Related Issues

key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle.kts') }}
restore-keys: |
${{ runner.os }}-gradle-
uses: gradle/gradle-build-action@v2
Copy link
Contributor Author

Choose a reason for hiding this comment

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

https://github.com/gradle/gradle-build-action

Ref detekt/detekt#3723, it's really so fast to run jobs, and many other advantages.

@Goooler
Copy link
Contributor Author

Goooler commented Mar 18, 2022

Error:  Failed to execute goal com.expediagroup:graphql-kotlin-maven-plugin:6.0.0-SNAPSHOT:generate-client (default) on project graphql-kotlin-maven-client-example: Execution default of goal com.expediagroup:graphql-kotlin-maven-plugin:6.0.0-SNAPSHOT:generate-client failed: A required class was missing while executing com.expediagroup:graphql-kotlin-maven-plugin:6.0.0-SNAPSHOT:generate-client: com/expediagroup/graphql/client/Generated
Error:  -----------------------------------------------------
Error:  realm =    plugin>com.expediagroup:graphql-kotlin-maven-plugin:6.0.0-SNAPSHOT
Error:  strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy

@dariuszkuc
Copy link
Collaborator

Looks like the gradle-build-action does not play nicely with caching action for Maven (we publish both Maven and Gradle plugins and need to run Maven for plugin integration tests).

@Goooler
Copy link
Contributor Author

Goooler commented Mar 18, 2022

I've tested again on my repo, it passed. See Goooler#1

Comment on lines -30 to -35
uses: actions/cache@v1
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle.kts') }}
restore-keys: |
${{ runner.os }}-gradle-
Copy link
Contributor Author

Choose a reason for hiding this comment

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

gradle/gradle-build-action just caches the .gradle folder, .m2 folder is handled by actions/cache.

@dariuszkuc dariuszkuc added the type: tool update CI, code coverage, or linter updates label Mar 21, 2022
@dariuszkuc dariuszkuc merged commit e5777fa into ExpediaGroup:master Mar 21, 2022
@Goooler Goooler deleted the ci branch March 21, 2022 23:36
dariuszkuc pushed a commit to dariuszkuc/graphql-kotlin that referenced this pull request Aug 5, 2022
### 📝 Description
Use gradle-build-action to speed up build on CI and bump all action versions.

### 🔗 Related Issues
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: tool update CI, code coverage, or linter updates
Development

Successfully merging this pull request may close these issues.

2 participants