Why leave testing for the end? Why not strictly leave chapter 13 to
optimization, and start indoctrinating people with testing from the
beginning?
IMHO, the more people are exposed to testing, the more likely they
are to understand and use it in their own development. By leaving
testing until the end, it would seem to me that you are saying,
"yeah, you can do automated testing" ;) But by dropping examples of
testing throughout the text, you say "this is how we do X in C::A,
and this is how we test to make sure that's what it really does".
Just my two cents worth.
Good luck! Sounds awesome :) Looking forward to seeing this.
Jason
On Sep 4, 2005, at 7:02 PM, Jaldhar H. Vyas wrote:
A couple of months back we had some discussion on a
CGI::Application book.
I think I am ready to get started on this. As a first step to
making a
proposal to a publisher[1] here is a synopsis of the books possible
contents. This is just a brain dump so I appreciate any and all
comments,
criticism and suggestions.
Tentative title: Modern CGI Applications in Perl
Ch 1: Common Gateway Interface
What is CGI? Perl good language for CGI. CGI not dead yet.
(Advantages
over proprietary methods like java, .net) CGI.pm standard for perl
CGI
programming (with example.)
Ch 2: Architecture of a CGI::App
Model-View-Controller design pattern explained. CGI.pm's
inadequacy for
MVC. CGI::Application is a solution. CGI.pm example rewritten using
CGI::Application and contrasted. Basic CGI::App features (setup,
teardown
runmodes etc.) introduced.
Ch 3: Run modes.
The central concept of run modes explained in detail. run_modes(),
start_mode(), error_mode(), mode_param() explained. The CGI::App
processing pipeline. setup(), teardown(), cgiapp_prerun(),
cgiapp_postrun(),
Ch 4: Templates
HTML::Template and all its features introduced.
Ch 5: Object orientation
The OOP nature of CGI::App discussed. cgiapp_init(). Plugins.
subclassing and mixins discussed. When to use each.
Ch 6: Processing Forms
How to do it with CGI::App. tainting and other security issues.
HTML::FillInForm. Data::FormValidator, C::A::P::ValidateRM
Ch 7: Database Integration
C::A::P::DBH, Implementing BREAD (or CRUD) with C::A::P::Bread,
C::A::P::DBIProfiler, SQL::Abstract, Data::Page discussed.
Ch 8: Sessions and Authentication
Cookies. CGI::Session and C::A::P::Session discussed and explained.
session id in url as an alternative to cookies. Authen and Authz
discussed.
Ch 9: Alternative Output
C::A::P::Stream. C::A::P::Gzip, outputting PDFs, CSV files or sending
email.
Ch 10: Further Enhancements to the Application
Some miscellaneous topics. The various plugins related to
configuration
discussed and contrasted. Logging with C::A::P::LogDispatch.
Validation
and clean HTML with C::A::P::HtmlTidy
Ch 11: Enhancing interactivity with AJAX
HTML::Prototype and C::A::P::HTMLPrototype
Ch 12: Alternative Templating
Template Toolkit and C::A::P::TT. C::A::P::HtDot,
C::A::P::PageBuilder,
C::A::P::TemplateRunner, C::A::P::AnyTemplate
Ch 13: Testing and Optimizing the Application
Testing. Ways to speed things up discussed. Running under
Apache::Registry for
modperl. C::A::P::Apache
Ch 14: Distributing the Application
Best practices for Layout of directories and resources (templates
etc.)
Packaging a CGI::App for CPAN
Appendix A: Getting help
CGI::App wiki and mailing list
Appendix B: CGI environment variables
Appendix C: HTTP Error codes, headers and other relevant info.
[1] Although self-publishing, making it purely web etc. were
discussed. I
think it would help further boost the legitimacy of CGI::App if the
book
was available in every Borders, Barnes & Nobles etc.
--
Jaldhar H. Vyas <[EMAIL PROTECTED]>
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/[email protected]/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/[email protected]/
http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]