コード例 #1
0
        protected override long DoClient(NetMQSocket socket, int messageSize)
        {
            var msg = new byte[messageSize];

            var watch = Stopwatch.StartNew();

            for (int i = 0; i < Iterations; i++)
            {
                socket.SendFrame(msg);
                socket.SkipFrame(); // ignore response
            }

            return(watch.ElapsedTicks);
        }
コード例 #2
0
ファイル: LatencyBenchmark.cs プロジェクト: cjkao/netmq
        protected override long DoClient(NetMQSocket socket, int messageSize)
        {
            var msg = new byte[messageSize];

            var watch = Stopwatch.StartNew();

            for (int i = 0; i < Iterations; i++)
            {
                socket.SendFrame(msg);
                socket.SkipFrame(); // ignore response
            }

            return watch.ElapsedTicks;
        }