We’ve just released the PhidgetServo code and NetBeans project to the public under the Creative Commons Public Domain License. For more information: http://dozersoftware.com:3000/wiki/phidgetservo-jruby

This work is dedicated to the Public Domain

We, being my oldest son Layne and me – though he doesn’t really know it yet. I’ve sparked some interest for coding via basic robotics. We’ve also been playing with interaction via Jabber. This particular project is the basis for an incoming message notifier (waving servo). We’ll probably be posted another which provides a control interface via a Python-based Jabber bot.

Pretty cool. We should have more stuff soon. Part of the fun was skinning Redmine as our project hosting site.

(Also getting a big head start on this year’s science fair project.)

Warbler is an enabler. True, Warbler is a Rails-specific tool, and not really Ruby. But, if Rails/JRuby isn’t, at a minimum, a blip on you enterprise developer’s radar you’re missing something important.

Anyone who has ever spent a significant amount of development time with Java knows the dev cycle (code, build, test, deploy, test, code) is painful…especially with tools like Maven driving the bus. For this reason alone I believe Ruby has an inroad to Enterprise development. Keep in mind that SOA and web-based services are the general target. Ruby (Rails) combined with a TDD/BDD attitude can promote a more pleasant cycle (test, code, test, code).

Here’s a short list of the relevant stumbling blocks. And no, XML processing isn’t on the list (it is rather good, with multiple options – try Googling for more info)

  • This is the SOAP support in Ruby. Where the hell is the documentation. What’s the point of having rdoc if you aren’t going to document the usage. Lame.
  • Enterprise integration with Ruby is a book put out in 2006, covering generic integration topics. That’s it, that’s all there is as far as the formal discussion goes. A book.

Ok, see I said it was short.

With JRuby rolling, there’s no reason not to enjoy the “fun” that comes with Ruby development. Shoot, there’s even Swing-focused tools like “Monkeybars”http://monkeybars.rubyforge.org/ that help make Java GUI development fun (ok, maybe just interesting – fun could be a stretch).

However unfortunate, I do think it will take JRuby to get some mainstream corporate use. But, whatever it take right? There’s no excuse now, not to start looking at, talking about, and enjoying Ruby development.

I’m posting this blog article. Which will then show up in my Google Reader because it is going to automatically get piped their from somebodies Yahoo! Pipe. Once it shows up in Reader, I’m going to share it…which will cause it to show up in my Google Reader Share ( http://www.google.com/reader/shared/03419463208734067981 )...causing it to cycle around again. I’m kind of curious what other ill-effects happen (browser melt-down, pink-slip action, etc.)

Here’s the tinyurl (for my shares): http://tinyurl.com/6s5kop

Sorry, just me bein’ a dork.

Introduction

It is widely known that the Open Source community uses a different approach (Bazaar) to software engineering – over traditional, proprietary environments (Cathedral)[1]. However, there are many opportunities to apply Open Source practices to internal software engineering efforts, where the software product is consumed by another internal organization. Integrating these practices is not trivial…though in most cases it is just a matter of utilizing a few new, or different tools. In some cases, there may need to be a cultural shift, or simply a new awareness.

In order to avoid any confusion in the distinction between true Open Source development, where there is a “public” interface and intra-organizational development I’d like to call the generic practices found in the Open Source world Community-Based Development (CBD).

CBD serves the environment where one team is developing software that has consumption potential. Notice I didn’t say reuse, which is a chokepoint for many engineers. Consumption, in this case, means library, API, or interface implementation – not source code copy n’ paste. The “customer” is another developer, or engineering project. CBD is about optimizing this kind of relationship, especially where the customer is proactive in the development of the source product.

Background

There are a few key functions, or tools used in this provider-customer relationship – many of which are clearly defined in Producing Open Source Software [2].

Here’s the quick (not all inclusive) breakdown:
  • Mailing lists - Dev, Announcements, Users, Builds, etc.
  • RSS feeds - Tie into mailing lists, issue tracking
  • Issue Tracking
  • SCM
  • Wiki
  • Search (projects and code)
  • Admin Management (Users, Roles, Project setup, etc.)
  • Web Site
On the Open Source side of the fence these tools are usually consolidated, and provided from a single user-interface (website). In many cases, projects are homed into a parent structure, provided by a “hosting” service. There are a few examples such as SourceForge.net[3], or Java.net[4] which front-end many projects. The software platforms that provide these infrastructures are available for commercial application in both proprietary and Open Source form. In addition, there project infrastructure suites such as Redmine.org[5] that are designed specifically for internal/team-centric software engineering collaboration.

Integration

There are a few “tough” questions that arise when considering CBD, especially as applied to internal relationships. The first, and probably most obvious, is how to integrate CBD with existing processes and methodologies. Existing processes can usually accommodate CBD with little pain. CBD is a complimentary environment, and can integrate seamlessly in to any methodology (waterfall, spiral, agile). Where things get really complicated is in the tooling. Most development environments are already using individual tools to perform specific functions (e.g. issue tracking, project management). How CBD is applied where existing tools are entrenched – should not be a replacement effort. Although, there may be some duplication – the idea is to expose the integrated collaboration tool suite to both the product developer(s) and the customer, or product consumer/integrator. Continuous integration environments shouldn’t be affected – as the source code repository is independent from the project suite.

Discovery

Keep in mind that the developer-developer relationship requires that the consumer have the ability to search/discovery the internal software product. Just having code in a repository with an associated issue tracking system doesn’t lend itself as available for consummation. This is why the SourceForge (centralized collection of projects) is prevalent in the Open Source community. Having a centralized source of CBD projects leads to the potential for consummation because they can be discovered.

Governance

In order to maintain a “community” project there is a requisite membership ideal. Usually, the project owner plays the leadership role, whereas the consumer plays member (active or passive). CBD requires members be given roles to control access to data, ability to commit changes, as well as general project management activities. Again, having the consolidated project environment ensures that user administration is consistent across all projects, as well as providing a potential for parent-sub project relationships. The consolidated suite of tools also ensures that the project owner can control the roles and privileges without implicating administrative personnel.

Community

The idea of a community-based approach to software engineering is based on the principle that the consumer is integral in the development, much in the same way as Agile Methodologies manage the customer relationship. The consumer’s activity may be as simple as reviewing/editing documentation or providing input via issues and bug reports. Or, it can be as proactive as the consumer writing code and submitting it to the project. Regardless, the objective is to maintain the codebase for the continued and growing consumption without duplicating anything across the organization. Internal to an organization, there may be boundaries specified by contract, external customers, or functional hierarchies that make it difficult for software to be reused. The notion of CBD can help overcome this by removing the demarcations and continuously improving the “wheel” without starting over.

References

At least 80% of the times when I attempt to update Twitter I get the “overloaded” bullshit. Amazing, in today’s “everything-scales” technotopia cloud we can’t get me guaranteed access to a free service. Geez.

I’ve been on and off the Twitterino bandwagon a few times already, and am about to drop off forever. The only thread hanging is that a few peers use twitter as their pseudo-blog. I really wish they wouldn’t – but, unfortunately they are (even with no social network intent).

I recently found Hellotxt via another fairly new playa BrightKite. I’m sure I’m at least a couple of months behind…because Hellotxt already has all the majors lined up and a load of the “what the hell is thats”. About the only one of these cats that is remotely interesting is Facebook. I realize I should prolly care a bit more about LinkedIn – but, I have a job (at least I think I do).

So, if Twitter wins the “dumber” award for not being able to scale (and I don’t want to hear the dumbass Rails argument either), then Hellotxt picks up the dumb one. I actually think Hellotxt is interesting simply because it is stupid that I can’t just blog my own updates…from my site, and load the feed to all these sites. At least Hellotxt is a step towards unification of the belt.

Anyway…kind of a mindless Friday lunch – looking at some of these new fangled things that are supposed to improve my social life.

Phidgets and Ruby...

June 9th, 2008

Well, I’ve been looking for a reason to play with JRuby for some time now. It finally came time, in the shape of a Phidgets servo. Ok, so maybe it isn’t “Phidgets and Ruby” exactly. I can’t say what I’m using the Phidgets for but being able to access them from Ruby is a huge bonus (if for no other reason than I prefer looking at Ruby). Problem is…no Ruby API to access them directly. Python yes, Ruby no. Although I really have nothing against Python this particular project already implicates Java. So, what’s one more library like JRuby?

I will admit that I had quite a few problems getting through outdated documentation for JRuby. Just getting setup with the initial ‘include Java’ instead of ‘require java’ was almost torture. Ruby community’s documentation is already suspect – therefore JRuby must just want to follow suit [Ruby itself, is fairly well documented – thanks to James and the Happy Camper guys]. Then I had to figure out how to work the Java interfaces for the servo’s “attach” listener. The documentation for how to do this is a bit of a struggle too. Just need to remember that JRuby is early 1.x version.

I was actually able to get Phidget servo to respond and set it to a given position. Cool. And, I will admit the code is much cleaner, simpler and a lot less of it.


include Java

require 'phidget21.jar'

include_class Java::com.phidgets.ServoPhidget
include_class Java::com.phidgets.event.AttachListener
include_class Java::com.phidgets.event.AttachEvent
include_class Java::com.phidgets.PhidgetException

class ServoAttachListener

  servo = ServoPhidget.new()

  def attached(ae)
    begin
      puts "Getting Device Name..." 
      servo = ae.getSource()
      puts "Device Name: " + servo.getDeviceName()

      puts "Getting Servo Count..." 
      puts "Servo Count: " + servo.getMotorCount().to_s

      puts "Getting Servo Max Position..." 
      puts "Position: " + servo.getPositionMax(0).to_s

      puts "Getting Servo Min Position..." 
      puts "Position: " + servo.getPositionMin(0).to_s

      puts "Setting Servo to Max Position..." 
      servo.setPosition(0, 232.0)

    rescue PhidgetException => e
      puts "Java or Ruby exception: #{e}" 
      raise
    end
  end

end

puts "Hello Phidget Servo" 

servo = ServoPhidget.new()
attach_listener = ServoAttachListener.new()

servo.addAttachListener(attach_listener)
servo.openAny()

while true

end
puts "Goodbye Phidget Servo" 

So, I’ve been “offline” for a bit. Had a short break in the academic dimension, money issues in the corporate dimension, and general techno-depression (where I just don’t give a shnizzle about any of it) – all of which removed any desire to be at the ole puter.

Not much has changed accept I’m back at it – for my last graduate class evar.

There’s been some interesting things happening in my techie-world. I just can’t seem to get any motivation going to care. Lot’s of good discussions around Groovy, JRuby and virtual machines in general. Functional Programming seems to be the snowball that is sucking people up for no good reason. Open source hardware, smaller and smaller processors, and almost the dead quiet before the tornado in the networking world. Apple still is going nuts though I am already tired of the continued iPhone hype. Maybe I’m just jealous because I am stuck with a 1st-gen’er. I really wish there would be some big news from today’s MacWorld Keynote about OS X or their other platforms (non-iPhone). Still waiting for that.

I still subscribe to Linux Journal magazine – but, am not really sure why. The content is lame…and is second rate to most of the blogs I read anyway. There’s nothing new in that space…especially from the OS perspective. Reading it this morning kind of took me back to somewhere around ‘93 when I first saw Linux running on a friends Packard Bell PC. It was kind of funny … I was supposed to be getting a demo of this awesome Windows alternative called OS/2 (which is now completely dead). I got so hooked on the story of Linux that I could’ve cared less about OS/2. I’d seen some UNIX before this – and pretty much favored DOS over Win3.X at the time. Slackware (the Linux distro) was cool, not because of the software itself, but rather the culture. I’m not sure what happened, but it really feels like that culture is gone, replaced by ego-driven twerps with zero appreciation. Kind of like yoga’s americanized incarnation (downward facing dog instead of Adho Mukha Svanasana). I kind of get the same old-skool Linux feel from the Ruby (not Rails) community, which is cool. The difference for me between then and now, is that I really could care less if anyone jumps on the Ruby bandwagon. Back then, I was a religious zealot about Linux – preaching to anyone who’d listen (and even those who didn’t want to hear it). Maybe it is just a funk…but, I’m kind of just tired. In the early 2000 I was beating the IPv6 drum only to have my head constantly bashed against a wall by corporate idiots. At some point I think I’ve just subconsciously realized that it will all unfold however it damn well pleases and there’s no point in me caring one way or the other (I’m really just along for the ride). I suppose the sooner I consciously accept this the better off I will be.

Then, there is the whole “human” angle…like I should be trying to save the race or something. Like where ever I put my energy should be for the greater good (or something). All this green crap, the election politics, fuel prices, my rapidly thinning scalp coverage, blah, blah, blah. It really is rather depressing. Oh wait, I’m not supposed to care about the number of hairs listing from the top o’ my head…green, green is good. Damn, green is bad. Green means we’ve already screwed up and attempting to care. Then I read O’Reilly’s latest blog post and return to proud American mode. Sorry…can’t…help…myself…ahhhhhhhh…the…madness. It’s The Happening.

I watched Discovery’s deal on NASA (leaving Earth…) last night. Really frickin’ cool. We pretty much suck as a country these days. I wish we could have a Kennedy lead us to the Moon right about now. Just looking forward would be nice. These tiddly little mission to Mars with a robot just aren’t doing it either. Don’t get me wrong on understand the relevance of the Phoenix missions – but without human life on the line it isn’t the same. Those guys working Mercury, Gemini and Apollo (my Dad included) were the bomb. No computers to solve the problems…just smart people working it out. That’s effin’ amazing. Anyway…that was then, this is now. Tomorrow we’ll still be worrying about $5/gallon gas.

So. What was I saying? Techno-depression…that overwhelming feeling that it is simply impossible to feel like you are doing anything relevant, let alone worthy. I can’t seem to latch on to any one thing long enough to feel like I’ve made my mark. The ‘master of nothing’ syndrome in full effect. I’m basically in information overload…damn you Google Reader! Add in a mix of ‘mobile me’ and it is all over. I just spent a week at the ocean (in and out of the water). It was all I could do to not open Google Reader from my iPhone. Fear of the 600 new feeds I’d have to wade through was killing me. I’m an addict for sure. Is there an Informatics Anonymous?

Actually, I’m doing pretty good now. High of 104 degrees today. Back at work, the routine is definitely soothing. Performance evaluation this morning. Kids are doing well, one is visiting Zion the other I have no clue what he’s up to. All I know is that every time I get near him he closes his computer, phone, etc. as fast as possible. Is that a sign? Went and saw the Indy Jones movie last night. I’m definitely getting old…but somehow guys like Harrison Ford and Clint Eastwood don’t – and not in the Barry Bonds sort of way (not older, and not bigger at the same time). The movie was OK. Definitely in line with the others. Weird that Lucas et al. progress from religious relics to alien encounters…or maybe progress is the wrong verb.

Well, lunch is over. Back to work. Peace in.

Demand, Indeed...

April 24th, 2008

A peer in Phoenix recently dropped a blog comparing the job market for Ruby, versus Groovy. Indeed.com is an interesting Job market tool, to say the least. I decided to plug in some of the keywords associated with recent projects. This is the result:

rails, ESB, RTSJ, CBE, OSGi, IPv6 Job Trends graph
rails, ESB, RTSJ, CBE, OSGi, IPv6 Job Trends rails jobs - ESB jobs - RTSJ jobs - CBE jobs - OSGi jobs - IPv6 jobs
Kind of cool, no? So, check this one out:

rails, ESB, RTSJ, CBE, OSGi, IPv6, SOA Job Trends graph
rails, ESB, RTSJ, CBE, OSGi, IPv6, SOA Job Trends rails jobs - ESB jobs - RTSJ jobs - CBE jobs - OSGi jobs - IPv6 jobs - SOA jobs

rVooz Screencast...

April 24th, 2008

Captured a very simple screencast, attempting to show some of the functionality we’re building out.

Check it out here: rVooz Overview

On a recent project I needed the ability to register and unregister users from a Rails app, specifically a simple User model. At first I just added the necessary capabilities to the model itself…then realized the functionality really should exist as a library/helper. Well, if I’m going that far – might as well just drop it into a “plugin”.

You can find the plugin here: xmmp4rails.

xmmp4rails is a simple method-level layer around a “few” of the capabilities provided by the awesome xmpp4r library.

To get the plugin:

git clone git://github.com/kitplummer/xmpp4rails.git

Here’s how I’ve used it – in my model I’ve got this:


...
before_create :xmpp_register?
...
def xmpp_register?
    begin
      register_account(self.login + "@" + CONFIG['hostname'], self.password)
    rescue StandardError
      return false
    else
      simple_send('gateway@' + CONFIG['hostname'], 
                         'CONFIG['jabberpw'], 
                         'admin@' + CONFIG['hostname'], 
                         "new account: #{identity_url}")
      return true
    end
end

So, if the registration fails, so the does the account creation. Obviously with the library called from the model you can do different things with it. Notice the simple_send method too. When an account gets created in the app – the model sends me a notification via Jabber.

I’ve also provide a simple stub so the models can still test out completely.

Hopefully this will be useful for someone else. I’d also love a reason to keep extending the functionality wrapped, as well as flesh out the tests with RSpec. Let me know.

I recently wrote a non-traditional paper looking at how it might be possible to integrate Agile practices into a software maintenance activity. Academically I don’t expect the paper to go over so well – but, believe it might be of interest to some who’ve been asked the same questions as me.

The paper uses a very simple “helloworld” application written in Ruby and highlights a few really cool Ruby tools.

Anyway here’s the paper in PDF form – feedback always appreciated.

I’ve also written a very similar paper on the potential for IV&V integration into an Agile project. I’ll probably post this one as well in the near future.

Rails Vs. Merb...Footprint?

April 21st, 2008

So, I realize if you are reading this you actually care about Rails and Merb. Therefore I hope you are not absolutely perturbed at the lack of quality content here. :)

Out of strange curiosity I decided to see which framework was truly lighter in “default” form. I simply ran each’s command to create a blank projects then looked at the “size” of the created directory.


$ rails test

The resulting project weighed in at 400KB.


$ merb-gen app test

Merb’s project weighs in at 104KB.

Amazing? No, not really. But, now I’m wondering what the size of a Grails project is…

It’s not very often I read anything on the web and get excited. But, I just can’t help relay this nugget of pure rationalization:

12 Things You Should Know About REST and WOA

Enjoy getting smarter.

Wow. I started to get a “real” sense for the state of Rails and the surrounding Ruby-based frameworks on Friday morning. You know what they say about making promises…

Needless to say I don’t have a working geo-client. I did chase about every possible rabbit. There were some promising options including Merb with a generic session captured in DataMapper. Ironically the simplest solution is the Ramaze one. Way unfortunate that they aren’t pushing the OpenID capability. I think if I had the time, I’d debug their OpenID-mongrel problem. But, I still believe we should get the geo-client over to Rails for the sake of continuity across our code/project-base.

The real irony here is that everyone has seemed to go the custom OpenID solution based on the openid-ruby gem. Not necessarily surprised just wondering way the people that put effort into a plugin for Rail 1.x/OpenID 1.x are putting the same effort in to maintaining them for Rail and OpenID version 2s. Strange. This is one of the problems that I think the Java world with its more Darwinian approach to projects. But, due to the Rails defacto documentation being blog posts the old (weak) stuff seems to live off for ever…and not get maintained in the same way as Java-ish projects – it really is self-centered. I supposed this is somewhat due to RubyForge, and the general lack of a true “foundation” to house Ruby projects ala Apache or Eclipse. I wonder why that is. No, not really I know why. It is because of shops like 37Signals…not “getting” the greater good part of Open Source. Don’t get me wrong I’m not necessarily fault them – just saying that they are definitely partly responsible for the state of things Ruby and Ruby on Rails.

ActiveRecord is a terd. I appreciate most of what it brings to the table…but, I’m really struggling with it – and any intuitive understanding. I’ll take the blame for most of it – not all of it. For example, why does this work:

@openid = UserOpenids.find(:first, :conditions => ["user_id = ?", @user.id])

And not this:

@openid = UserOpenids.find_by_user_id(:first, @user.id)

It took me at least 4 hours to figure this effer out…and I still don’t understand.

Recruiting is a growing problem for the branches of the Military. If the state of the “battle” continues on it’s current path – it will prove to be somewhat insurmountable.

The real problem lies with the “skillz” needed by our soldiers, airmen, seaman (and Marines), as well as coasties. Where the military has typically “trained” to reach the required performance – the cost to do so is growing beyond the ability to recover the investment within four years.

Obviously I’m really only addressing the problem as it relates to “technical” skillsets…like Math and Science. For example…I’m a high school student excelling in Mathematics and Science (possibly Computer Science). I have the choice of either attending a four year school, graduating, getting a job making 65K/year; attending a four year school, graduating, getting commissioned as an officer and making ~32K/year; or enlisting and earning ~17K/for the first year. Here’s the real problem. It would take almost 8 years from the military route’s pay to double…assuming “good” behavior. If I were an exceptional professional I could double my pay within 5 – easily.

Air Force’s Cyber Command recruiting commercial does an excruciatingly painful job at trying to be cool to this crowd. The first problem with this…is that it shows “operators” clicking on a touch screen. Operators are literally just that. What it doesn’t address is the intelligence that is really required…the engineering mindset (social or technical).

Also, operators don’t develop the systems (really no one serving does) – federal contractors do. The “touch screen” technology as well as the command and control applications are an example of such a case. The military branches are also competing with the folks that actually engineer the stuff. However, having served in the Air Force I know there is a lot more to operating and maintaining – thus the fairly lengthy technical schooling session plus constant on-the-job training. And, back to my original assertion that from an investment perspective this may be an insurmountable problem.

This Air Force commercial is a little better – but, notice that the guy is a captain. The majority of the people in the video are not. The reality is that our Air Force’s “network” war is being fought by high-school graduates.

Navy Seal Recruiting Commercial But, let’s be real – we all know that these are just commercials and don’t truly represent like this one

Ok, seriously. Here’s the wiki entry on Air Force’s recently established Cyber Command:

http://en.wikipedia.org/wiki/Air_Force_Cyber_Command

This is serious stuff; seriously technical stuff, requiring massive innovation to stay in the lead. Basically, what is happening is that the Air Force and Navy are recruiting against the likes of Google, Microsoft, Cisco and Garmin. I’m sure that these guys aren’t even aware. But, I’m equally sure that the Air Force and Navy are.

Patriotism aside I can’t arrive at any logical solution that would lead me to the military – especially based on the pay potential. The “funding” for school doesn’t cover the difference in salary over the first four years either. My oldest son is already talking about going to the Air Force Academy. Fortunately, I am a patriot and so is my wife who is a Captain in the Air National Guard. But, we are the minority for sure.

I don’t think this is a winnable war for either the Air Force or the Navy unless they throw the right incentives. Pay is a good starting point…though I don’t see this as the ultimate solution. I’ll throw this last idea out there as a parting shot. What if the Air Force offered college grads with direct job placement into the top federal contractors (guaranteed) and possibly with commercial companies like those mentioned above – after their commission and duty time is served? This is a positive for all stakeholders. The Air Force ensures that there needs flow in to the contractors. The contractors ensure they get personnel that understands the problems. And, the individual gets a job that allows them to take advantage of all their knowledge, skills and abilities.