-
Notifications
You must be signed in to change notification settings - Fork 84
Description
Hi
I'm sending String objects by publisher in C# each one millisecond to a Crossbar's topic. When I suscribe in this topic for a long time, the onError exception prints: "WampSharp.V2.Core.Contracts.WampConnectionBrokenException" and close the connection. The broker Crossbar only print that the suscriber left the topic.
What happened?
This is the publisher's code:
DefaultWampChannelFactory channelFactory = new DefaultWampChannelFactory();
IWampChannel channel = channelFactory.CreateJsonChannel(wsuri, realm);
IWampClientConnectionMonitor monitor = channel.RealmProxy.Monitor;
monitor.ConnectionBroken += OnClose;
monitor.ConnectionError += OnError;
await channel.Open().ConfigureAwait(false);
IWampRealmServiceProvider services = channel.RealmProxy.Services;
crossbarSubject = services.GetSubject<String>(myTopic);
crossbarSubject.OnNext(randomString);
This is the suscriber code:
DefaultWampChannelFactory channelFactory = new DefaultWampChannelFactory();
IWampChannel channel = channelFactory.CreateJsonChannel(wsuri, realm);
IWampClientConnectionMonitor monitor = channel.RealmProxy.Monitor;
monitor.ConnectionBroken += OnClose;
monitor.ConnectionError += OnError;
await channel.Open().ConfigureAwait(false);
IWampRealmServiceProvider services = channel.RealmProxy.Services;
crossbarSubject = services.GetSubject<String>(myTopic);
IDisposable disposable = crossbarSubject .Subscribe(
x => {
ProccessString(randomString);
},
onError => {
Console.WriteLine("error: " + onError);
},
() => Console.WriteLine("Done...")
);
I'm using crossbar for python 3.6 64 bits, WampSharp v2 and .NET Framework 4.6.1