Apr 17 2006

Model-Glue: Not optimal under load

Posted by Joe Rinehart at 10:08 AM
8 comments
- Categories: Model-Glue

I'm working with Mike Brunt over at Webapper to add Model-Glue to the list of CFPetmarket apps that have been tested. When I got preliminary results back, I was a little suprised: it was much slower than I thought it'd be.

I've never had an opportunity to compare it side-by-side with a Mach-II (or Fusebox) application, and because my Petmarket implementation used the same model code as the Mach-II implementation, I was able to use the Mach-II version as a reference for performance tuning.

It turns out I made two low-level mistakes in the framework: the CFC that most people know as "arguments.event" was re-instantiated for each <event-handler>, and, when it was instantiated, it re-instantiated the CFC that handles Event Bean population. I've tuned those two flaws out of the core, and JMeter (the Apache foundation's F/OSS load test tool) is showing that M2 and MG behave comparably under heavy (100-thread) load.

I'm testing this as a 1.1.01 release of Model-Glue right now, and if anyone else wants to give it a whirl, it's comitted to the Subversion BER URL.

Comments

Craig M. Rosenblum

Craig M. Rosenblum wrote on 04/17/06 11:41 AM

Just two serious questions...

1. How do each of the framework's compare in terms of performance, creating the same basic app.

2. What kind of processing does each have to do, to allow the special handling that makes developing in x framework that much easier?

Just something I always wanted to know...

And what is reasonable and what is not...Where do you draw the line?
Sean Corfield

Sean Corfield wrote on 04/17/06 12:03 PM

FWIW Joe, I've found that trusted cache makes a bigger difference to the performance of MG than to M2 - which might be explained by the extra CFC creation MG was doing.

To Craig, performance can only be determined for a specific application and a specific usage pattern so we'd first need to build an application that could be implemented almost identically across all of the frameworks. Seems like Joe is going in the right direction here. A Fusebox app could be built from the common model that Joe is using. Based on my experiences and timing on a variety of applications, I would expect Fusebox to be fastest (because of its compile-to-straight-line-CFML approach and then Model-Glue and Mach II fairly close together - and my tests suggest Model-Glue should be a little faster than Mach II. However, the overhead of these three frameworks is insignificant in the overall picture. The maintenance benefits far outweigh any performance issues (servers and memory is cheaper than developers in the long run).

Not really sure what you're asking in your second point...?
Craig M. Rosenblum

Craig M. Rosenblum wrote on 04/17/06 12:05 PM

For example in fusebox, there is extra processing to enable model-viuiiew controller to run on each page, to determine for this app, what file has the model, view or controller.

I am just curious as to what processing each type of framework has to enable the features such as this.
Sami Hoda

Sami Hoda wrote on 04/17/06 12:43 PM

Joe,

Thanks for your hard work. This is something I've been asking the community for, for a very long time.

And I have Simon to thanks for the PetMarket comparisons!

Oh, how things work out in mysterious ways! Who would have thought.

Sami
Sean Corfield

Sean Corfield wrote on 04/17/06 1:16 PM

Craig, there may be more work for a developer to create separate circuits for Model, View and Controller in Fusebox but since each top-level fuseaction is compiled down to straight-line-CFML, there is no runtime overhead for MVC in Fusebox because the 'do' verb is compiled away completely.

If your controller circuit has:

do action=&quot;m.getdata&quot;

do action=&quot;v.showview&quot;

The compiled result is exactly as if you had written the bodies of the getdata fuseaction and showview fuseaction directly inside the controller. That's one of the great things about Fusebox: structuring code into circuits introduces no overhead.
Britt

Britt wrote on 04/17/06 8:03 PM

So, its safe to say you will be releasing a maintenance update in the near future that takes care of these minor load issues. Will you be making a blog post when 1.1.01 is released officially?

Thanks for the hard work as always, greatly appreciative.
etjqxtdn

etjqxtdn wrote on 08/11/08 5:19 AM

wimjbywd http://ledjclpx.com rvkjezoe dvwiqjwn <a href="http://ntvmasxv.com">ezuetzwa</a>; [URL=http://dnseqkqz.com]prcoyqao[/URL]
Mihaela

Mihaela wrote on 09/29/08 3:35 AM

The compiled result is exactly as if you had written the bodies of the getdata fuseaction and showview fuseaction directly inside the controller. That's one of the great things about Fusebox: structuring code into circuits introduces no overhead.
http://www.batteryfast.co.uk/asus/m6-2.php asus a42-m6 m6n m67 m68n m6000 laptop battery,
http://www.batteryfast.co.uk/asus/a42-w1.php asus W1 W1000 A42-W1 W1G W1Ga laptop battery,
http://www.batteryfast.co.uk/asus/a31-s5-2.php ASUS A31-S5 A32-S5 S52N S5000 S5200N S5N laptop battery,
http://www.batteryfast.co.uk/mitac/8375-2.php MITAC 8175 8375 8575 8575A 8575P LAPTOP BATTERY black laptop battery,
http://www.batteryfast.co.uk/toshiba/pa3176u-1bas-2.php Battery For Toshiba Portege M200 M205 PA3128U PA3191U black laptop battery,
http://www.batteryfast.co.uk/acer/batcl32l.php acer aspire batcl32l 2000 batcl32 2001 2003 laptop battery,

http://www.batteryfast.co.uk/acer/btp-73e1.php acer travelmate 370 380 btp-73e1 btp-50t3 laptop battery,
http://www.batteryfast.co.uk/acer/1670.php acer LC.BTP05.004 Aspire 1670 series laptop battery,
http://www.batteryfast.co.uk/acer/as07a41.php AS07A41 Aspire 4310 4520 4710 4920 laptop battery,
http://www.batteryfast.co.uk/acer/batbl50l6.php Aspire 3100 3690 5100 5110 9110 9800 laptop battery,
http://www.batteryfast.co.uk/acer/batcl50l.php acer travelmate 290 291 29x 292 batcl50l laptop battery,
http://www.batteryfast.co.uk/acer/btp-36d1.php acer travelmate 350 352 353 354 btp-36d1 laptop battery,

http://www.batteryfast.co.uk/acer/btp-39d1.php acer btp-620 btp-39d1 btp-39sn ms2103 laptop battery,
http://www.batteryfast.co.uk/acer/btp-43d1.php acer travelmate 22x 23x 26x 28x btp-43d1 laptop battery,
http://www.batteryfast.co.uk/acer/squ-207.php acer 916-2350 BT.A0807.002 SQU-207 laptop battery,
http://www.batteryfast.co.uk/acer/squ-302.php acer BT.A1007.002 SQU-302 laptop battery,
http://www.batteryfast.co.uk/asus/a42-a4.php asus a4 a4d a4g a4k a4l a4s a4000 a42-a4 laptop battery,
http://www.batteryfast.co.uk/asus/a32-f3.php A32-F3 Battery ASUS F3 F3J F3Q F3JA F3JM F3JF Hi-Capaci laptop battery,

Write your comment



(it will not be displayed)