Package io.bytestreams.exchange.core
Interface Transport
- All Superinterfaces:
AutoCloseable,Closeable
- All Known Implementing Classes:
ResilientTransport,SocketTransport
Pluggable I/O transport that provides input/output streams and connection metadata.
Implementations must be thread-safe: the input stream is read by the channel's reader thread while the output stream is written by the writer thread concurrently. Both methods may be called multiple times and should return the same underlying stream.
-
Method Summary
Modifier and TypeMethodDescriptionio.opentelemetry.api.common.AttributesReturns transport-level OTel attributes (e.g. network type, peer address, peer port).voidclose()Returns the input stream for reading inbound messages.Returns the output stream for writing outbound messages.
-
Method Details
-
inputStream
Returns the input stream for reading inbound messages.- Throws:
IOException
-
outputStream
Returns the output stream for writing outbound messages.- Throws:
IOException
-
attributes
io.opentelemetry.api.common.Attributes attributes()Returns transport-level OTel attributes (e.g. network type, peer address, peer port). -
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Throws:
IOException
-