We are developing a library that will include an easier-to-use complete set of classes for utilizing iControl from within Eclipse, and part of building that library will include a community effort, as I've mentioned in my blog.

But what if you want to use Java with iControl today and don't want to wait for our effort? There are a few simple things you can do to make your life easier. First, remember that the iControl API supports Java just fine. The Eclipse IDE has some problems with the libraries that are truly minimal and can be resolved relatively quickly if you know what to look for.

The first thing you can do to make development in Eclipse easier is to move all libraries required for iControl Development to a top-level directory. Due to the depth of the iControl API directory (folder) structure, Eclipse can have problems with the length of command lines.

We moved all of the supporting (non-F5) libraries into a directory called C:\javalib and included that directory in the classpath when building the iControl library, then when the library was built, we moved it also into C:\javalib. This made command lines short-and-sweet, and also made it easier to add them in Eclipse. NetBeans also benefitted from moving the libraries.


Next, we set the source path (which doesn't suffer from file path lenght issues) to the java source folders that hold the output of wsdl4j, giving us the ability to debug into iControl when we need to figure out exactly where the error started - but this step may not be necessary for you as the Exceptions thrown by iControl are very descriptive.

Finally, the first thing you should do when a call fails with an error other than "Authorization Required" is to navigate to the home page of your BigIP or run one of the sample programs and make certain the BigIP is accessible. I work over a VPN, and when not on the VPN I can reach my BigIP via 192.168.42.XXX. When on the VPN, that number actually maps to another city. THe moral of the story is make certain you've got access.

If you are writing Java code for the BlackBerry, remember that the first call will always fail while the handheld receives the cookie, so put a catch into the first call you make that retries before you start looking for bugs.

That's it for now, more to come later.