Tagged: install

FuseDay – Installation

JBoss FUSE cloud
I’ve decided to do a bit of a “deep dive” in to the Fuse ESB, which is now owned by Red Hat, to upgrade my technical skills in this area. I’ve actually ended up using a product called Fuse Service Workbench instead of this and will eventually do a post similar to this on how to install it. The directions given here will work though if you want to set up “Basic Fuse” along with the Developer Studio.

One thing I have discovered (by getting FSW up and running) is that due to various bugs in Oracle’s JDK 1.7 on Apple – you should use it, at least for this. Instead, you need to use Apple’s JDK 1.6, making sure that you set JAVA_HOME to the real path, not a symbolically linked one (of which there are many). I’m assuming 1.7 is OK on Windows (as the doc says it should be) – feel free to let me know your experiences in the comments section.


For simplicity, I’m using the RedHad FUSE ESB which includes: Installers, Testing, Performance, Third party verification, Centralized management of uniquely configured brokers with Fuse Fabric and Incremental patching. It’s a 30 day trial, but I’m just using it for the quick and easy installation.

1. Install JBoss FUSE Beta (6.1)

Get it from http://www.jboss.org/products/fuse, unzip the file, uncomment the (last) admin user line from etc/users.properties:


and start the ESB, so you should get something like this:

JBoss-FUSE rwest$ bin/fuse	 	 
Please wait while Fabric8 is loading...	 	 
100% [=============================================================]	 	 
      _ ____                  ______	 	 
     | |  _ \                |  ____|             	 	 
     | | |_) | ___  ___ ___  | |__ _   _ ___  ___	 	 
 _   | |  _ < / _ \/ __/ __| |  __| | | / __|/ _ \	 	 
| |__| | |_) | (_) \__ \__ \ | |  | |_| \__ \  __/	 	 
 \____/|____/ \___/|___/___/ |_|   \__,_|___/\___|	 	 
  JBoss Fuse (6.1.0.redhat-328)	 	
Hit '<tab>' for a list of available commands	 	 
and '[cmd] --help' for help on a specific command.	 	 
Open a browser to http://localhost:8181 to access the management console	 	 
Hit '<ctrl-d>' or 'osgi:shutdown' to shutdown JBoss Fuse.

As mentioned above, you can then go to http://localhost:8181 and login

JBoss FUSE login

which should give you the welcome screen!

JBoss FUSE welcome

Congratulations – you’ve almost got FUSE running as what you have at the moment is a Fabric, which is kind of like a ‘mini cloud’

Now you should shut FUSE down using

JBossFuse:karaf@root> osgi:shutdown
Confirm: shutdown instance root (yes/no): yes
JBossFuse:karaf@root> JBoss-FUSE rwest$

so you can …

2. Install JBoss Developer Studio 7.1

Get it from https://www.jboss.org/products/devstudio.html and just open it – as it’s a jar file, on a Mac (which I use) it will just run the installer:

JBoss DevStud first

If you’re on a Mac, then the JVM/JDK will probably be set to your browser’s JVM, which is not correct – it should be set to your JDK. In the case of Apple, it should be 1.6:

>> TODO: Update Diagram Below


Contrary to the screen above, you can use the “Visual Page Editor” on a Mac if you do a 32-bit installation. At the end you can then start the IDE and at a minimum you should install all of the “Integration Stack” items as some of these work with FUSE:

JBoss DevStud updates

and there’s some pretty cool stuff such as support for Rules systems like Drools and Guvnor. You’ll probably get a warning about “unsigned content”, but that’s just someone (in Red Hat) being lazy.

After the installation, JBoss DevStudio will want to reboot and then you’ll be right for development with FUSE which we’ll cover in the next installment…

NOTE: Still a bit more updating to do, but most of the above should be correct.

The Almost Unbearable Lightness of LightTable

Note: This post is in Draft, I’ll be updating it a bit more…

LightTableSeesawAs I’ve been tweeting, I’m very interested in LightTable, the amazingly cool IDE being developed by Chris Granger @ibdknox and his gang. It’s a bit like the black spaceship from Hitch-Hikers Guide To The Galaxy though: “It’s the weird colour scheme that freaks me. Every time you try to operate one of these weird black controls, which are labeled in black on a black background, a small black light lights up black to let you know you’ve done it”. The next major release (in a month or so) will be addressing “user experience”, but in the mean time, what if you want to give it a serious try?

That is what the rest of this post is going to try and help you do also – get LightTable up and running so you can incorporate other projects and frameworks, which is really needed if you’re to proceed beyond trivial playing with it. But first, a warning from our sponsors (that’s me :). The version on LightTable says it all – 0.2.7. If you want a seamless install / development experience, especially if you have other installations of Clojure, IDE’s, lein, … then it’s probably best to come back later… They’re working quickly to address things, but this is a Real Agile Project that released very early and is now releasing often, so major kudos to them for doing so!

Finally, for some context, I’d rate myself as an “Enthusiastic Clojure Amateur” – I don’t do it for a day job, but I know my way around Unix, Maven, (now) Lein and Clojure through other environments. If you’re at this level or above then this post could be for you, and hopefully save you some time and frustration. You should also note that I use a Mac (is there any other platform to use for serious development? ;) so these instructions assume that. I won’t be doing a Windows post of this, but if anyone wants to then feel free to copy and change what I’ve written.

There are 3 key activities for setting up the latest version (0.2.7 or above) of Clojure:

  1. Clean Installation of Lein2
  2. Clean Installation of LightTable
  3. Creating a LightTable Project with Dependencies using Lein2

Note: I’m assuming you’ve got Maven 2 running, because you’re some sort of Java dev – I may add instructions for this later…

I’m sure all of these issues will be addressed in subsequent releases, but for the meantime, here’s how I did it – Note: it’s assumed that you’ve installed to your local user. If this is global (Unix) or Windows you’ll have to use different paths.

1. Clean Installation of Lein2

LeiningenThis was probably the most difficult and time-consuming thing to work out as I was running a version of Lein 1 that I’d installed ages ago, which is an absolute no-no. LightTable won’t work with this configuration and give you all sorts of weird errors. Whatever version of Lein you’re running it’s probably best to clean out your Maven directory:

rm -r ~/.m2/*

If you’re running an “old version” 1.x of Lein you’ll have to upgrade, which means that you should clean out your .lein directory:

rm -r ~/.lein

Then you’ll have to do a “Bootstrap Install” of Lein2 which isn’t that hard. Firstly, remove you’re old shellscript which in my case was in my ~/bin directory that is on my Unix path:

rm ~/bin/lein

Github LeiningenThen you’ll need to get the latest and greatest version of Lein 2.0.0 – this matters, as the default when you grab it from GitHub is the 2.1-SNAPSHOT (at this time of writing) version which is on the “master” branch, but unfortunately this won’t currently work with LightTable and give you weird connection errors. I originally got this, then changed it to Stable (2.0). In my environment, everything is in ~/Gits.

The final step for this is to then install Lein2:

cd ~/Gits/leiningen
lein install
lein version
>> Leiningen 2.0.0 on Java 1.6.0_37 Java HotSpot(TM) 64-Bit Server VM

2. Clean Installation of LightTableLightTableIcon

Once you have the right version of Lein2 going, it’s actually pretty easy to get LightTable going either if you haven’t installed it or are running an earlier version. To reset your configuration, just remove your .lighttable directory and contents:

rm -r ~/.lighttable

If you don’t have a recent version of LightTable, i.e. your icon doesn’t look like the above one, then you’ll need the latest installation of LightTable, which is pretty easy – just go to http://www.lighttable.com and download the correct launcher

Once you’ve reset your configuration, just run LightTable, it should then get the latest version and tell you to restart. When you’ve done this you can check the version from the “command line” at the bottom by typing “version” which should show 0.2.7 or whatever the latest (higher) version is. If it’s less then somethings gone wrong – Maybe you didn’t delete the entire directory? Maybe you have an old version of the launcher? You’ll have to do some digging if this is the case…

3. Creating a LightTable Project with Dependencies using Lein2

Now you have the right infrastructure set up, it gets very easy. To create a new project, you just create a default template:

cd ~/Projects/LightTable/
lein new guitesting

start up LightTable and connect to your project


during which you’ll see connecting and retrieving messages


and hopefully a brief connected message


If you get any blue error windows popping up on the left, then something has gone wrong, probably with your installation of Lein2 so you should go through and check the above process again.

Ah, but there is “one more thing”, which was the key capability I was looking for originally with LightTable, and that’s the ability to include extra projects / dependencies. Now that you’re up and running, this should be comparatively easy. You just add whatever you want to your project.clj, probably using LightTable now you have it running

(defproject guitesting "0.1.0-SNAPSHOT"
  :description "FIXME: write description"
  :url "http://example.com/FIXME"
  :license {:name "Eclipse Public License"
            :url "http://www.eclipse.org/legal/epl-v10.html"}
  :dependencies [[org.clojure/clojure "1.4.0"]
                 [seesaw "1.4.0"]])

which in my case was seesaw that is a development framework for Swing GUI’s that I talked about in my previous post on Easy UI development in Clojure with Seesaw. If you have an instance of LightTable running then you should quit and re-start it to pick up the new dependencies when you connect and that’s it! You should now be able to use LightTable like you see on all the latest articles and videos

Finally, I will be doing an “Unbearable Lightness of LightTable” when LightTable progresses more in installation to the stage where the above instructions will not be necessary. In the mean time, I hope the above has helped you if like me, you’ve been looking at all the latest LightTable videos and wondering why you can’t do these things.

PS If I you have a different experience then please let me know via the comments and I’ll correct or add to the post