Package io.vertigo.core.analytics
Interface AnalyticsManager
- All Superinterfaces:
Component,CoreComponent,Manager
- All Known Implementing Classes:
AnalyticsManagerImpl
Main access to all analytics functions.
- Author:
- pchretien, npiedeloup
-
Method Summary
Modifier and TypeMethodDescriptionvoidAdds an already built AProcess (via the builder) for tracking process that are not executed in a single thread environnement.aggregate(List<HealthCheck> healthChecks) Generates an aggregated status from a list of health checks.voidTraces a process and collects metrics during its execution.<O> OtraceWithReturn(String category, String name, Function<Tracer, O> function) Traces a process that has a return value (and collects metrics during its execution).
-
Method Details
-
trace
Traces a process and collects metrics during its execution. A traced process is stored by categories.- Parameters:
category- the category of the processname- the name of the processconsumer- the function to execute within the tracer
-
traceWithReturn
Traces a process that has a return value (and collects metrics during its execution). A traced process is stored by categories.- Parameters:
category- the category of the processname- the name of the processfunction- the function to execute within the tracer- Returns:
- the result of the traced function
-
getCurrentTracer
- Returns:
- the current tracer if it has been created before
-
addSpan
Adds an already built AProcess (via the builder) for tracking process that are not executed in a single thread environnement. Prefer the use of method trace and traceWithReturn for commons cases (easier)- Parameters:
span- the built process
-
getHealthChecks
List<HealthCheck> getHealthChecks()- Returns:
- the list of health checks
-
aggregate
Generates an aggregated status from a list of health checks.- Parameters:
healthChecks- the list of halth checks.- Returns:
- the global health status
-
getMetrics
- Returns:
- the list of metrics
-