PoolInstrumentation
class PoolInstrumentation extends AbstractInstrumentation
Constants
| protected CONNECTION_COUNT_METRIC |
|
| protected CONNECTION_LIMIT_METRIC |
|
| protected CONNECTION_PENDING_REQUESTS_METRIC |
|
| protected CONNECTION_POOL_NAME_ATTRIBUTE |
|
| protected CONNECTION_STATE_ATTRIBUTE |
|
| protected STATE_IDLE |
|
| protected STATE_USED |
|
| protected OBJECTS_METRIC |
|
| protected OBJECTS_LIMIT_METRIC |
|
| protected OBJECTS_PENDING_REQUESTS_METRIC |
|
| protected OBJECT_POOL_NAME_ATTRIBUTE |
|
| protected OBJECT_POOL_STATE_ATTRIBUTE |
|
Properties
| protected InstrumentationOptions | $options | from AbstractInstrumentation |
Methods
Register the instrumentation with normalized options.
Register pool instruments and collection callbacks.
Determine whether a metric is enabled.
Determine whether the throwable is a direct coroutine cancellation.
Return the semantic conventions schema URL for Hypervel instrumentation scopes.
Index callback observers by their matching instrument name.
Create pool instrumentation.
Create one observable pool instrument.
Record snapshots from every existing database and Redis connection pool.
Record one existing connection-pool snapshot.
Record snapshots from every existing object pool.
Details
in
AbstractInstrumentation at line 21
final void
register(array $options)
Register the instrumentation with normalized options.
at line 58
protected void
registerInstrumentation()
Register pool instruments and collection callbacks.
in
AbstractInstrumentation at line 35
protected bool
tracesEnabled()
Determine whether trace output is enabled.
in
AbstractInstrumentation at line 43
protected bool
metricEnabled(string $name)
Determine whether a metric is enabled.
in
AbstractInstrumentation at line 53
protected bool
isDirectCancellation(Throwable|null $exception)
Determine whether the throwable is a direct coroutine cancellation.
Ending an operation by direct cancellation is control flow, not a failure.
in
AbstractInstrumentation at line 64
protected string
schemaUrl()
Return the semantic conventions schema URL for Hypervel instrumentation scopes.
Every tracer, meter and logger obtained for one scope must pass the same URL.
in
AbstractInstrumentation at line 79
protected array
indexObservers(array $names, array $observers)
Index callback observers by their matching instrument name.
The SDK supplies observers in the same order as the instruments passed to batchObserve(), so the unchanged name order is the mapping contract.
at line 47
__construct(PoolManager $databasePools, PoolManager $redisPools, PoolManager $objectPools, MeterProviderInterface $meterProvider)
Create pool instrumentation.
at line 113
protected ObservableUpDownCounterInterface
createInstrument(MeterInterface $meter, string $name)
Create one observable pool instrument.
at line 150
protected void
observeConnectionPools(array $observers)
Record snapshots from every existing database and Redis connection pool.
at line 166
protected void
observeConnectionPool(array $observers, ConnectionPool $pool, string $name)
Record one existing connection-pool snapshot.
at line 202
protected void
observeObjectPools(array $observers)
Record snapshots from every existing object pool.