Building mobile agents
Buidling mobile agents
Dateline: 01/19/99
Mobile agents were one of the hottest topics in Internet development just a few months ago. Just remember the hype surrounding General Magic and its Magic Cap operating system and Telescript agent scripting language. Everybody used to talk about personalized agents that roam the Internet acting as personal assistants, shoppers, stockbrokers and attorneys. All boring, repetitive and time-consuming tasks would be accomplished without our direct presence, just by sending an agent to do it for us.
Science fiction? Unfortunately, for the present time, yes. Some of the first operating systems/environments used to implement mobile agents were proprietary, and failed to fulfill programmer's expectations. But the vision of the Internet as a distributed, massively parallel supercomputer that connects information respositories, databases, search engines and mobile code was too tempting to let it go. Then came Java, complete, object-oriented, network-centric, platform-independent and safe language - shortly, it was a dream come true for the developers of mobile agent applications. For more complete review of network computing paradigms, see the previous feature article at this site.
As a result, there are several mobile agent systems that support Java programming language. You will still find other languages in use (Tcl, Scheme, Python): see the list at the end of this article for more information.
At the present moment, several organizations promote standards for mobile agent systems (Object Management Group and the Foundation for Intelligent and Physical Agents together represent more than 1000 corporate members). Five of the key players at this field have jointly development a proposal for a Mobile Agent System Interoperability Facility that will further enhance the interfaces between agent systems.
Several years ago, IBM decided to produce what is now one of the most popular agent development kits. A research team at the IBM Tokyo Research Lab, led by Danny Lange and Mitsuru Oshima, produced Java Aglets SDK that streched "write once, run anywhere" philosophy to "write once, go anywhere". More technical details on this can be found in earlier articles. Java Aglets SDK always contained enough documentation and samples, including online Aglet Cookbook that is now replaced by the new book, "Programming and Deploying Java Mobile Agents with Aglets", written by authors of the original SDK and published by Addison-Wesley. It is practical in focus and geared for experienced Java programmers (no previous agent experience required). Introductory chapters on Java or network programming wouldn't fit on some 225 pages, anyway. Concepts of this technology are presented in a clear and concise manner. An average programmer wanting to learn about mobile agents (and learn it fast) will appreciate many advanced topics and programming tips. However, I would like to see a CD enclosed, instead to having to download everything from the Aglets main site.
First chapters of the book provide a general introduction to mobile agents, including elements of mobile agent systems and linkage of such systems with Java. Aglet "anatomy" and one of the key elements of the Aglet API, Aglet-Context interface, are described in the following sections. Readers experienced in Aglets development will probably skip directly to the description of Aglet Messaging and Collaboration systems that are followed by demonstration of different advanced programming techniques. I have really learned a lot from sections on multicast messaging, directory listing aglets and agents in parallel execution, to name just a few. Aglet security is also covered, along with the very interesting chapter on agent design patterns, which is highly useful technique in object-oriented programming for achieving good design through reusability of validated components (instead of "reinventing the wheel").
Potential readers should be aware that this is highly specialized and still somewhat exotic field that requires previous knowledge of Java programming. If you plan to design and/or implement applications for electronic commerce, personal assistance, distributed information retrieval, parallel processing, monitoring/notification or related fields you should probably give it a try.
Still unsure if this is a book and development system for you? Go to the nearest bookstore, look for the "Seven good reasons for Using Mobile Agents" on third page, and you'll know. If you find yourself attracted to the mobile agent philosophy, chances are that you will use Aglet API really soon.
Now that your agent has "legs", you may want to make it smarter. Mobility alone is an exciting concept, but needs more to achieve a real breakthrough (and to find itself described in the AI column). One of the best books on the subject (Agents + Java + Artificial Intelligence) is "Intelligent Java Applications for the Internet and Intranets" by Mark Watson that gives clear explanations and source code for the theory behind the AI techniques described inside. If you are interested, here is a more detailed description. Another recommendation goes to the "Constructing Intelligent Agents With Java : A Programmer's Guide to Smarter Applications" by Joseph and Jennifer Bigus (OK, I have written a review of this book also). It is very well written and easy to read; unfortunately, you may experience troubles when running some of the software from the CD. However, code is easy to understand, and you will probably have no problems with understanding the concepts.
Similar site(s) of interest:
- Aglets
Everything you want to know about Java Aglet API.
- TabiCan
E-commerce service created using an aglet-based framework (Japanese only).
- Odyssey
100% pure Java reimplementation of the older Telescript concepts from one of the inventors of the mobile agent technology.
- Concordia
Full-featured Java framework for development and management of network-efficient mobile agent applications from Mitshubishi.
- Voyager
Combination of Java based object request broker and mobile agent system, written in Java.
- D'Agents
Mobile agent system from Darthmouth College whose agents can be written in Tcl. The Java, Python and Scheme modules will be released publically over the course of the next few months.
- Ara
Platform for the portable and secure execution of mobile agents in heterogeneous networks, using Tcl and C/C++ interpreters.
- TACOMA
This project focuses on operating system support for agents and how agents can be used to solve problems traditionally addressed by other distributed computing paradigms.
- IMT
Very interesting project, led by Benjamin Falchuk and Ahmed Karmouch that uses visual tools to allow non-programmers to customize agent behavior and accomplish flexible tasks.