Module metrics

Module metrics 

Source
Expand description

Prometheus metrics for observability

This module provides comprehensive metrics collection for monitoring IPFRS interface performance, usage patterns, and system health.

Structs§

ASYNC_TASKS_ACTIVE
Number of goroutines (async tasks)
AUTH_ATTEMPTS_TOTAL
Authentication attempts
AUTH_SESSIONS_ACTIVE
Active authenticated sessions
BATCH_OPERATION_DURATION_SECONDS
Batch operation duration
BATCH_OPERATION_SIZE
Batch operation size (number of items)
BLOCKS_RETRIEVED_TOTAL
Total blocks retrieved
BLOCKS_STORED_TOTAL
Total blocks stored
BLOCK_ERRORS_TOTAL
Block operation errors
BLOCK_RETRIEVAL_DURATION_SECONDS
Block retrieval duration
CACHE_HITS_TOTAL
Cache hits
CACHE_MISSES_TOTAL
Cache misses
CACHE_SIZE_BYTES
Current cache size
DOWNLOAD_BYTES_TOTAL
Total bytes downloaded
GRPC_REQUESTS_TOTAL
gRPC requests total
GRPC_REQUEST_DURATION_SECONDS
gRPC request duration
HTTP_CONNECTIONS_ACTIVE
Currently active HTTP connections
HTTP_REQUESTS_TOTAL
Total number of HTTP requests by endpoint and method
HTTP_REQUEST_DURATION_SECONDS
HTTP request duration in seconds
HTTP_REQUEST_SIZE_BYTES
HTTP request body size in bytes
HTTP_RESPONSE_SIZE_BYTES
HTTP response size in bytes
MEMORY_ALLOCATED_BYTES
Total memory allocated (in bytes)
RATE_LIMIT_HITS_TOTAL
Rate limit hits (requests blocked)
RATE_LIMIT_TOKENS_AVAILABLE
Available rate limit tokens
STREAMING_CHUNK_SIZE_BYTES
Streaming chunk size
STREAMING_OPERATIONS_ACTIVE
Active streaming operations
TENSOR_OPERATIONS_TOTAL
Tensor operations total
TENSOR_SIZE_BYTES
Tensor size in bytes
TENSOR_SLICE_OPERATIONS_TOTAL
Tensor slice operations
Timer
Helper struct for timing operations
UPLOAD_BYTES_TOTAL
Total bytes uploaded
WEBSOCKET_CONNECTIONS_ACTIVE
Active WebSocket connections
WEBSOCKET_MESSAGES_RECEIVED_TOTAL
WebSocket messages received
WEBSOCKET_MESSAGES_SENT_TOTAL
WebSocket messages sent

Functions§

encode_metrics
Encode all metrics in Prometheus text format
finish_http_request_timer
Finish timing an HTTP request
record_auth_attempt
Record authentication attempt
record_block_error
Record block error
record_block_retrieved
Record block retrieval
record_block_stored
Record block storage
record_cache_hit
Record cache hit
record_cache_miss
Record cache miss
record_download_bytes
Record download bytes
record_http_request
Record an HTTP request
record_http_request_size
Record HTTP request size
record_http_response_size
Record HTTP response size
record_rate_limit_hit
Record rate limit hit
record_upload_bytes
Record upload bytes
start_http_request_timer
Start timing an HTTP request