Skip to main content

Supported languages

Dorgu detects the primary language of your application by looking for well-known manifest files in the project root:
If multiple language files are detected (e.g., both package.json and requirements.txt), Dorgu uses heuristics and the Dockerfile base image to determine the primary language.

Supported frameworks

Once the language is identified, Dorgu inspects dependency manifests to detect the framework in use: Framework detection influences the generated manifests — for example, a Spring Boot app gets a default port of 8080 and JVM-appropriate resource limits, while an Express app defaults to port 3000 with lower memory requirements.

Health endpoint detection

Dorgu scans your source code for common health endpoint patterns. When found, these are used to configure liveness and readiness probes in the generated Kubernetes manifests. Detected endpoints:
  • /health
  • /healthz
  • /ping
  • /ready
  • /readyz
  • /livez
  • /status
The scanner looks for route registrations in your source code (e.g., app.get("/health", ...) in Express, @app.get("/health") in FastAPI, r.GET("/health", ...) in Gin). If multiple health endpoints are found, Dorgu uses /healthz or /health for liveness and /readyz or /ready for readiness probes.

Metrics endpoint detection

Dorgu also checks for Prometheus-compatible metrics endpoints:
  • /metrics
  • /prometheus
When a metrics endpoint is detected, the generated manifests include Prometheus scrape annotations on the pod template:

Dependency extraction

Dorgu reads dependencies from each language’s standard manifest file to understand the application’s technology stack: Extracted dependencies are used for framework detection, identifying database drivers (to suggest appropriate resource limits), and populating the persona’s dependency metadata.

LLM-enhanced detection

When using the --llm-provider flag, the LLM augments static analysis with deeper understanding:
The LLM can identify:
  • Frameworks not in the static detection list — less common or newer frameworks
  • Architectural patterns — microservice vs monolith, event-driven, CQRS
  • Resource sizing recommendations — based on the application’s actual code patterns
  • Security practices — identifying sensitive data handling, authentication mechanisms
LLM analysis results are merged with static analysis — static detection always takes precedence for known frameworks to ensure deterministic behavior.

Adding support

Framework detection logic lives in internal/analyzer/code.go in the Dorgu CLI repository. To add support for a new language or framework:
  1. Add the detection file to the language detection map
  2. Add the framework’s dependency identifier to the framework detection map
  3. Add default port and resource recommendations for the framework
Contributions are welcome — see the contributing guide for details.