[Analysis] Templates: The good, the bad, the ugly
jake at bugzilla.org
Thu Dec 9 09:21:14 UTC 2004
Gervase Markham wrote:
> Jake wrote:
>> What was supposed to happen?
>> Visualization items (eg, the HTML, etc) was supposed to be completly
>> seperated from code for all content generated by Bugzilla.
> That's not quite right - it's not "what was supposed to happen?", as
> if there was some deadline. It was more "what was the aim?".
Correct me if I'm wrong, but isn't the aim what's supposed to happen? I
really don't see much, if any, difference between the two.
>> What did happen?
> Similarly, "where have we got to so far?".
>> What went wrong?
>> While it's true that the presentation and the perl code are now seperate
>> from each other, there is still a lot of code in the middle of this
>> presentation. This code is in the form of template directives, some of
>> which are just as complicated as perl code.
> Perhaps we should file bugs on simplifying the most complicated of
> them. Although I challenge anyone to write the boolean chart template
> directives in a more simple way while still having them work. :-)
Good, bad, or indifferent, it's still code and it's still in the middle
of the presentation :)
>> Templates first came to life in Bugzilla as part of a completely
>> patch with little to no discussion beforehand about the implimentation,
>> template package, etc.).
> Well, sort of. Myk was just bored of waiting, maybe :-) And it's
> worked out for the best, IMO. I really like TT.
If that's what happened I think it's more for Myk to say. I'm not trying
to point fingers, though. And I never said I hated TT... I was trying to
stay somewhat objective. Kinda. ;)
>> The process was started in the middle of a development cycle and became
>> one of the blockers for the next release. Because it was such a huge
>> undertaking and reviews often took a considerable amount of time (and
>> was just finding the reviewer!), the stable release was delayed numerous
> True, if you are talking about the 2.16 release (for which most of the
> templating was done). But it's a bit late to post-mortem that, isn't it?
Hindsight is 20/20, they say. But they also say that those who don't
learn from the past are doomed to repeat it. It's obvious that we can't
change the 2.16 release date or criteria, but we can look at things that
happened in the past with an eye for the future. So, no, I don't think
it's too late.
>> Speed. While I haven't run any benchmarks, I've gotta believe that the
>> introduction of another processing engine (eg, Template Toolkit) had a
>> negative impact on our speed.
> If you count this, then you need to add "increased developer
> productivity" to the "what went right" section.
Now this is the kind of thing I'm looking for. I know my list of good
and bad can't possibly be complete.
> Has the speed decrease, if any, been significant enough to cause
> long-term problems for any sites?
Beats me. Like I said, I haven't done any testing :). And it may be hard
to notice with other speed improvements going in (like not calling a
separate perl process to send mail or optimized SQL queries).
More information about the developers