IceSL 0.3.2: oneway outgoing calls not supported?

kwaclawkwaclaw Oshawa, CanadaKarl WaclawekOrganization: PersonalMember
I am accessing IceStorm from a Silverlight app.

The Slice definitions have no return values and no exceptions defined:
interface WhiteboardSession {
    ["ami"] void StartStroke(StylusPointSeq points);
    ["ami"] void AddPoints(StylusPointSeq points);
    ["ami"] void Clear();
    ["ami"] void Upload(StrokeDataSeq strokes);
  };

The code to get the proxy is this:
switch (args.Task) {
  case TaskType.Connect:
    try {
      topic = topicMgr.retrieve(args.Topic);
    }
    catch (IceStorm.NoSuchTopic) {
      topic = topicMgr.create(args.Topic);
    }
    try {
      topic.subscribeAndGetPublisher(qos, localWhiteboard.Proxy);
      Ice.ObjectPrx pub = topic.getPublisher();
      remoteWhiteboard = Wbs.WhiteboardSessionPrxHelper.uncheckedCast(pub.ice_oneway());
      Dispatcher.BeginInvoke(() => { ConnectBtn.Content = "Disconnect"; });
    }
    catch (IceStorm.AlreadySubscribed) { }
    catch {
      Dispatcher.BeginInvoke(() => { WhiteBoardNameBox.IsReadOnly = false; });
      throw;
    }
    break;

If I change the remoteWhiteboard proxy to a twoway proxy it works fine in Silverlight, but the oneway calls hang in Outgoing.invoke(), at Monitor.Wait(). The exact same code works OK with Ice for .NET.

The Ice setup has 4 client threads:
Ice.InitializationData initData = new Ice.InitializationData();
initData.properties = Ice.Util.createProperties();
initData.properties.setProperty("Ice.Default.Router", "Glacier2/router:tcp -p 4502 -h " + args.Address);
initData.properties.setProperty("Ice.ACM.Client", "0");
initData.properties.setProperty("Ice.RetryIntervals", "0 10 100");
initData.properties.setProperty("Ice.ThreadPool.Client.Size", "4");
initData.properties.setProperty("Ice.ThreadPool.Client.SizeMax", "16");
initData.properties.setProperty("Ice.MessageSizeMax", "1024");
initData.properties.setProperty("Ice.FactoryAssemblies", "WhiteBoardSL,version=1.0.0.0");

initData.properties.setProperty("TopicManager.Proxy", "Whiteboard/TopicManager:tcp -p 4505");
comm = Ice.Util.initialize(initData);

Ice.RouterPrx defaultRouter = comm.getDefaultRouter();
if (defaultRouter == null)
  throw new Exception("no default router set");

router = Glacier2.RouterPrxHelper.checkedCast(defaultRouter);
if (router == null)
  throw new Exception("configured router is not a glacier2 router");

session = router.createSession("", "");
String category = router.getCategoryForClient();

Ice.ObjectAdapter adapter = comm.createObjectAdapterWithRouter("WhiteboardAdapter", router);
WhiteboardSessionI wbSession = new WhiteboardSessionI(args.Page.InkP, adapter, category);

Karl

Comments

  • xdmxdm La Coruña, SpainJose Gutierrez de la ConchaOrganization: ZeroC, Inc.Project: Ice DeveloperAdministrators, ZeroC Staff ZeroC Staff
    Hi Karl,

    This is a bug in IceSl-0.3.2 socket transport, we are going to fix this in next IceSl release that would be available soon.

    Thanks for the bug report.

    José
Sign In or Register to comment.