public interface MetadataExtractor
Payload metadata, which
could be composite metadata with multiple entries. Each metadata entry
is decoded based on its MimeType and a name is assigned to the decoded
value. The resulting name-value pairs can be added to the headers of a
Message.| Modifier and Type | Field and Description |
|---|---|
static org.springframework.util.MimeType |
COMPOSITE_METADATA
Constant MimeType
"message/x.rsocket.composite-metadata.v0". |
static String |
ROUTE_KEY
The key to assign to the extracted "route" of the payload.
|
static org.springframework.util.MimeType |
ROUTING
Constant for MimeType
"message/x.rsocket.routing.v0". |
| Modifier and Type | Method and Description |
|---|---|
Map<String,Object> |
extract(io.rsocket.Payload payload,
org.springframework.util.MimeType metadataMimeType)
Extract a map of values from the given
Payload metadata. |
static final String ROUTE_KEY
static final org.springframework.util.MimeType COMPOSITE_METADATA
"message/x.rsocket.composite-metadata.v0".static final org.springframework.util.MimeType ROUTING
"message/x.rsocket.routing.v0".Map<String,Object> extract(io.rsocket.Payload payload, org.springframework.util.MimeType metadataMimeType)
Payload metadata.
The Payload "route", if present, should be saved under ROUTE_KEY.payload - the payload whose metadata should be readmetadataMimeType - the metadata MimeType for the connection.