Prerequisites
- Java 11 or higher
- (Optional) Phoenix API key if using auth
Add Dependencies
1. Gradle
Add the dependencies to yourbuild.gradle:
Setup Phoenix
- Docker
- Phoenix Cloud
Pull latest Phoenix image from Docker Hub:Run your containerized instance:This command:
- Exposes port 6006 for the Phoenix web UI
- Exposes port 4317 for the OTLP gRPC endpoint (where traces are sent)
Configuration for Phoenix Tracing
Run Spring AI
By instrumenting your application, spans will be created whenever it is run and will be sent to the Phoenix server for collection.Observe
Once configured, your OpenInference traces will be automatically sent to Phoenix where you can:- Monitor Performance: Track latency, throughput, and error rates
- Analyze Usage: View token usage, model performance, and cost metrics
- Debug Issues: Trace request flows and identify bottlenecks
- Evaluate Quality: Run evaluations on your LLM outputs

