[EMAIL PROTECTED] writes:

> 1. before a page is executed, I create a proc
> ::request::hputs and ::request::headers, which call
> ::hputs and ::headers respectively and store arguments as some lists.
 
> 2. after the page is executed, both lists are stored and re-executed
> when the same page is being executed for the second time.

> 3. the cache should be cleaned up so that it does not contain more
> entries than it is allowed to...

> But here are some questions which I wonder about:

> 1. how can I break execution of dtcl page? since this does not work:
> namespace eval a {puts "A"; return; puts "B"}; puts "C"

Hrmm... I hadn't realized that this didn't return execution to the
main script.  I'll have to investigate.

> then I have no idea how to print headers+body and exit This is what
> seems to work, but is a very weird construction:

> namespace eval a {while {1==1} {puts A; break; puts B; break}; puts C}

> any better (and easy to implement) ideas?

You could use a 'catch' statement.  That at least looks cleaner...

> 2. how to create unique names? I can have the .ttml supply it's name
> (using arguments it uses), but I was wondering how this could be
> done automagically :-)

Unique in what sense?

> 3. where to store it? SQL or arrays? [arrays have a disadvantage that
>    their lifetime is smaller, SQL will probably take more time and will
>    be DBMS dependant]

I think arrays would be much faster and a better mechanism to use.
Or, actually, you could just use the filesystem.  IIRC, other systems
do that...

> Or maybe write a dedicated server using tcp, icp or pipes?

Sounds complex and a bit slow.

-- 
David N. Welton
Free Software: http://people.debian.org/~davidw/
   Apache Tcl: http://tcl.apache.org/
     Personal: http://www.efn.org/~davidw/
         Work: http://www.innominate.com/

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

  • cache wojciech
    • David N. Welton

Reply via email to