Ok, elaboration time.

This is also going to invovle session persistience type ideas. Basically whats going to happen, is client A first hits the script. The script generates an object/data/etc for him, by a series of sql queries, some processing, some files, etc etc. He has his data. That data is then stored in the session attached to him via a cookie. Then the script generates an output screen for him, made up of some data from his "object", from other peoples objects, some environment data, etc etc. This screen would be sent back to him. However, the client would be constantly (2-3 a minute) refreshing the script. Since the output data is dependent on "outside" factors (i.e. not just data contained by the clients session object dealy), the output data that is sent back might be changed a little bit, (a few numbers), or might not be changed at all. As i mentioned above though, the little changes are critical, so whatever system i use must be able to keep sending back the new data. The problem (that i see from here, i havent tested/benched this at all) is that every time the client refreshes, it would have to generate the "output data" all over again, not to mention reinitialize the session data and so forth. Also note that this solution must be entirely "browser based", i.e. using nothing other then what a default browser has (and the server of course), which means basically html/javascript (yes, it will be required. deal.) is allowed, as well as whatever serverside perl / db magic you can conjure up.

Update:
I guess what this mostly boils down to, is there any way i can avoid having to constantly reinitialize 'session/objects' per user? It seems to me that every time the client hits the script, it would have to go through a (relatively) huge amount of work, reloading all the files, constructing the objects from mysql queries etc.

In reply to Re: Improving efficiency - repeated script hits at small interval by BUU
in thread Improving efficiency - repeated script hits at small interval by BUU

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.