Skip to content

StorageManager tech debt 3/6: raw types and unchecked casts - #14560

Open
DaanHoogland wants to merge 1 commit into
ghi12316-storage-exceptionsfrom
ghi12316-storage-rawtypes
Open

DaanHoogland wants to merge 1 commit into
ghi12316-storage-exceptionsfrom
ghi12316-storage-rawtypes

Conversation

@DaanHoogland

@DaanHoogland DaanHoogland commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

Depends on #14559

Description

Stack for #12316 (StorageManager tech debt), one PR per item of the issue checklist, review only the top commit of each:

  1. StorageManager tech debt 1/6: remove unused methods, fields and return values #13598: unused methods, fields and return values
  2. never-thrown checked exceptions
  3. raw types and unchecked casts
  4. never-used parameters
  5. remaining trivial warnings
  6. deprecated SearchCriteria.addAnd usages

This PR (3/6) removes all rawtypes and unchecked javac warnings in the touched storage files (13 + 11 on main, 0 after):

  • details MAP parameters in AddSecondaryStorageCmd, AddImageStoreCmd, CreateStoragePoolCmd and UpdateStoragePoolCmd are typed Map<String, ? extends Map<String, String>>, as CreateSecondaryStagingStoreCmd already does. That removes the casts in their accessors and in StorageManagerImpl.extractApiParamAsMap.
  • AddImageStoreCmd.setDetails declared Map<String, String> but is given the unpacked (nested) map, so its type is corrected. The unused UpdateStoragePoolCmd.setDetails is removed.
  • CollectionUtils/MapUtils switch to commons-collections4, whose typed intersection makes the (List<String>) casts unnecessary.
  • The one unavoidable cast (local storage config parsed into untyped maps) is now an explicit, commented @SuppressWarnings.

Part of #12316

Types of changes

  • Cleanup (Code refactoring and cleanup, that may add test cases)

🤖 Generated with Claude Code

Part of #12316

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Nov 2, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 3.88%. Comparing base (fb4c916) to head (9523aad).

Additional details and impacted files
@@                     Coverage Diff                      @@
##           ghi12316-storage-exceptions   #14560   +/-   ##
============================================================
  Coverage                         3.88%    3.88%           
============================================================
  Files                              493      493           
  Lines                            42571    42571           
  Branches                          8069     8069           
============================================================
  Hits                              1653     1653           
  Misses                           40687    40687           
  Partials                           231      231           
Flag Coverage Δ
uitests 3.88% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@DaanHoogland DaanHoogland changed the title StorageManager tech debt 3/5: raw types and unchecked casts StorageManager tech debt 3/6: raw types and unchecked casts Nov 2, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

deal with tech debt in StorageManager(Impl)

1 participant