npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

javalens-mcp

v1.3.5

Published

MCP server for semantic Java code analysis, built on Eclipse JDT. Provides 63 tools for navigation, refactoring, and code intelligence.

Readme

javalens-mcp

GitHub release npm License: MIT

An MCP server providing 63 semantic analysis tools for Java, built directly on Eclipse JDT for compiler-accurate code understanding.

Requirements

  • Java 21 or later — required as the server runtime, analyzes Java source from version 1.1 through 23
  • Node.js 18+ — required to run this package via npx. If you don't have Node.js, download JavaLens directly from GitHub Releases instead.

Quick Start

{
  "mcpServers": {
    "javalens": {
      "command": "npx",
      "args": ["-y", "javalens-mcp"],
      "env": {
        "JAVA_PROJECT_PATH": "/path/to/your/java/project"
      }
    }
  }
}

What This Package Does

This npm package bundles the full JavaLens distribution (~23 MB). No runtime downloads, no network dependency after install. It:

  1. Checks that Java 21+ is installed
  2. Reads JVM configuration from the bundled eclipse.ini
  3. Launches the JavaLens MCP server with stdio for protocol communication

Why JavaLens?

AI systems need compiler-accurate insights that reading source files cannot provide. When an AI uses grep to find usages of a method, it cannot distinguish a method call from a method with the same name in an unrelated class, a field read from a field write, or an interface implementation from an unrelated class.

| Approach | Result | |----------|--------| | grep "save(" | 47 matches including orderService.save(), saveButton, comments | | find_references | Exactly 12 calls to UserService.save() |

Features

Navigation (10 tools)

Search symbols, go to definition, find references, find implementations, type hierarchy, document symbols, and positional queries.

Fine-Grained Reference Search (9 tools)

JDT-unique capabilities not available through LSP: find annotation usages, type instantiations, casts, instanceof checks, throws declarations, catch blocks, method references, type arguments, and reflection usage detection.

Analysis (16 tools)

Diagnostics, syntax validation, call hierarchy (incoming/outgoing), field write tracking, test discovery, unused code detection, possible bug detection, change impact analysis, data flow analysis, control flow analysis, and Spring DI registration scanning.

Compound Analysis (4 tools)

Combine multiple queries to reduce round-trips: analyze file, analyze type, analyze method, and type usage summary.

Refactoring (10 tools)

All return text edits rather than modifying files directly: rename, organize imports, extract variable/method/constant/interface, inline variable/method, change method signature, and convert anonymous to lambda.

Quick Fixes & Metrics (8 tools)

Import suggestions, quick fixes, cyclomatic complexity, dependency graphs, circular dependency detection, large class detection, and naming convention violations.

Build System Support

Single-module and multi-module projects load end-to-end across Maven, Gradle, and Bazel.

| System | Detection | Multi-module | Compiler compliance | Generated sources | Annotation processors | |--------|-----------|:-:|:-:|:-:|:-:| | Maven | pom.xml | ✅ | ✅ | ✅ | ✅ | | Gradle | build.gradle / build.gradle.kts | ✅ | ✅ | ✅ | ✅ | | Bazel | MODULE.bazel / WORKSPACE.bazel / WORKSPACE | ✅ | ✅ | n/a | ✅ | | Plain Java | src/ directory | n/a | ✅ | n/a | n/a |

If mvn / gradle is missing or the subprocess fails, JavaLens reports a structured warning (e.g. MAVEN_SUBPROCESS_FAILED) in the load_project response so callers know the classpath is degraded.

Configuration

| Environment Variable | Description | Default | |---------------------|-------------|---------| | JAVA_PROJECT_PATH | Auto-load project on startup | (none) | | JAVALENS_TIMEOUT_SECONDS | Operation timeout | 30 | | JAVA_TOOL_OPTIONS | JVM options, e.g. -Xmx2g for large projects | 512m | | JAVALENS_LOG_LEVEL | TRACE/DEBUG/INFO/WARN/ERROR | INFO |

Documentation

Full documentation, tool reference, and architecture details: GitHub