Performance problems

Developer
Apr 4, 2009 at 7:56 PM
I'm trying to use CThru with Asp.Net, and I see big performance problems. A test containing an http request takes about 55 seconds on my box (that's because of the initial precompilation), and more than 300 seconds with the CThru engine listening.

That's a shame, cause I was hoping to use it in Ivonna, which is already damn slow.
Coordinator
Apr 4, 2009 at 8:52 PM
CThru is not currently optimized.
I'm working on it, but your best thing to do is to get the latest source, and look in the CThru.sln in CThru project in here:
http://cthru.codeplex.com/SourceControl/changeset/view/21077#346322

look inside the
CallbackBeforeMethodCall
method. there are ways to optimize it so that only calls relating to HTTPRuntime are intercepted and everything else is ignored (LetIsolatorDecide option).
You can compile it so that it is optimized specifically for Ivonna.
Developer
Apr 7, 2009 at 12:35 PM
Would be cool to be able to alter that programmatically instead of altering the source. Would be even better to let the aspect decide. Each aspect knows the classes it needs, the engine asks all aspects and ignores the rest of the classes.

If you think it's a good idea, I could create a patch..
Developer
Apr 13, 2009 at 6:15 PM
Turned out the performance is a lot better this way. I added an abstract ShouldProcess method to the Aspect class, and the engine loops through all added aspects and checks if the method should be processed. At the same time, this approach separates the decision "should I process this method?" from the actual processing.

Next question is, if I use it in Ivonna, should I publish my version of the source?
Coordinator
Apr 14, 2009 at 10:51 AM
Go ahead and create your own custom version to use.
If you have unit tests for this functionality, go ahead and send me a patch.
I'll incorporate it after review.