Search in sources :

Example 6 with RSocketConnector

use of io.rsocket.core.RSocketConnector in project spring-framework by spring-projects.

the class DefaultRSocketRequesterBuilder method connect.

@Override
@SuppressWarnings("deprecation")
public Mono<RSocketRequester> connect(ClientTransport transport) {
    RSocketStrategies rsocketStrategies = getRSocketStrategies();
    MimeType metaMimeType = getMetadataMimeType();
    MimeType dataMimeType = getDataMimeType(rsocketStrategies);
    RSocketConnector connector = initConnector(this.rsocketConnectorConfigurers, metaMimeType, dataMimeType, rsocketStrategies);
    return connector.connect(transport).map(rsocket -> new DefaultRSocketRequester(null, rsocket, dataMimeType, metaMimeType, rsocketStrategies));
}
Also used : RSocketConnector(io.rsocket.core.RSocketConnector) MimeType(org.springframework.util.MimeType) WellKnownMimeType(io.rsocket.metadata.WellKnownMimeType)

Aggregations

RSocketConnector (io.rsocket.core.RSocketConnector)6 WellKnownMimeType (io.rsocket.metadata.WellKnownMimeType)4 MimeType (org.springframework.util.MimeType)4 PayloadDecoder (io.rsocket.frame.decoder.PayloadDecoder)2 LoadbalanceRSocketClient (io.rsocket.loadbalance.LoadbalanceRSocketClient)2 Field (java.lang.reflect.Field)2 NettyDataBufferFactory (org.springframework.core.io.buffer.NettyDataBufferFactory)2 ByteBuf (io.netty.buffer.ByteBuf)1 ByteBufAllocator (io.netty.buffer.ByteBufAllocator)1 ConnectionSetupPayload (io.rsocket.ConnectionSetupPayload)1 DuplexConnection (io.rsocket.DuplexConnection)1 Payload (io.rsocket.Payload)1 RSocketErrorException (io.rsocket.RSocketErrorException)1 DefaultConnectionSetupPayload (io.rsocket.core.DefaultConnectionSetupPayload)1 RSocketClient (io.rsocket.core.RSocketClient)1 ClientTransport (io.rsocket.transport.ClientTransport)1 DefaultPayload (io.rsocket.util.DefaultPayload)1 InetSocketAddress (java.net.InetSocketAddress)1 SocketAddress (java.net.SocketAddress)1 Duration (java.time.Duration)1