tags:

views:

62

answers:

1

Hi All,

Good day.

CppApp and CsApp Event Handle Design Changed. For Industry application.

Old design.

CsApp pull event from CppApp. There are a lot of events from CppApp. So we created two threads in CsApp to handle the events from CppApp. It worked very well.

New design.

CsApp and CppApp com event (fire event method) design instead of the push/pull event method. Only one pointer in Cpp IDL file created, but it could still handle two fire events function, we didn't change the CppApp event related part code. That means One Com Event Channel between CppApp and CsApp now.

Test Result. We tested and it on simulation mode and it worked very well. But there is not enough real machine online testing till now. Specially there where be a lot of event at industry online production envrionment.
We worry about if there is some Com Event Sending from CppApp to CsApp delay.

Is there any resource which i could research about Com Event performance for industry application?

Thanks a lot in advance here.

BR! Nano

+1  A: 

It isn't clear to me what the difference is between "we tested and it on simulation mode and it worked very well" and "real machine online testing at industry online production envrionment":

  • What are the differences between the simulation machine and the production machine?
  • Can you simulate these differences?
  • When you say that you "tested it on simulation mode", did you do performance/load testing (generating, in your simulation, as many events per second as you expect on the real machine)?
  • Do you allow any extra margin for safety (e.g., I might feel comfortable if my testing shows that my software needs only 10% of the machine's CPU capacity ... because then even if if it needs 10 times more than that in real life, that's still enough)?
  • The end-user/customer will eventually do acceptance testing on the real machine. Can you work with them, to get you access to the real machine?

We worry about if there is some Com Event Sending from CppApp to CsApp delay

Well, COM is faster when it's used in-process instead of inter-process or out-of-process: when the COM object is a DLL loaded into the same process as whatever is using it.

Is there any resource which i could research about Com Event performance for industry application?

I don't know; for what it's worth, the article Events vs. Callbacks says,

Performance Issues

When performance is at stake, it will usually be worthwhile to do the extra work required to create custom callback interfaces. By employing early binding in the callback interface connection code, significant improvements can be made in high-volume or in-process components. By design, event interfaces are not vtable bound and are, therefore, slower in most scenarios than comparable early-bound callback interfaces.

Of course, in any performance issue, the only way to gauge your own needs is to experiment, benchmark, and test. Try out the various permutations yourself and do the math. If you really care about getting the absolute last spurt of speed, then doing the tests is the only way to prove what works, no matter what promises are made.

Other articles in that section of MSDN are also relevent to performance, for example Understanding and Using COM Threading Models

ChrisW
Hello ChrisW,Thanks a lot for your input. It is really great help for me.I think i need think more about "How to do the testing to compare Old design and New design based on Simulation Mode and Realtime Mode".
Nano HE