Install a plugin in OpenBD
Posted by Euroranger on March 25, 2011
Second blog entry in a row for something other than me ranting and raving. Actually, I COULD be ranting and raving today as the Jeep I own that I had repaired just yesterday made it…check this out…A GRAND TOTAL OF THREE F**KING MILES BEFORE THE SAME THING BROKE AGAIN. Yep. Got it back, drove it exactly 3.3 miles before it broke stranding me at the place I went for lunch today. Naturally, the garage that “fixed” it (and I’m using the common English definition for the word “fix”…which may or may not be the same definition the garage uses) has it again but they’ve called to tell me that no, they won’t be able to “fix” it again until tomorrow morning. Saturday. Nearly 20 miles from where I live. So while we have, yet again, another fine example of just how much God does indeed hate me (as though there was any atom of a doubt by now) I have made the decision to veer away from the expected recitation of some malevolent deity’s childish torturing of my apparently annoying continued existence to share yet a second technical blog entry. Note to God: It’s called “taking the high road”…you should leave me alone and try it sometime. Anyway, on to the fun.
I’ve mentioned before that my site is run by CFML (Coldfusion Markup Language). Specifically, it’s run atop an instance of something called Open Bluedragon or OpenBD as it’s more commonly known. OpenBD is a CFML engine (similar to Adobe’s CF9) that is built and maintained by a very talented group of folks as an open source project. Anyhow, in my continuing efforts to upgrade and resurrect my site, I discovered that some old code that I’d built that allowed my customers and users to utilize Twitter was now broken. It seems that sometime in the interim, Twitter changed their API (application programming interface) and so now my previously working code was now obsolete. In an effort to try and get my code back up and running I ran across mention of a plugin for OpenBD that would make available CFML functions that would do much of the Twitter work for me. In programming parlance this is something known as “very good” and can cause developers to break into spontaneous happy dance mode. Using a standard plugin or custom tag or function helps to standardize the language (in my opinion) so I was all on board with trying out this nifty plugin. Unfortunately, the installation directions accompanying the plugin didn’t work. I followed them to the letter but when I tried testing them, no joy. Nothing happened. The site responded as though the plugin wasn’t even there. In programming parlance this is known as “frustrating as hell” and is quite a regular occurrence (for me anyway). However, due to my previously mentioned metaphysically caused misery (God hating me), I am well accustomed to frustration, depression, rage, suicidal ideation and other normal signs of a typical day of being a developer…so I took this all in stride. More accurately, I dropped an email to the fellow who built the plugin asking “what gives”. He (Matt Woodward) was as helpful as he could be to someone he didn’t know and whose server setup he had no real clue about. However, after several attempts to troubleshoot my problem via email, he forwarded me to another fellow who is part of the team that helps to craft what eventually becomes OpenBD in it’s final perfect and serene form, Alan Williamson. Alan pretty much immediately discerned what was up and very helpfully provided the instructions necessary to get OpenBD to recognize an load a plugin file. I am pleased to report that my test of the plugin loading succeeded on the first attempt and, because no detailed instructions appear to exist on the web for such, I am pleased to share a step-by-step narrative for how to install a plugin on OpenBD.
Before we begin, the version of OpenBD I am running is 1,4. It is running atop Apache Tomcat/6.0.26 with an operating system that is described as: Linux i386 (2.6.18-164.9.1.el5xen). OpenBD plugins are .jar files that follow a particular naming convention: openbd-XXXX-plugin.jar. Normally all you’d need to do is to simply identify your project’s WEB-INF/lib directory, drop the .jar file(s) into that directory, reboot your server and VOILA! you have functioning plugins. It should come as no surprise to anyone that I would not enjoy such a simple experience. However, due to the help of those people as well as the tech support folks at Viviotech (who host my site) I am pleased to present the following instructions for how to install a plugin on OpenBD:
- Drop the pertinent openbd-XXXX-plugin.jar file into your project’s WEB-INF/lib folder. In my case, it was the /opt/openbd/lib/ folder.
- Edit the bluedragon.xml document (for me, found in the /opt/openbd/conf/ folder) and add the following entry under <server><system> (same level as <buffersize> and <licensekey>): <pluginjarpath>file:///opt/openbd/lib/openbdplugin-XXXX.jar</pluginjarpath>
- To add more plugin files, simply comma-separate them within the single <pluginjarpath> tag
- Reboot your server
- Login to OpenBD admin and click on Log Files under Debugging and Logging
- View the log file for bluedragon.log
- You should see an entry in the log (2 lines) that looks something like this: 25/03/11 12:08.40: -] PluginManager Manual Loading …
25/03/11 12:08.40: -] PlugIn.Load.Installed: org.alanwilliamson.openbd.plugin.spreadsheet.SpreadSheetPlugin; SpreadSheet; Version=1.95 (I tested with the OpenBD spreadsheet plugin, ergo the details in the plugin installation. Different plugins will read differently)
- Congratulations! Your new plugin should be ready for testing/use.
It should be noted that while I was forced to use this method to get OpenBD to recognize a plugin, it should work for anyone whether they need to use the method or would simply prefer to. Understandably so, it’s easier to simply drop the .jar files into the appropriate place and restart your server. In fact, that’s one of the nice features of working with a Java based CFML engine like OpenBD. However, in my case (supposedly because I was using Tomcat), that method didn’t work…but this one did.
So, a quick post today to extol the virtues of OpenBD. As a side note, please note that what I was attempting to do was to modify the actual install of OpenBD so that I would acquire access to functions specific to Twitter. Not a UDF or component or custom tag…but actually integrated into the language. As far as I know, this isn’t something you can do with CF9 and is one of the things I like best about OpenBD. It’s much more dynamic than CF9 and when I had an issue with it, I was able to speak to one of the architects who got me a workaround IN THE SAME DAY. While I work everyday with and like CF9, there’s no way on Earth Adobe is nearly this responsive to user issues. One of the nice legacies of NewAtlanta’s BlueDragon platform…from which sprang OpenBD. Superior, contactable, responsive support…just because they like doing what they do. Something proprietary vendors should pay a lot more attention to.
(Please note that I’ve included a few pertinent links in this post to sites and blogs and such that pertain to this subject. These are all smart, dedicated folks who have much wisdom to impart.)
My name is Euroranger and I approved this message.