Skip to content

Chore: removed commented out struts actions#1859

Open
LiamStanziani wants to merge 3 commits intomaintenancefrom
chore/remove-orphaned-struts-actions-1193
Open

Chore: removed commented out struts actions#1859
LiamStanziani wants to merge 3 commits intomaintenancefrom
chore/remove-orphaned-struts-actions-1193

Conversation

@LiamStanziani
Copy link
Collaborator

@LiamStanziani LiamStanziani commented Jan 22, 2026

In this PR, I have:

  • Removed commented out struts actions (listed in the attached ticket)

I have tested this by:

  • Smoke testing the application

Summary by cubic

Removed commented-out Struts actions in struts.xml to clean up config. Only comments were deleted; active actions and routing are unchanged.

Written for commit 2020744. Summary will update on new commits.

Summary by Sourcery

Enhancements:

  • Clean up struts.xml by deleting multiple unused, commented-out action definitions that are no longer in use.

Summary by CodeRabbit

  • Chores
    • Removed multiple endpoints from system configuration, including features for consultation printing, patient selection, immunization setup, maintenance operations, billing management, remote referrals, waiting list administration, and MOH XML data handling.

✏️ Tip: You can customize this high-level summary in your review settings.

@sourcery-ai
Copy link

sourcery-ai bot commented Jan 22, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

This PR performs a pure configuration cleanup by removing a set of legacy, fully-commented-out Struts action definitions from struts.xml, without modifying any active actions, routes, or result mappings.

File-Level Changes

Change Details Files
Remove legacy commented-out Struts action mappings to reduce noise in configuration.
  • Deleted commented-out action mapping for an old consultation request print endpoint.
  • Deleted commented-out patient options and immunization initialization actions that are no longer used.
  • Removed commented-out measurement stylesheet streaming action mapping.
  • Removed commented-out maintenance, billing, waiting list, and remote referral action mappings that have replacement implementations or are unused.
  • Removed commented-out actions for BC billing payment handling, file download, consultations, and MOH XML handling that have newer equivalents present as active actions.
src/main/webapp/WEB-INF/classes/struts.xml

Assessment against linked issues

Issue Objective Addressed Explanation
#1193 Remove or fix the active Struts mapping billing/CA/ON/moveMOHFiles that references the missing class ca.openosp.openo.billing.CA.ON.www.ArchiveMOHFile2Action in struts.xml.
#1193 Remove the 11 commented-out orphaned Struts mappings listed in the issue from struts.xml.

Possibly linked issues

  • #: The PR removes all listed orphaned Struts mappings from struts.xml, matching the issue’s requested cleanup.

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@coderabbitai
Copy link

coderabbitai bot commented Jan 22, 2026

📝 Walkthrough

Walkthrough

This PR removes 10 obsolete Struts action configurations from the application's routing file, eliminating publicly accessible endpoints for consultation requests, patient options, immunization setup, maintenance, billing, waiting lists, and remote referrals. Alternative implementations remain in place.

Changes

Cohort / File(s) Summary
Legacy Action Removals
src/main/webapp/WEB-INF/classes/struts.xml
Removed 10 obsolete Struts action mappings:
• Consultation: printPdf (EctConsultationFormRequestPrint2Action)
• Patient/Search: PatientOption (EctPatientOptions2Action)
• Immunization: CreateInitImmunization (EctImmCreateImmunizationSetInit2Action)
• System: oscarMaintenance (Maintenance2Action)
• Billing BC: billingStatement, DownloadBilling (CreateBillingStatement2Action, DownloadFile2Action)
• Billing ON: displayMOHXML, moveMOHFiles (DisplayMOHXML2Action, ArchiveMOHFile2Action)
• Referral: PMmodule/remoteReferal (OscarRemoteReferal2Action)
• Waiting List: WLWaitingList (WLWaitingList2Action)
Additional legacy endpoints documented as commented-out blocks

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Suggested reviewers

  • yingbull

Poem

🐰 Old actions fade, like morning dew,
Legacy endpoints bid adieu,
The registry grows slim and clean,
Obsolete pathways now unseen.
Simpler routes in place remain,
Progress whispers down the lane! 🌿

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: removal of commented-out Struts actions from the configuration file, which is reflected in the -39 line deletion and the removal of multiple action blocks.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/remove-orphaned-struts-actions-1193
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Jan 22, 2026

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Snapshot Warnings

⚠️: No snapshots were found for the head SHA 6367953.
Ensure that dependencies are being submitted on PR branches and consider enabling retry-on-snapshot-warnings. See the documentation for more information and troubleshooting advice.

Scanned Files

None

@LiamStanziani LiamStanziani marked this pull request as ready for review January 22, 2026 18:34
Copy link

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

@claude
Copy link

claude bot commented Jan 22, 2026

Code review

No issues found. Checked for bugs and CLAUDE.md compliance.

This PR safely removes 11 commented-out Struts action blocks from struts.xml. All deletions are complete XML comment blocks with no impact on active functionality. The cleanup aligns with the project's documented maintenance philosophy of removing unused code to reduce the codebase's attack surface.

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@yingbull
Copy link

Let's hold on this with the Struts 6.8 update ready for develop and see what is needed after that in relation to this.

@sebastian-j-ibanez sebastian-j-ibanez changed the base branch from develop to maintenance March 13, 2026 23:03
@sebastian-j-ibanez
Copy link
Collaborator

Retargeted to maintenance.

I don't see any issues with merging this PR now.

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.

Remove 12 orphaned Struts action mappings pointing to non-existent classes

3 participants