Skip to content

Updated v3 to v4 in github actions #11698

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

Merged
merged 1 commit into from
Apr 9, 2025

Conversation

ImeshRanawellaSG
Copy link
Collaborator

@ImeshRanawellaSG ImeshRanawellaSG commented Apr 9, 2025

Summary by CodeRabbit

  • Chores
    • Upgraded key automation steps in our build and deployment pipelines to the latest supported versions.
    • Enhancements include improvements in code checkout, Java setup, caching, and artifact management processes.
    • These updates help ensure more reliable and efficient releases, contributing to a smoother and more consistent user experience.

@ImeshRanawellaSG ImeshRanawellaSG self-assigned this Apr 9, 2025
Copy link
Contributor

coderabbitai bot commented Apr 9, 2025

Walkthrough

This pull request updates the GitHub Actions workflows by upgrading several action versions from v3 to v4. In the CodeQL analysis workflow, only the checkout action is updated, while the remaining CI/CD pipelines have been modified to use the newer versions of actions for code checkout, Java setup, caching, and in some cases artifact downloading. The structural logic and overall workflow execution remain unchanged.

Changes

File(s) Change Summary
.github/workflows/codeql-analysis.yml Updated actions/checkout from v3 to v4 for CodeQL analysis.
.github/workflows/{coop_dev_ci_cd.yml, coop_prod_ci_cd.yml, coop_stg_ci_cd.yml, development_pr_validation.yml, digasiri_prod_ci_cd.yml, hims_qa1_ci_cd.yml, hims_qa2_ci_cd.yml, horizon_prod_ci_cd.yml, kml_prod_ci_cd.yml, mp_prod_ci_cd.yml, rh_dev_ci_cd.yml, rh_prod_ci_cd.yml, rh_prod_deployment.yml, rh_stg_ci_cd.yml, rmh_prod_ci_cd.yml, southernlanka_prod_ci_cd.yml, southernlanka_stg_ci_cd.yml} Upgraded multiple GitHub Actions from v3 to v4. Changes include updating actions/checkout, actions/setup-java, and actions/cache steps (and updating actions/download-artifact where applicable) across various CI/CD workflows.

Warning

Review ran into problems

🔥 Problems

Git: Failed to clone repository. Please run the @coderabbitai full review command to re-trigger a full review. If the issue persists, set path_filters to include or exclude specific files.


📜 Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a812668 and fe6f3b2.

📒 Files selected for processing (18)
  • .github/workflows/codeql-analysis.yml (1 hunks)
  • .github/workflows/coop_dev_ci_cd.yml (2 hunks)
  • .github/workflows/coop_prod_ci_cd.yml (2 hunks)
  • .github/workflows/coop_stg_ci_cd.yml (2 hunks)
  • .github/workflows/development_pr_validation.yml (2 hunks)
  • .github/workflows/digasiri_prod_ci_cd.yml (2 hunks)
  • .github/workflows/hims_qa1_ci_cd.yml (2 hunks)
  • .github/workflows/hims_qa2_ci_cd.yml (2 hunks)
  • .github/workflows/horizon_prod_ci_cd.yml (2 hunks)
  • .github/workflows/kml_prod_ci_cd.yml (2 hunks)
  • .github/workflows/mp_prod_ci_cd.yml (2 hunks)
  • .github/workflows/rh_dev_ci_cd.yml (2 hunks)
  • .github/workflows/rh_prod_ci_cd.yml (2 hunks)
  • .github/workflows/rh_prod_deployment.yml (1 hunks)
  • .github/workflows/rh_stg_ci_cd.yml (2 hunks)
  • .github/workflows/rmh_prod_ci_cd.yml (2 hunks)
  • .github/workflows/southernlanka_prod_ci_cd.yml (2 hunks)
  • .github/workflows/southernlanka_stg_ci_cd .yml (2 hunks)
🔇 Additional comments (68)
.github/workflows/codeql-analysis.yml (1)

41-41: CodeQL Workflow Checkout Upgrade.
The “Checkout repository” step now uses actions/checkout@v4 instead of an older version. This update should improve overall reliability during repository checkout in CodeQL analysis.

.github/workflows/development_pr_validation.yml (3)

15-15: Checkout Update in JDBC Data Sources Validation.
The checkout step is updated to actions/checkout@v4, which aligns with the new standard across workflows.


35-35: Checkout Update in Compilation Validation.
The “Checkout Code” action in the validate-compilation job now utilizes actions/checkout@v4. This consistent upgrade helps mitigate potential version mismatch issues.


38-38: Setup Java Update in Compilation Validation.
The actions/setup-java action is now updated to v4. Please confirm that the arguments (distribution and java-version) are fully compatible with v4’s requirements.

.github/workflows/rh_prod_deployment.yml (3)

13-13: Checkout Action Update in Production Deployment.
The checkout action has been upgraded to actions/checkout@v4, ensuring that the build process leverages the latest improvements in action handling.


16-16: Setup Java Action Updated.
The “Set up JDK 11” step now calls actions/setup-java@v4, consistent with the upgrade across different workflows.


22-22: Cache Maven Action Upgrade.
The caching step now uses actions/cache@v4, which should offer enhanced caching performance as compared to the previous version.

.github/workflows/mp_prod_ci_cd.yml (5)

14-14: Checkout Action Upgrade in MP-PROD Build.
The “Checkout Code” step now employs actions/checkout@v4, aligning this workflow with the standardized version upgrade across the project.


17-17: Setup Java Action Version Updated.
The step “Set up JDK 11” is updated to use actions/setup-java@v4, ensuring that Java environment setups are using the latest configuration options.


23-23: Cache Action Updated for Maven Packages.
The cache step now references actions/cache@v4, aligning with the overall upgrade and potentially benefiting from performance improvements.


58-58: Deploy Job Checkout Action Consistency.
The deploy job’s “Checkout Code” step now uses actions/checkout@v4, which is consistent with the changes in the build job.


61-61: Artifact Download Action Updated.
The “Download Build Artifact” step now uses actions/download-artifact@v4. Ensure that artifact retrieval works as expected with the new version.

.github/workflows/rmh_prod_ci_cd.yml (4)

14-14: Updated Checkout Action Version

The checkout step now uses actions/checkout@v4, which brings in the latest improvements and bug fixes compared to the previous v3. Please verify that any additional parameters (if needed in your context) are still valid.


17-17: Updated Setup-Java Action Version

The JDK setup step has been updated to actions/setup-java@v4. Ensure that the configuration (distribution: 'temurin' and java-version: '11') works as expected with the new version and that there are no breaking changes.


23-23: Updated Cache Action Version

The caching step now employs actions/cache@v4 for Maven packages. Please double-check that the caching key configuration (${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}) continues to perform optimally with this version.


58-58: Consistent Checkout in Deploy Job

The deploy job’s checkout now also uses actions/checkout@v4, ensuring consistency with the build job. Confirm that any side effects in deployment (if previously relying on v3 behaviors) are addressed.

.github/workflows/horizon_prod_ci_cd.yml (4)

14-14: Updated Checkout Action Version

Updated the checkout step to actions/checkout@v4. This change is consistent with the overall update strategy and should provide the latest features and fixes.


17-17: Updated Setup-Java Action Version

The JDK setup now uses actions/setup-java@v4 ensuring that the build job is aligned with the latest configuration standards. Please ensure that the current java version settings remain valid.


23-23: Updated Cache Action Version

The cache step now refers to actions/cache@v4, which should help with improved performance and reliability. Verify that your caching logic continues to work as expected.


58-58: Consistent Checkout Action in Deploy Job

The deploy job now uses actions/checkout@v4, matching the build job. This consistency is good for pipeline maintainability—just make sure it doesn't introduce unexpected behaviors.

.github/workflows/coop_stg_ci_cd.yml (4)

14-14: Updated Checkout Action Version

The upgrade to actions/checkout@v4 ensures that the repository checkout in the build job benefits from the latest fixes. Please review any version-specific documentation if your workflow has custom needs.


17-17: Updated Setup-Java Action Version

The setup for JDK now uses actions/setup-java@v4. Confirm that the distribution and Java version parameters are fully supported in this release.


23-23: Updated Cache Action Version

The caching of Maven packages is now handled by actions/cache@v4. Make sure that the caching key and restore-keys options still yield the desired caching behavior.


58-58: Checkout Updated in Deploy Job

The deploy job’s checkout step has been updated to use actions/checkout@v4, ensuring a uniform configuration across jobs.

.github/workflows/southernlanka_prod_ci_cd.yml (4)

14-14: Updated Checkout Action Version

The checkout step is updated to actions/checkout@v4, which is in line with the overall update strategy across workflows. No issues detected.


17-17: Updated Setup-Java Action Version

The step for setting up JDK 11 now uses actions/setup-java@v4. Please ensure that the provided configuration (distribution and version) remains compatible.


23-23: Updated Cache Action Version

Using actions/cache@v4 for caching improves consistency. Validate that the key mechanism using ${{ hashFiles('**/pom.xml') }} functions as intended.


58-58: Deploy Job Checkout Update

The deploy job has its checkout action updated to actions/checkout@v4, maintaining consistency with the build job. Please confirm that this change does not affect deployment-specific behaviors.

.github/workflows/hims_qa2_ci_cd.yml (4)

14-14: Updated Checkout Action Version

The checkout action for the build job has been updated to actions/checkout@v4. This update should provide improved performance and security.


17-17: Updated Setup-Java Action Version

Now using actions/setup-java@v4 for the JDK setup, which is consistently applied across workflows. Verify that there are no breaking changes with your current configurations.


23-23: Updated Cache Action Version

The caching step has been upgraded to actions/cache@v4. Ensure the caching key and restore keys are still optimally configured.


58-58: Deploy Job Checkout Updated

The deploy job now also uses actions/checkout@v4, aligning it with the build process. This consistency is beneficial; just confirm that the deployment process remains uninterrupted.

.github/workflows/rh_dev_ci_cd.yml (4)

14-14: Upgrade Checkout Action in Build Job
The "Checkout Code" step now uses actions/checkout@v4, which meets the PR objective of upgrading action versions. Please verify that all custom checkout configurations (if any) work as intended with v4.


17-17: Upgrade Setup Java Action
The "Set up JDK 11" step has been updated to actions/setup-java@v4. Ensure that any configuration defaults or behaviors changed in v4 do not unexpectedly affect the build environment.


23-23: Upgrade Maven Cache Action
The "Cache Maven Packages" step now uses actions/cache@v4. Verify that the caching for Maven artifacts continues to function correctly with the new version.


58-58: Deploy Job Checkout Update
In the deploy job, the "Checkout Code" step is updated to use actions/checkout@v4. This update is consistent with the build job. Confirm that the deploy process remains unaffected by this change.

.github/workflows/coop_dev_ci_cd.yml (4)

14-14: Upgrade Checkout Action in Build Job
The "Checkout Code" step now uses actions/checkout@v4 in the COOP-DEV workflow. This upgrade is aligned with the overall PR objectives. Ensure that repository checkout behaves as expected with the new version.


17-17: Upgrade Setup Java Action
The "Set up JDK 11" step now utilizes actions/setup-java@v4. Double-check that the JDK installation and associated options remain consistent with prior behavior.


23-23: Upgrade Cache Maven Packages Action
The "Cache Maven Packages" step now employs actions/cache@v4. Please validate that caching functions—especially the key and restore-keys settings—continue to work properly.


58-58: Deploy Job Checkout Update
The deploy job's "Checkout Code" step is updated to actions/checkout@v4, consistent with the build job. This uniformity across workflows minimizes version discrepancies.

.github/workflows/rh_prod_ci_cd.yml (4)

14-14: Upgrade Checkout Action in Build Job
The "Checkout Code" step has been upgraded to actions/checkout@v4. Confirm that there are no unexpected changes in repository behavior due to this version bump.


17-17: Upgrade Setup Java Action
The updated action actions/setup-java@v4 for setting up JDK 11 should be reviewed to ensure that any changes in default behavior or supported features from v3 are appropriately handled.


23-23: Upgrade Maven Cache Action
The "Cache Maven Packages" step now using actions/cache@v4 is a straightforward upgrade. Please verify that Maven dependencies are correctly cached with the new version settings.


58-58: Deploy Job Checkout Update
The deploy job’s "Checkout Code" step now utilizes actions/checkout@v4. This change is in line with the build steps; however, it's advisable to test the deployment flow thoroughly after the update.

.github/workflows/hims_qa1_ci_cd.yml (4)

14-14: Upgrade Checkout Action in Build Job
The "Checkout Code" step in the HIMS QA-1 workflow now uses actions/checkout@v4, fulfilling the PR objective. Verify that branch checkout and related configurations work without issues.


17-17: Upgrade Setup Java Action
The "Set up JDK 11" step now employs actions/setup-java@v4. Ensure that no unexpected side effects occur due to changes in the new action version.


23-23: Upgrade Cache Maven Packages Action
With the Maven cache step now updated to actions/cache@v4, it’s important to test that artifact caching still performs as needed under CI conditions.


58-58: Deploy Job Checkout Update
The deploy job's "Checkout Code" step has been updated to actions/checkout@v4 which is consistent with other environments. Confirm that code retrieval during deployment is not affected by this change.

.github/workflows/coop_prod_ci_cd.yml (4)

14-14: Upgrade Checkout Action in Build Job
The "Checkout Code" step now uses actions/checkout@v4 in the COOP-PROD workflow. This upgrade is part of a consistent version update across all workflows.


17-17: Upgrade Setup Java Action
The "Set up JDK 11" step in the COOP-PROD workflow is updated to actions/setup-java@v4. Please verify that the new version correctly handles JDK setup as expected.


23-23: Upgrade Maven Cache Action
The update to actions/cache@v4 in the "Cache Maven Packages" step should maintain all previous caching functionality. Testing is recommended to confirm that your Maven build dependencies remain efficiently cached.


58-58: Upgrade Deploy Job Checkout Action
The deploy job's "Checkout Code" step is now updated to actions/checkout@v4, mirroring the changes made in the build job. This uniformity aids in reducing version-related inconsistencies across environments.

.github/workflows/rh_stg_ci_cd.yml (4)

14-14: Upgrade Checkout Action to v4.
The checkout step has been updated from v3 to v4 in this build job. Please verify that any new parameters or behavioral changes in v4 are compatible with this workflow.


17-17: Upgrade Setup-Java Action to v4.
The JDK 11 setup now uses actions/setup-java@v4. Confirm that the provided inputs (e.g., distribution and java-version) are still valid and that there are no breaking changes compared to the v3 version.


23-23: Upgrade Cache Maven Packages Action to v4.
The caching step now references actions/cache@v4. Please verify that the cache key syntax and behavior remain consistent with your expectations for Maven dependencies.


57-58: Consistent Checkout in Deployment Job.
The deployment job’s checkout step is now updated to v4. Ensure that this update aligns with any downstream actions (e.g., artifact download) that depend on the checkout process.

.github/workflows/digasiri_prod_ci_cd.yml (4)

14-14: Upgrade Checkout Action to v4 in Build Job.
The checkout step here has been upgraded to actions/checkout@v4. Double-check for any new parameters or behavioral changes that might impact the build process.


17-17: Upgrade Setup-Java Action to v4.
The JDK 11 setup now uses v4. Please confirm that the configuration (distribution and java-version) is compatible with the updated action version.


23-23: Upgrade Cache Action to v4.
The Maven cache step has been updated to use actions/cache@v4. Verify that the cache key generation and restore behavior work as intended with this new version.


57-58: Upgrade Checkout Action in Deploy Job.
The deploy job now checks out source code using actions/checkout@v4. Ensure that no downstream steps are adversely affected by this version change.

.github/workflows/kml_prod_ci_cd.yml (4)

14-14: Upgrade Checkout Action to v4.
The build job’s checkout step has been updated to actions/checkout@v4. Please confirm that the upgrade does not introduce any unexpected behavior in the code checkout process.


17-17: Upgrade Setup-Java Action to v4.
The JDK 11 setup is now using actions/setup-java@v4. Verify that the input parameters (distribution and java-version) remain valid and that the new version does not affect the build environment adversely.


23-23: Upgrade Cache Maven Packages Action to v4.
The caching step now uses actions/cache@v4. Make sure that the cache key and restoration steps continue to function properly under the new version.


57-58: Upgrade Deploy Job Checkout Step.
The deploy job now checks out the repository with actions/checkout@v4. This upgrade should harmonize with other jobs; please verify that artifact download and subsequent steps are unaffected.

.github/workflows/southernlanka_stg_ci_cd .yml (4)

14-14: Updated Checkout Action Version

The change from actions/checkout@v3 to actions/checkout@v4 is in line with current best practices. Please verify that any differences in default behavior (e.g., regarding submodule handling or fetch depth) are compatible with your repository setup.


17-17: Updated Setup Java Action Version

Updating to actions/setup-java@v4 is a positive step to leverage the latest improvements. Ensure that the parameters (distribution and java-version) behave as expected under v4 and review the action’s documentation for any breaking changes.


23-23: Updated Cache Maven Packages Action Version

Changing to actions/cache@v4 should help improve cache handling. Confirm that the caching key logic and the specified path (~/.m2) still meet your needs without introducing any unexpected behavior.


58-58: Updated Deploy Job Checkout Action Version

The deploy job now also uses actions/checkout@v4, which ensures consistency across your workflows. Double-check any repository-specific configurations (like checkout depth or submodules) to guarantee they continue to function correctly.


🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai plan to trigger planning for file edits and PR creation.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@ImeshRanawellaSG ImeshRanawellaSG merged commit cf84811 into development Apr 9, 2025
3 checks passed
@ImeshRanawellaSG ImeshRanawellaSG deleted the update-versions-in-github-actions branch April 9, 2025 06:47
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

Successfully merging this pull request may close these issues.

2 participants