The CastanetTM System

Introducing Castanet

Contents

Castanet
Channels
Tuners
Transmitters

Castanet

Marimba's Castanet is a system for distributing and updating software over intranets and the Internet. Although the Castanet system is capable of distributing and updating most any kind of file, its initial focus is on Java programs called channels. That's primarily because Java has the best-developed security system for downloaded software; it's secondarily because Java is an excellent language for writing multi-platform software.

At first glance, Castanet might seem similar to downloading software with FTP and a Web browser. In fact, Castanet goes far beyond FTP:

Channels

Channels are a cross between Java applets and conventional applications. Like applets, channels are:

Like applications, channels are:

Unlike either applets or applications, channels are:

Because channels can be updated automatically and efficiently, they can be much more dynamic than traditional applications, which are updated once a year or so. Channels are an excellent vehicle for distributing information that changes weekly, daily, hourly, or even more often. Education channels that receive a new lesson every day, news channels that update sports scores every 15 minutes, and story channels whose casts and locales grow with time, are some examples. Developers of more traditional channels--those that are function- as opposed to content-oriented--can distribute code improvements frequently and bug fixes immediately.

You subscribe to channels with the Castanet tuner. Subscribing downloads the channel, installs it on your hard disk, and launches it. Subscribing also initiates the automatic update schedule (hourly or weekly, for example) saved in the channel by its developer; you can also direct the tuner to update a channel whenever you wish. You can launch a subscribed channel from the tuner, from a Web Browser, or, from a platform-specific launch facility such as a shortcut or alias.

Tuners

The Castanet tuner is the receiver component of the Castanet software distribution system. A tuner is a small Java application that does three main things:

Each channel carries an update schedule provided by its developer. When it's time to update a channel, or you direct the tuner to so so, the tuner connects to the channel's transmitter. The tuner and transmitter compare the files constituting the channel. If the transmitter has a newer version of a channel file (or a new file) it sends the file to the tuner. Thus, channel updates are differential: only files that have changed since the channel was last updated are transmitted to the tuner. If a running channel's developer has indicated that the channel can be updated on the fly, the tuner installs the new files immediately; otherwise it waits until the channel stops. Channel updates are performed under the protection of a transaction so that channel files are always consistent with one another, even if power fails in the midst of an update.

Tuners are themselves channels, and automatically update themselves once a week.

Transmitters

Castanet transmitters serve channel files in response to tuner requests, roughly as HTTP servers serve Web pages to Web browsers. In fact, transmitters can be configured as extensions to popular HTTP servers, or they can run as stand-alone processes. Unlike HTTP servers, transmitters send tuners only the files that are out of date on the tuner's machine, and they send all of the files in a single connection. Transmitters are, accordingly, much more efficient than HTTP servers.

Developers use the Castanet publisher application to interact with transmitters. When a developer has completed a channel version, he or she points the publisher to the directory containing the new version's files (some of which may not have changed). The publisher copies the new files to a transmitter directory and notifies the transmitter that a new version is available. Then the transmitter, which keeps running while channels are updated, begins serving the new version to new tuner connections; in-progress connections receive the files from the version that was current when the connection was opened. In sum, transmitters accept updates on the fly, and serve multiple versions of channels concurrently.

Transmitters can be extended on a per-channel basis by plug-in software supplied by channel developers. A transmitter invokes a channel's plug-in when a tuner requests an update for the channel. The plug-in can select files to be returned in the update or it can process data supplied by the tuner. If, for example, the channel data indicates that the user prefers German, the plug-in can point the transmitter at the German edition of the channel files. The channel data supplied to plug-ins is created by channel code which passes the data to the tuner, which passes it to the transmitter, which passes it to the plug-in. In addition to user preferences such as language, channel data might report, for example, how often a user has asked for help and on what subjects, or which advertisements (displayed by the channel) a user has clicked on for details. What a plug-in does with channel data is also developer-defined: The tuner and the transmitter merely transport the data.

 


Copyright © 1997 Marimba, Inc. All rights reserved.