Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 617583
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T18:27:06+00:00 2026-05-13T18:27:06+00:00

I have to clean up an old project and general knowledge here is that

  • 0

I have to clean up an old project and general knowledge here is that the project contains lots of unused code that we could remove. That would save some headaches and make maintenance easier.

I found the Eclipse Core Tools plugin which looks like a great tool, but in our case we have a Maven2 project that is split in 3 modules.
I can’t seem to be able to run the “find unreferenced members” on the parent project, and when I run it on one of the modules it ignores completely the fact that other modules might be using some of the public members…

Anyone has overcome that issue? Or found another way to go about this?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T18:27:06+00:00Added an answer on May 13, 2026 at 6:27 pm

    when I run it on one of the modules it ignores completely the fact that other modules might be using some of the public members…

    Yes, that’s the problem, and that’s why there is no real deterministic way to do find unused code as reminded by @cletus in this previous answer.

    Having that said, tools like PMD (and its unusedcode rule), Findbugs may help anyway. IDEs like IntelliJ (Java code inspections are fully available in the Community Edition) and Eclipse also have good support for this.

    For IntelliJ, have a look at Global unused declaration inspection:

    Thanks to improvements in the internal indexes behind the Intellij IDEA code insight engine, Maia will be able to instantly highlight some java classes, methods and fields which are unused across the entire project.

    For Eclipse, there is the UCDetector plugin:

    UCDetector (Unecessary Code Detector) is an Open Source eclipse PlugIn Tool to find unecessary (dead) public java code. It also tries to make code final, protected or private.

    alt text

    But I confess that I’m not sure if any of these solution will really work across modules. In that case, my suggestion would be to put all the code in one “janitor” project (yeah, this is ugly but well…) and to run the tools on it (and to clean modules based on the obtained results).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The sad truth about this post is that I have poor regex skills. I
If I ever have a problem that is not showing up as a warning,
I have an Xcode project and needed to change the name of the product
I have to maintain an old database which is not properly normalized. For instance
I have a solution with many projects. One project contain few custom components. One
I have an ANTLR grammar file as part of a C# project file and
So our new webapp project is based on maven. I'm really liking the dependency
I inherited some release scripts that prepare and deploy a PHP webapp to around
[edit] Found the solution. Reinstall EVERYTHING - xcode, mono, monodevelop and monotouch. Now it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.