Skip to content

Komalpreet2809/POMguard

Repository files navigation

POMguard — Maven Dependency Auditor

POMguard

POMguard is a web app that scans your Maven pom.xml and tells you which dependencies are outdated — instantly, without any local Maven setup. Upload a file, get a color-coded report.


What it does

Most Java projects accumulate outdated dependencies over time. Upgrading blindly is risky; ignoring them is worse. POMguard gives you a quick snapshot:

  • Parses your pom.xml
  • Looks up the latest version of each dependency on Maven Central
  • Flags anything that's behind
  • Keeps a history of your last 10 audits

Status Indicators

Status Meaning
GREEN Dependency is up to date
YELLOW Newer version available
UNKNOWN Not found on Maven Central or no version declared

How to Use

  1. Open pomguard.komalpreet.me
  2. Upload your pom.xml
  3. View the audit report — each dependency shows current version vs latest
  4. Revisit past audits from the history panel

Tech Stack

Backend Java 17, Spring Boot 3.2.5
Templating Thymeleaf
Version data Maven Central REST API (search.maven.org)
Parsing Jackson XML
Version comparison Apache Maven's ComparableVersion

How It Works

  1. ParsePomParser deserializes the uploaded XML into a list of Dependency objects using Jackson
  2. LookupAuditService fans out using parallelStream(), each thread calling MavenCentralClient to fetch the latest version from Maven Central; results are cached in memory so repeat lookups skip the network
  3. CompareVersionComparator uses Apache Maven's own ComparableVersion to correctly handle semver, RC, and qualifier strings
  4. Render — Thymeleaf renders result.html with the audit table; history is stored in-memory (last 10 sessions)

Running Locally

Requires JDK 17. If your system default is different, activate JDK 17 for the current shell first:

. .\activate.ps1
mvn spring-boot:run

Open http://localhost:8080.

# Run tests
mvn test

Running with Docker

docker build -t pomguard:latest .
docker run --rm -p 8080:8080 pomguard:latest

Or pull the published image:

docker pull ghcr.io/komalpreet2809/pomguard:latest
docker run --rm -p 8080:8080 ghcr.io/komalpreet2809/pomguard:latest

Project Structure

src/main/java/com/pomguard/
├── controller/
│   └── AuditController.java      # Routes: GET /, POST /audit, POST /delete-session
├── model/
│   ├── Dependency.java           # Parsed dependency (groupId, artifactId, version)
│   ├── AuditResult.java          # Result per dependency with GREEN/YELLOW/UNKNOWN status
│   └── AuditSession.java         # Saved audit history entry
└── service/
    ├── PomParser.java            # XML → Dependency list (Jackson XML)
    ├── MavenCentralClient.java   # REST calls to search.maven.org with in-memory cache
    ├── VersionComparator.java    # Semver-aware comparison via ComparableVersion
    ├── AuditService.java         # Parallel audit orchestration
    └── HistoryService.java       # In-memory session history (last 10)

About

Maven pom.xml dependency auditor — checks your dependencies against Maven Central and flags outdated versions

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors