public interface ObservationCollector
basic.get
).
Implementations can gather information and send it to tracing backends. This allows e.g. following the processing steps of a given message through different systems.
This is considered an SPI and is susceptible to change at any time.
ConnectionFactory.setObservationCollector( ObservationCollector)
,
MicrometerObservationCollectorBuilder
Modifier and Type | Interface and Description |
---|---|
static interface |
ObservationCollector.BasicGetCall
Underlying
basic.get call. |
static interface |
ObservationCollector.ConnectionInfo
Connection information.
|
static interface |
ObservationCollector.PublishCall
Underlying publishing call.
|
Modifier and Type | Field and Description |
---|---|
static ObservationCollector |
NO_OP |
Modifier and Type | Method and Description |
---|---|
Consumer |
basicConsume(String queue,
String consumerTag,
Consumer consumer)
Decorate consumer registration.
|
GetResponse |
basicGet(ObservationCollector.BasicGetCall call,
String queue)
Decorate message polling with
basic.get . |
void |
publish(ObservationCollector.PublishCall call,
AMQP.Basic.Publish publish,
AMQP.BasicProperties properties,
byte[] body,
ObservationCollector.ConnectionInfo connectionInfo)
Decorate message publishing.
|
static final ObservationCollector NO_OP
void publish(ObservationCollector.PublishCall call, AMQP.Basic.Publish publish, AMQP.BasicProperties properties, byte[] body, ObservationCollector.ConnectionInfo connectionInfo) throws IOException
Implementations are expected to call publish( PublishCall,
AMQP.Basic.Publish, AMQP.BasicProperties, byte[], ConnectionInfo)
to make sure the message is
actually sent.
call
- publish
- properties
- body
- connectionInfo
- IOException
Consumer basicConsume(String queue, String consumerTag, Consumer consumer)
Implementations are expected to decorate the appropriate Consumer
callbacks. The
original Consumer
behavior should not be changed though.
queue
- consumerTag
- consumer
- GetResponse basicGet(ObservationCollector.BasicGetCall call, String queue)
basic.get
.
Implementations are expected to basicGet( BasicGetCall, String)
and
return the same result.
call
- queue
- Copyright © 2023 VMware, Inc. or its affiliates.. All rights reserved.