为了制定某些周转基金基准,我需要有一个方法来获得交换数据(所有信头(甚至TCP)/压缩/...)的大小。
它在一个更大的基准中(它也尝试不同的绑定、编码、...), 所以我需要用程序来做它,
有钩子的地方这样做吗?
所有频道/装订器/编码器都是以程序方式创建的,以使一些测试自动化。
为了制定某些周转基金基准,我需要有一个方法来获得交换数据(所有信头(甚至TCP)/压缩/...)的大小。
它在一个更大的基准中(它也尝试不同的绑定、编码、...), 所以我需要用程序来做它,
有钩子的地方这样做吗?
所有频道/装订器/编码器都是以程序方式创建的,以使一些测试自动化。
Write a MessageInspector. This will give you an event for all messages. http://msdn.microsoft.com/en-us/library/system.servicemodel.dispatcher.clientruntime.messageinspectors.aspx
You might be able to use WMI performance counters http://msdn.microsoft.com/en-us/library/ms735098.aspx
您有两个选项 :
I m not sure why you prefer the former - I recommend to try wireshark, I m sure it can be automated too. Anyway if you want to do this inside wcf you should implement a custom message encoder to calaulate the size of bytes that go on the wire. this would need to be a generic encoder that wraps any other encoder inside it. here is an example for a generic encoder. note that the encoder approach will only consider the message size, but not any framing on top of it (HTTP headers for example). This is why I think wireshark is better for your case.
What is the use of default keyword in C#? Is it introduced in C# 3.0 ?
I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...
I m pretty new to the Objective-C world and I have a long history with .net/C# so naturally I m inclined to use my C# wits. Now here s the question: I feel really inclined to create some type of ...
I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class. My import looks like this: [DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr ...
I have two EF entities. One has a property called HouseNumber. The other has two properties, one called StartHouseNumber and one called EndHouseNumber. I want to create a many to many association ...
How to user GhostScript DLL to convert PDF to PDF/A. I know I kind of have to call the exported function of gsdll32.dll whose name is gsapi_init_with_args, but how do i pass the right arguments? BTW, ...
Since I cannot order my dictionary, what is the best way of going about taking key value pairs and also maintaing an index?
Maybe it s something I m doing wrong. I m just learning Linq because I m bored. And so far so good. I made a little program and it basically just outputs all matches (foreach) into a label control. ...