API Monitoring & Observability
Anka Secure API provides built-in observability features to facilitate comprehensive monitoring of API performance, usage metrics, errors, and overall system health.
Overview
Monitoring and observability are critical for maintaining the reliability and performance of your cryptographic infrastructure. Anka Secure API integrates seamlessly with standard monitoring tools, providing endpoints to capture real-time operational insights.
Monitoring Capabilities
Anka Secure API supports comprehensive monitoring through the following built-in capabilities:
- Endpoint Usage Tracking: Detailed statistics on requests per API endpoint.
- System Metrics: JVM metrics, CPU usage, memory consumption, and thread usage.
- Error Logging: Structured logs for API errors, facilitating troubleshooting.
- Key Usage Statistics: Insights into cryptographic key usage counts, expiration dates, and soft-limit warnings.
- License Usage Metrics: Usage counts, quotas, and license expiration monitoring.
- Prometheus Integration: Native metrics exposure compatible with Prometheus, enabling visualization via Grafana.
Monitoring Endpoints
The following endpoints are provided by Spring Boot Actuator and Micrometer, enabling you to retrieve monitoring data easily:
Endpoint | URL | Description |
---|---|---|
Health | /actuator/health |
Application health status (UP/DOWN) |
Metrics Overview | /actuator/metrics |
List of all available application metrics |
Detailed Metrics | /actuator/metrics/{metric-name} |
Specific metric details (e.g., CPU, memory usage) |
Prometheus Metrics | /actuator/prometheus |
Metrics formatted for Prometheus ingestion |
Application Info | /actuator/info |
General information about the application |
Examples of Usage
Health Check
Response:
General Metrics List
Simplified response:
{
"names": [
"http.server.requests",
"jvm.memory.used",
"process.cpu.usage",
"system.cpu.usage",
"jvm.threads.live"
]
}
Specific Metric (e.g., CPU Usage)
Response example:
{
"name": "system.cpu.usage",
"measurements": [
{
"statistic": "VALUE",
"value": 0.0425
}
],
"availableTags": []
}
Prometheus Metrics
To integrate with Prometheus, query:
Prometheus-formatted response:
# HELP process_cpu_usage CPU usage of the Java process
# TYPE process_cpu_usage gauge
process_cpu_usage 0.002451
...
Recommended Prometheus Configuration
Integrate Anka Secure API metrics into Prometheus by configuring your prometheus.yml
as follows:
scrape_configs:
- job_name: 'anka-secure-api'
metrics_path: '/actuator/prometheus'
static_configs:
- targets: ['demo.ankatech.co:443']
Integration with Observability Tools
Anka Secure API natively supports integration with industry-standard observability tools:
- Prometheus: For metrics scraping
- Grafana: Visualization and dashboards
- Dynatrace: Comprehensive observability and monitoring
- Datadog: Comprehensive observability and monitoring
Ensure your monitoring solutions are configured to consume data from provided endpoints for optimal visibility.
Support
For additional assistance and advanced monitoring configuration, please contact our support team or refer to the Swagger UI for interactive endpoint testing and details.