java.lang.Object
io.fluxzero.javaclient.publishing.DefaultMetricsGateway
- All Implemented Interfaces:
MetricsGateway,HasLocalHandlers
Default implementation of the
MetricsGateway interface.
This class delegates all functionality to an underlying GenericGateway instance, enabling the use of metrics
gateway methods while leveraging the generic gateway's capabilities.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.fluxzero.javaclient.tracking.handling.HasLocalHandlers
hasLocalHandlers, registerHandler, registerHandler, setSelfHandlerFilterMethods inherited from interface io.fluxzero.javaclient.publishing.MetricsGateway
publish, publish
-
Constructor Details
-
DefaultMetricsGateway
public DefaultMetricsGateway()
-
-
Method Details
-
publish
public CompletableFuture<Void> publish(Object payload, io.fluxzero.common.api.Metadata metadata, io.fluxzero.common.Guarantee guarantee) Description copied from interface:MetricsGatewayPublishes a metrics message with the specified metadata and delivery guarantee.This method may complete asynchronously.
- Specified by:
publishin interfaceMetricsGateway- Parameters:
payload- the metrics payloadmetadata- metadata to attach to the messageguarantee- delivery guarantee (e.g.,Guarantee.SENTorGuarantee.STORED)- Returns:
- a
CompletableFuturethat completes when the message is published (or not, depending on the guarantee)
-