Introduction to Scavenger
As software systems age, they often accumulate unused or "dead code" resulting from changes in requirements and specifications. The Scavenger project is designed to tackle this issue head-on, providing a comprehensive solution for identifying and managing dead code in Java-based applications.
Scavenger originated as a more advanced version of codekvast, which was the first tool to offer runtime dead code analysis in Java. Building on this foundation, Scavenger introduces a more sophisticated and user-friendly interface, while refining the underlying logic through a significant overhaul of the codebase.
Components
The Scavenger platform is made up of several key components, each playing a vital role in its functionality:
-
Scavenger Agent: This component is responsible for collecting information about the codebase. It regularly sends data about the application’s invocations to the collectors.
-
Scavenger Collector: It stores the data received from agents into a database and cleans up any unnecessary information or garbage.
-
Scavenger API: This component offers APIs to explore the recorded invocations.
-
Scavenger Frontend: This provides a graphical user interface, making it easier to interact with the Scavenger system.
-
Scavenger Python Agent (BETA): Although still in beta, this agent is designed for users who want to apply Scavenger's capabilities to Python applications.
Features
Scavenger boasts several notable features:
- It performs runtime analysis of dead code without requiring any changes to the existing code.
- Initially designed for JVM-based languages, it supports various Java versions, though official support for Java 1.7 has ended. Users needing this can use outdated agents.
- The tool offers a web-based interface for managing projects, capturing invocation snapshots, and monitoring project dashboards.
- Scavenger supports several databases, including MySQL, Vitess, and H2.
Download
Scavenger is readily available for download, ensuring users can access the latest versions with ease:
-
Collector and API: The latest versions can be downloaded from here.
-
Agent for Java: The newest edition can be obtained from Maven's repository, with links pointing users to the latest version.
-
Old Agent for Java: Although not maintained anymore, the old agent for Java 1.7 is still available for download for users who require it.
Documentation
A wealth of documentation is available to assist with Scavenger's installation and usage, including an installation guide and a user guide.
Contribution
Scavenger is open to contributions from the community. The team encourages active participation through pull requests, following a simple process to facilitate code changes and enhancements:
- Fork the repository and create a branch from the 'develop' branch.
- Add tests if new functionalities are introduced.
- Ensure that all tests pass.
- Submit a pull request for review.
Versioning
For clarity in its development and to maintain backward compatibility, Scavenger adheres to Semantic Versioning. This ensures that major, minor, and patch updates are carefully tracked, providing insight into the nature of changes between releases.
Q/A and Bug Tracker
For those encountering bugs or thinking of new features, Scavenger encourages users to raise issues through their GitHub issue tracker, keeping the development team informed and involved in resolving concerns.
License
Scavenger operates under the Apache License 2.0, allowing users to use and modify the software while complying with the licensing terms. For further information, visit Apache License 2.0.
Scavenger offers an extensive solution for managing dead code, enhancing the clarity and efficiency of software projects. Whether for Java or through the emerging support for Python, Scavenger continues to evolve, welcoming community engagement and feedback.