Expand description
JVM classpath analysis for sqry.
This crate provides bytecode parsing, build system resolution, and graph integration for JVM classpath dependencies (Java, Kotlin, Scala). It enables sqry to resolve imports and type references across workspace source code and compiled library JARs.
§Architecture
The classpath pipeline runs as a pre-pass before the main build graph pipeline:
- Detect - Identify the build system (Gradle, Maven, Bazel, sbt)
- Resolve - Extract the classpath JAR list via build tool subprocess
- Scan - Parse
.classbytecode from each JAR intoClassStubrecords - Cache - Persist parsed stubs per JAR (SHA-256 keyed) for incremental rebuilds
- Index - Merge all stubs into a
ClasspathIndexfor fast FQN lookup - Emit - Create synthetic graph nodes and register in
ExportMap
§Feature Gate
All classpath functionality is gated behind the jvm-classpath feature on sqry-core.
When disabled, no classpath code is compiled and there is zero overhead.
Modules§
- bytecode
- JVM bytecode parsing.
- detect
- Build system detection for JVM projects.
- graph
- Graph integration for classpath data.
- kotlin
- Kotlin metadata extraction from
@kotlin.Metadataannotations. - pipeline
- Classpath pipeline orchestration.
- resolve
- Classpath resolution via build tool subprocesses.
- scala
- Scala signature extraction from
@ScalaSignatureannotations. - stub
- Stub data model for parsed bytecode.
Enums§
- Classpath
Error - Errors that can occur during classpath analysis.
Type Aliases§
- Classpath
Result - Result type for classpath operations.