Class MongoMetricsCommandListener
- java.lang.Object
-
- io.micrometer.core.instrument.binder.mongodb.MongoMetricsCommandListener
-
- All Implemented Interfaces:
com.mongodb.event.CommandListener
@NonNullApi @NonNullFields @Incubating(since="1.2.0") public class MongoMetricsCommandListener extends java.lang.Object implements com.mongodb.event.CommandListener
CommandListenerfor collecting command metrics fromMongoClient.- Since:
- 1.2.0
-
-
Constructor Summary
Constructors Constructor Description MongoMetricsCommandListener(MeterRegistry registry)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcommandFailed(com.mongodb.event.CommandFailedEvent event)voidcommandStarted(com.mongodb.event.CommandStartedEvent commandStartedEvent)voidcommandSucceeded(com.mongodb.event.CommandSucceededEvent event)
-
-
-
Constructor Detail
-
MongoMetricsCommandListener
public MongoMetricsCommandListener(MeterRegistry registry)
-
-
Method Detail
-
commandStarted
public void commandStarted(com.mongodb.event.CommandStartedEvent commandStartedEvent)
- Specified by:
commandStartedin interfacecom.mongodb.event.CommandListener
-
commandSucceeded
public void commandSucceeded(com.mongodb.event.CommandSucceededEvent event)
- Specified by:
commandSucceededin interfacecom.mongodb.event.CommandListener
-
commandFailed
public void commandFailed(com.mongodb.event.CommandFailedEvent event)
- Specified by:
commandFailedin interfacecom.mongodb.event.CommandListener
-
-