You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
create a rsocketSupplierProcessor with initial RSocket cluster information
create LoadBalancedRSocketMono from rsocketSupplierProcessor
invoke rsocketSupplierProcessor.onNext() to update RSocket cluster information
LoadBalancedRSocketMono will not work after cluster information updated. Maybe refreshSockets() not invoked after cluster updated.
// rsocket cluster
List<String> uriList1 = Arrays.asList("tcp://127.0.0.1:42252");
ReplayProcessor<List<RSocketSupplier>> rsocketSupplierProcessor = ReplayProcessor.cacheLast();
rsocketSupplierProcessor.onNext(uriList1.stream().map(uri -> new RSocketSupplier(() -> rSocket(uri))).collect(Collectors.toList()));
LoadBalancedRSocketMono rSocketMono = LoadBalancedRSocketMono.create(rsocketSupplierProcessor);
//update rsocket cluster, the update logic in io.rsocket.client.RSocketSupplierPool.handleNewFactories
// handleNewFactories does not invoke io.rsocket.client.LoadBalancedRSocketMono.refreshSockets();
List<String> uriList2 = Arrays.asList("tcp://localhost:42252");
rsocketSupplierProcessor.onNext(uriList2.stream().map(uri -> new RSocketSupplier(() -> rSocket(uri))).collect(Collectors.toList()));
The text was updated successfully, but these errors were encountered:
linux-china
changed the title
LoadBalancedRSocketMono refresh problem after Collection<RSocketSupplier> updated
LoadBalancedRSocketMono refresh problem after new Collection<RSocketSupplier>
May 16, 2019
Steps as following:
LoadBalancedRSocketMono will not work after cluster information updated. Maybe refreshSockets() not invoked after cluster updated.
The text was updated successfully, but these errors were encountered: