JANOS: A Java-based Active Network Operating System --------------------------------------------------- Part of the Flux Janos Project at the University of Utah: http://www.cs.utah.edu/flux/janos/ Send any comments or questions to: janos-discuss@flux.cs.utah.edu. (You can subscribe to this and other Janos mailing lists from the Janos web page.) This distribution contains: Janos Java NodeOS Bindings This is a presentation of the NodeOS interface in Java. It is in the java/nodeos/ subdirectory. There are two "back-ends" in this implementation, one implemented in pure Java and one which calls on Moab's NodeOS API. It defaults to the "pure java" version. ANTSR A re-write of ANTS to use the Java NodeOS interfaces. And to better separate resource usage among flows.a Located in java/antsr/* A bunch of other goodies. Makefiles, configuration scripts, a regression test suite, some documentation, a tool for mapping, creating and maintaining virtual ANTSR networks on real networks, and tools for analyzing and manipulating class files. And this README. Prerequisites: GNU make On most BSD-based distributions GNU make is installed as 'gmake'. Use that. (The configure script will find it for you.) A Java Compiler Jikes is required. No other javac that we know of can both initialize our blank final fields and compile our code bug-free. (We haven't tried the javac in JDK1.3, though). Jikes is good for you anyway; if you're not using it now, you'll thank us when you start. We use version 1.06. (Though 1.12 would be an improvement.) You can get Jikes from: http://www10.software.ibm.com/developerworks/opensource/jikes/ NOTE: Kaffe's compiler, kjc, has some bugs in it that our code tickles. However, we don't check for this bug at configure-time. There are regression tests that will check it, though. Older versions of Jikes (e.g., v0.47) do not correctly propagate public static final longs into classes that use but do not define them. (E.g., B uses A.longVal). This only affects the debugging infrastructure. There is no configure-time test for this bug. The configure script will run some minimal tests on your java compiler to tell you if its up to speed. Please let us know if you are successful in getting another compiler to compile Janos. A Java Virtual Machine We use a recent (early Millennium) Kaffe snapshot. We have reports that the last "stable" release of Kaffe (1.0.5) does not run the test cases. JDKs 1.1.x or 1.2.x from SUN seem to work fine. You could probably even run on an older 1.0.x JVM, as we use few (if any) of the classes introduced in 1.1. (Though we haven't tested this). You can get the latest CVS version of Kaffe from http://www.kaffe.org/ Building Janos: Here's the short version. Read INSTALL for more details. Janos has a configure-like script that tries to figure out in what ways your system is broken (er... different from ours). Ideally it works like this: cd ./configure ./build If configure cannot find a passable javac, try this: ./configure --javac=/path/to/recentjdk/bin/javac If you have jikes, but it isn't working, it is probably because the classpath isn't being set correctly. Try this: ./configure --classpath=/path/to/jdk/lib/classes.zip You can run configure in another directory if you don't want to contaminate the source tree. All files will be generated in that directory. Still stuck? Read the detailed instructions in INSTALL. Or, send a message to janos-discuss@flux.cs.utah.edu. Testing Janos: - Hello, World! The simplest test is the Janos HelloWorld. You can run it like this: cd tools/bin/janosvm edu.utah.janos.nodeos.Main edu.utah.janos.tests.HelloWorld You should see some output like: Janos Java NodeOS v1.1.0 Hello, world! Root flow term handler. Shutting down. Shutting down. If that doesn't work try: sh -x tools/bin/janosvm edu.utah.janos.nodeos.Main edu.utah.janos.tests.HelloWorld to see what might be going wrong. - Regression Tests The regression tests will provide a quick check that the system is really working for you. To that end a 'check' script is generated that runs the basic regression tests. cd ./check Using Janos: You should source the script tools/startup/env-cshrc. This will add the tools/bin/ directory to your PATH. (Assuming you use a csh-like shell. Bash/sh users are left in the cold, currently.) The 'janosvm' script in the tools/bin/ directory will add the required Janos classes to the CLASSPATH. It will invoke 'java' as the underlying JVM. Let us know what you think! janos-discuss@flux.cs.utah.edu