Re: CLI and HTTP diagnostics design
- From: Tim Roberts <timr@xxxxxxxxx>
- Date: Tue, 26 May 2009 23:30:39 -0700
Derek Fountain <nomail@xxxxxxxxxxxxxxx> wrote:
I'm putting together a small PHP application which produces as its
output an XML file. The application needs to run from either an HTTP
request or a CLI invocation. HTTP requests don't come from a web
browser, they're called from an application that talks HTTP.
The issue I have one of diagnostics. The specification says there needs
to be a method for the user to see both runtime narration (i.e. what the
process does and why it chooses to do it), runtime warnings (i.e. non
fatal errors) and fatal errors.
Is this homework? You wouldn't generally see this kind of "specification"
in the wild, because it doesn't make sense. An HTTP request only has one
output stream. If the output has to be XML, then that's going to occupy
the output stream.
If this is for debugging and tracing, one perfectly valid option is to add
the diagnostics and log messages as <!-- comments --> in the XML file. That
would work in either CGI or HTTP.
--
Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.
.
- Follow-Ups:
- Re: CLI and HTTP diagnostics design
- From: Derek Fountain
- Re: CLI and HTTP diagnostics design
- From: C. (http://symcbean.blogspot.com/)
- Re: CLI and HTTP diagnostics design
- References:
- CLI and HTTP diagnostics design
- From: Derek Fountain
- CLI and HTTP diagnostics design
- Prev by Date: Re: convert to UTF-8
- Next by Date: Re: mb_detect_encoding when using other than UTF8 and Latin-1
- Previous by thread: CLI and HTTP diagnostics design
- Next by thread: Re: CLI and HTTP diagnostics design
- Index(es):
Relevant Pages
|