Nirvana JavaScript : Comet Forever IFrame Delivery Mode

An Introduction to Comet Forever IFrames

An IFrame is an inline frame within a web page which contains an inline document. The term 'Forever IFrame' is used to denote an inline frame which is implicitly declared as infinitely long. This property of such frames allow the server to continually populate it with data. As browsers render and execute scripts on a page incrementally, the pushed data can be manipulated by the client as it passes into the frame.

Comet Forever IFrames in Nirvana

The Forever IFrame delivery mode is supported by Nirvana's JavaScript API and can be used in all browsers. In addition to Forever IFrame, WebSocket and LongPolling delivery modes are supported.

A Nirvana JavaScript client can communicate with a server using the Forever IFrame delivery mode by specifying the following configuration when starting a session:

        NirvanaSession.start({
            ...
            protocolSelection : ["streamingcomet"]
        });