dotCMS / dotCMS/core

Task 3.1: Migrate Google Guava (High Usage)

Open
#32,683 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

dotCMS : Technical Debt Team : Platform Type : Task
Dominant language
Java
Stars
970
Forks
486
Avg merge
3d 33m
Merged PRs (30d)
170

Description

Task Description

Replace dot.guava with standard com.google.guava:guava dependency

Status: 🔄 PENDING
Scope
  • Update 219+ import statements from repackaged Guava to standard
  • Remove dot.guava from POM files
  • Ensure standard Guava 27.0.1-android is used from BOM
  • Test all Guava functionality, especially @VisibleForTesting annotations
Implementation Plan
  1. Dependency Update:

    • Remove com.dotcms.lib:dot.guava from BOM and dotCMS POM
    • Confirm standard com.google.guava:guava:27.0.1-android in BOM
    • Update dotCMS POM to use standard dependency
  2. Code Migration:

    • Find all imports: com.dotcms.repackage.com.google.common.*
    • Replace with: com.google.common.*
    • Update approximately 219+ import statements across codebase
  3. Testing:

    • Test all Guava functionality (collections, caching, utilities)
    • Verify @VisibleForTesting annotations work correctly
    • Run comprehensive unit and integration tests
    • Check for any custom Guava extensions
Acceptance Criteria
  • [ ] All 219+ Guava imports updated from repackaged to standard
  • [ ] Standard Guava dependency confirmed in BOM
  • [ ] Repackaged Guava dependency removed from POM files
  • [ ] All unit tests pass
  • [ ] Integration tests pass
  • [ ] @VisibleForTesting annotations work correctly
  • [ ] No functional regressions in Guava usage
Claude Assistance Benefits
  • Bulk Import Updates: Claude can efficiently handle 219+ import statement changes
  • Pattern Recognition: Identify all Guava usage patterns across codebase
  • Testing Support: Help identify and run relevant test cases
  • Risk Assessment: Evaluate potential impact of Guava version changes
Related
  • Epic: #32675 - Remove Repackaged Dependencies
  • Phase: 3 - Medium-Risk Migrations
  • Priority: High
  • Estimated Effort: 2-3 days (with Claude assistance)
Technical Notes
  • Guava is heavily used throughout the codebase
  • @VisibleForTesting is critical for test infrastructure
  • Verify version compatibility (27.0.1-android)
  • Check for any custom Guava utilities or extensions
  • High risk due to extensive usage
Risk Mitigation
  • Comprehensive test coverage before migration
  • Incremental testing approach
  • Rollback plan available
  • Performance monitoring during migration

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the BOM and dotCMS POM files, then search the codebase for imports beginning with com.dotcms.repackage.com.google.common. Update the dependency and approximately 219 imports, and verify the standard Guava version and @VisibleForTesting usage. Done means the repackaged dependency is removed, all imports are migrated, and unit and integration tests pass without regressions.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.