At 1:46 PM -0800 3/17/99, Marc Respass wrote:
>> Anyone have any experience with the performance price of reusable
>> components?
>>
>> I'd love to use components in my project where it makes sense. The docs
>> seem to support taking this approach.
>>
>> Then when you read the tuning and deployment section, it talks about
>> reducing your components.
>>
>> Any comments?
>>
>> Components seems the way to make the project development time go very
>> quick.... I'm just worried about deployment.
>
> I can only tell you my experience. Running on my development system (NT 4
> workstation and SP3 using WebObjects' web server instead of IIS and
> accessing a Paradox database via ODBC (Paradox is similar to Access - no
> database server) and using nested reusable components, I do not notice any
> real difference. Obviously, the smaller the web page, the quicker the page
> loads but I don't feel like WO is slowing down as it builds the reusable
> components. I use a reusable navigation header that contains my own reusable
> ActiveImage component so every page has a reusable component inside a
> reusable component. Plus, my ActiveImage component appears about eight times
> in the header :o. The advantages of reusable components far outweigh the
> disadvantages.
WO has a cache that loads pages into an object graph. Pages are
then instantiated from that graph. That is, it parses the HTML file
and the WOD into a data structure that's something like:
Raw HTML: 200 bytes
WebObject-PopupMenu1
RAWHTML: 200 bytes
So when it generates a page, it "printf"s 200 bytes, causes
PopupMenu1 to generate HTML, then spits out 200 more bytes.
I don't know whether or not they flatten the object graph or not,
but worst case, it would be something like this if you had a
component included twice in a page.
Raw HTML: 200 bytes
Component-1
Raw HTML: 20 bytes
WebObject-PopupMenu1
Raw HTML: 20 bytes
Component-2
Raw HTML: 20 bytes
WebObject-PopupMenu2
Raw HTML: 20 bytes
Raw HTML: 200 bytes
So the only disadvantage to having a component rather then a bunch
of WO tags is an extra pointer lookup, if that. It takes longer for
you to send 200 bytes out your ethernet connection then it does for
it to recurse through the graph one level. If they flatten the graph,
it wouldn't matter at all.
If it really bothers you, CyberStudio supports components in a
slightly different manner, you'd just have to add an extra "publish"
step to your development cycle.
Pierce
----------------------------------------------------------------
Pierce T. Wetter III, Director, Twin Forces, Inc.
e-mail: [EMAIL PROTECTED] Phone:520-779-4227
<http://www.twinforces.com/>
U.S. Mail: 1300 South Milton Rd, Suite 206, Flagstaff, AZ 86001