This site's content was compiled from 1993 to 2006. Beyond that, Google is your friend.
Ted Lawson
The CECGI Cluster is an Eiffel class library which allows CGI programs to be written entirely in Eiffel.
Facilities offered by the CECGI cluster help programmers solve a significant problem associated with practical CGI program design: the problem of state management.
When hit, a CGI program can accept a one-shot delivery of data from the browser, and can send a package of data back to the browser, usually in the form of dynamically generated HTML code for the browser to display. But no other kind of browser-CGI program interaction is possible. Each hit can be at most a single handshake.
If a CGI program needs to converse with the browser, as will be the case for most practical client-server applications, the conversation must take place across a series of hits. Then of course some or all of the state of the CGI program must be preserved between hits. But a number of factors make arranging this complicated, including, for example, the fact that the same CGI program can be invoked by several browsers concurrently. The CECGI cluster offers an elegant and transparent solution to the state management problem, as explained next.
To solve the problem, the CECGI cluster offers facilities which allow a CGI program to transmit its state to a browser in a way that causes the state to be sent back to the CGI program when the browser next hits it, reinvoking the program in that state.
Suppose we call a CGI program state that is relayed between a CGI program and a browser, a "hit-state". There are three ways that a hit-state can be sent to the browser, stored and retransmitted back to the CGI program. It can be appended to a URL in a hyperlink, appended to a form action, or sent as a hidden field inside a form. The hit-state is returned to the CGI program either when the hyperlink is invoked (i.e. clicked on) or when the form is submitted.
Of course the hit-state of an Eiffel program will be an Eiffel object, and in most cases, it will be a complex object incorporating an arbitrary number of possibly complex supplier objects. The CECGI cluster can relay hit-states which are arbitrarily complex, subject only to certain server-imposed size limits. This is a particularly transparent solution to the state management problem because the CGI programmer can then model the periods between hits simply as times when the CGI program is suspended, waiting for a reply from the browser.