Archive for software

Radiant CMS Tutorial - Custom Javascript in Admin Pages

At the moment I’m working on a fairly complex extension for Radiant CMS.  In creating the administrative pages I want to use a javascript library that is not distributed with the core radiant code.  This post will describe how to implement your own extension that can use an external javascript library, without playing around with any of the core radiant files to inject the javascript into the administrative layout.

It’s actually really easy to do.  If you haven’t created a Radiant extension before I’d recommend following this tutorial on the Radiant wiki.

Inside the Radiant GEM, the standard page layout resides at app/views/layouts/application.html.haml

The lines of code that insert the javascript tags are:


    - @javascripts.uniq.each do |javascript|
      = javascript_include_tag javascript

The @javascripts variable is populated from inside the app/controllers/application_controller.rb file.  The culprit is below.


  def include_javascript(script)
    @javascripts << script
  end

Pretty simple huh?  So, all you need to do, is call this method from within your new controller, because all controllers inherit from the application_controller.rb file, so they have access to this method, and you can have different javascript included for each method if you so wish.  In (assuming the example LinkRoll extension was built as linked above) vendor/extensions/link_roll/app/controllers/admin/links_controller.rb 


  def index
    include_javascript("admin/mootools-1.2-core-yc.js")
    @links = Link.find(:all)
  end

That will insert a link to admin/mootools-1.2-core-yc.js inside the admin/links/index page.  Righto, so now the only thing left to do is get the mootools-1.2-core-yc.js file into the actual public/javascripts/admin directory within the project.  What you want to do is alter the vendor/extensions/link_roll/link_roll_extension.rb file so that within the activate method the file is copied over.  I’d recommend making a public/javascripts/admin directory within your extension folder, and putting the file in there.  Then, when activate is called on the link_roll_extension.rb file, the activate method will copy the file over to the projects public/javascripts/admin directory.  You should also delete the file when the deactivate method is called in the link_roll_extension.rb file.

Questions and comments please!

Comments (1) »

Not all software is created equal

The types of companies I (used to) work for and (now) consult to,  love release management.  At least their IT people do.

For those who are not in the know, check out the following 2 resources for a bit of background

When companies often start out, they focus on getting IT systems enhanced as soon as possible.  A simplified, but common cycle is design (maybe), build (definitely), test (should) and deploy (definitely).  Steps in this process may be skipped when an organisation is small, and the side-effects of getting something wrong in build or deploy can be handled on-the-fly.  As companies mature and grow (in both size, application complexity, and IT landscape complexity), they often wish to have more control over the processes that manages software design, development and deployment.  As enhancements start to involve distributed application development (eg, introducing a new feature on a customer care system, that requires a service on a billing system, and have that exposed by an integration bus, and that integrated with from a web or IVR channel), the process and dependencies involved with deploying that application become more complex.

To ensure that the cross system (and often) cross department, company or country design, development, test and deploy process, companies introduce Release Management Processes.  Different application development projects are collected together, and managed from a central point - who is unimaginatively known as the Release Manager.  The release manager usually has responsibility for delivery and deployment of all the changes requried within a system, and across systems for a particular instance of deployment activities (that’s a wordy way of saying that a whole load of stuff gets developed, tested, and then deployed together).

So, to recap - early days - applications designed, developed, tested and deployed whenever people want.  More mature business - applications designed, developed, tested and deployed under a managed process, with defined implementation dates.  In principle, that sounds fine.  In fact, it sounds like a sensible way to manage development and deployment.  Software can be complex, and complexity grows as you have more systems involved, different parties, different skills, and in some extreme cases, different countries and cultures.

Business users (ie, the people paying for the development, and specifying the functionality) rarely like release management.  It’s costly.  It’s slow.  It’s inflexible.  And this is more true if the business users know a little bit about software development, and especially if it involves the web.

The web is known for being an inherently agile environment.  Web applications are usually self-contained and loosely coupled, and can be easily and quickly altered.  There are other types of applications that exist in enterprises that do not have the same inherent agility.  Customer Management Systems, Billing Systems, Banking Systems, ERP systems.  All of these systems usually have long lead time on changes, strict testing requirements, are have historically been designed and developed in a different (monolithic) manner to web systems.   The requirements on them are often different too - they often aren’t about exposing new “services” to the public, but more about internal services, bug fixes, operational fixes, or enhancements to allow new products to be offered.  However, they don’t interface with the external customer and often aren’t driven by the same requirement for agility - it’s often easier in business (for your brand, and bottom line) to deploy something that is a bit crappy internally (manual processes, double-keying data etc) if you can get the message out to the customer.

Business users want the ability to alter the messages and functions that are delivered to their customers on their terms - when they want - not bound to some (in their eyes) arbitrary release schedule.  They don’t understand why their functionality must be deployed with another, completely unrelated, system or process.  They want to get their product to market.

I feel strongly that certain types of systems fall nicely in a “release managed” category, and others fall into a “system owner” managed category.  (sidenote: I feel that for a platform that supports as much functionality as “the web” that often The System is too coarse a unit for splitting - it could be taken down to business process, journey, or user type).  For me, I believe that systems that have a requirement to be highly agile, provide a high level of flexibility (configuration/scripting, as opposed to packaging and release of compiled code), and support essentially decoupled functions and flows, should not necessarily form part of conventional release management processes.  The “release early, release often” convention can be followed on these systems.  Obviously, a business must be made aware of the risks with this approach (e.g., more defects are likely to arise), and they should also be made aware of some of the sensible processes and changes in methodology to make this approach work (e.g., agile development methodologies).  In my mind, integration and web implementations fall into this category.

Integration systems enhance the ability for each system to remain decoupled from it’s peers - and this in turn means the systems are more modular, and should be able to support development and implementation (outside of a monster sized release), even when all of the required functions are not implemented.  Integration systems can provide stubs that indicate a service is unavailable, and when each system is finally ready, then the processes can be turned on in each.  Integration systems are inherently cross application, yet system independent at once.  This paradoxical view on integration is what makes them great candidates for exclusion from release cycles - they are self contained, but support both the situations where external systems are present, as well as when they aren’t.  This level of resilience and flexibility means that they are a core enabler to allow other systems to deploy functions, and still work when the up/downstream systems they are reliant on do not exist.

I have a couple of recommendations if your organization is considering looking to migrate to a release management style approach for application development and deployment:

  1. Applying release management only to systems where it makes sense to do so, will allow a business to maintain the necessary rigour required for financial, legal, regulatory, professional and moral obligations.  Release management should not be a one-size-fits-all approach.
  2. Shielding systems with integration and process configuration flexibility (on/off switch for process/service enabling) will reduce the dependency of each system on it’s peers to be launched - and this in turn increases the flexibility to make changes to an individual system without them having a downstream impact, and increases the ability to more quickly make changes.
  3. Applying a finer-grained design, build, test and deploy scope (i.e., not cross-system) to customer facing systems will give businesses the agility they desire to get their messages to market.  This in turn will allow businesses to try more products and services in the market, and respond to competition in a more timely manner.

I believe following an approach that ensures that your systems are shielded from changes in each other, and promotes flexibility and agility in the customer facing systems is key to delivering true value to the business in terms of both responsiveness, and reliability.

No comment »

Open Source is a Meritocracy

For those of you unfamiliar with the term… Meritocracy.

Coté from Redmonk quoted the title of this entry in episode 14 of Redmonk Radio. Again, it’s another quote that was like an “Oh yeah” moment for me. In companies where you produce software (usually) the project timeline or budget is king. In the open source movement, the best ideas take as long to get implemented as needed - there is no overriding time line that says you must ship that feature by this date. Also, in distributed projects there can be healthy debate about the best way to implement things - the ideas and implementations with the best merit win.

I’m slowly catching up on these podcasts - making time on the train to listen is really working out for me.

Comments (1) »

Coding vs Configuration - The vendors are missing the point, and the customers aren’t helping

Large software vendors do (often in the long term) listen and act on what their customers say they want. However, implementations are still missing the point. What customers say they want and what they actually want can be very different things.

Historically people (like me) in enterprises have harped on to vendors for years about how we want their large enterprise applications to be more configuration driven rather than coding driven. The actual purpose behind this was about time to market, resource availability with the necessary skill sets required to maintain and alter the application, effort around testing and deployment, and certainty about the validity of the syntax and sensibility of the customisation. Vendors have responded by closing the code base, but offering more complex configuration environments - which is exactly what we have asked for (see next paragraph about how we have asked for the changes). However, what they have provided doesn’t meet the actual business goals of the request. For example, I’ve been recently looking at some Product Configuration software that has a guided Java coding environment for rules definition. This doesn’t actually make the implementation simpler. It means that your (previously) relatively unskilled (and that’s flame bait if ever I’ve seen it) configuration staff have to significantly increase their skills to match those of java developers. Its called “configuration” because its done in a “configuration” tool. The configuration tool is as much a config tool as Eclipse is (which has code completion BTW, is equally applicable for the task, probably nicer to use and definitely cheaper). What it’s done is moved the effort from the development staff, to the configuration staff. Assuming staff are happy with what they do, developers are unlikely to want to join a “configuration” team, and configurators are unlikely to want to gain development skills. One may also argue that your testing and deployment efforts are more difficult, because the coding that was done by people who know how to code, is now done by people who don’t know how to code - this in my mind introduces more risk. You also don’t know which parts of the application are affected by this complex configuration activity, and this may drive for more rather than less regression testing.

I’ve also been reading recently about user stories, which are something I’ve never professionally come across. I’ve been working for my entire professional career on waterfall based implementation projects, with requirements and scope specified in documentation like traditional UML use cases, interaction/sequence diagrams, and IEEE 830 style requirements. I wonder if the large enterprise is its own worst enemy when it comes to vendor software direction and influence. We are always writing (and that’s the first mistake) very specific (and that’s the second mistake) requirements for vendors to implement, and influencing them through RFIs and RFPs which contain hundreds or thousands of these requirements. Maybe if the interaction was more conversation and (business) outcome based we’d actually get what we wanted, instead of getting what we write down - which is always going to be flawed (inaccurate, incomplete, technology based rather than business value based, and driving misunderstandings between reader and writer). Conversations about outcomes are the way to get around the limitations of written software system specifications.

What we actually want and what we get are often different things. I’m beginning to understand that outcome driven conversations between parties playing their specific roles are the way to go. In a supplier-customer relationship, the customer should tell the supplier what they want to achieve (in a business context), perhaps explaining why the current implementation does not meet their needs. The suppliers role is to understand the customers issues and the drivers behind why those issues are actually issues, and then propose ways those issues could be resolved. Often it may be a process or simple usability issue, sometimes there are fundamental issues with the implementation that require longer term efforts to fix. Regardless, the vendors know their software and the capabilities it possesses and the customers know their business drivers and understand how they are using the software. Each party should focus on playing their part in the relationship and achieving their eventual outcome (customer = achieving the business value and business purpose they want, and vendor = getting a satisfied customer, which hopefully translates into a big purchase order for them).

No comment »

Requirements of Charles Schwab

I was listening to a Redmonk Podcast on the train on the way home from work today, and James from Redmonk said something that struck a chord with me. The quote was…

How many customers really have the requirements of Charles Schwab? That is an edge case and sometimes large software companies treat these edge cases as if they were the most sensible source of requirements.

This just really gelled with me. I’ve been working for the largest global mobile telecommunications company on earth for 8 years now, and we battle with vendors every day on requirements, features, architectures and roadmaps that we’d like them to build into their applications. What I take from that (and other things I’ve been reading and listening to) is that you have to be acutely aware of who your customer base is. If you are serving the top 5-10 companies in a particular sector in the world, then you can clearly afford to bend to their requirements, because that’s what they are paying you for. If you are trying to hit mass market, don’t try and emulate the big boys. Keep it simple. Keep the minimum. Keep the maintenance down.

I guess this aligns well with the philosophy that 37 Signals use with their rails apps, and also with the way I tried to create Got the GiST. That was an exercise in taking a painful and complex activity (tax preparation) and simplifying it so my mother could use it.

This is also something I need to remember when I start my new job in just over 1 month. Moving to the vendor/consultant side of the equation is going to be a real eye opener. I won’t always be working with very large enterprises.

The episode was only podcast 2 (very old!), I’ve only recently been introduced to these guys by a colleague. I say give them a listen if you’re keen for an alternative analysts take on IT and the industry.

No comment »

Confusing Marketing Messages

Sun, what are you up to?

Install java to experience the power of java? What is that supposed to mean?

Pointless Java Marketing

No comment »

Stupid word

wtf?

Word sucks

Someone needs to check the grammar rules in that thing.

No comment »

Poor Analytics

Boots! What are you doing?

Boots' marketing messages

I’m a dude. I don’t want to look lovely.

This really irks me. As part of my day job I perform IT system selections. One thing I know a little bit about is BI/campaign management/analytics software. It isn’t too hard to run a marketing campaign, and choose your messages based on the gender of the person you are trying to entice to purchase your products. Another option is choosing a subset of customers to market to - SELECT * FROM customers WHERE gender = ‘f’ might have excluded me.

Companies that don’t utilise their data well are just wasting an incredible important resource, and potentially creating a bad customer experience.

No comment »

Scope, creep. Part 2.

Ah. The satisfying feeling of knowing you’ve created some elegant and functional code. That piece of functionality took a bit longer than I expected. Now to make it more robust. I’ve got a bit of error checking and feedback to insert, then we’re ready to roll.
See more progress on: Start my own business

No comment »

Scope, creep.

It’s getting the better of me. I thought of a feature today that the application really should have. Now, I just have to build it in. Shouldn’t take me too long, I’ve just completed my design, now onto the coding.
See more progress on: Start my own business

No comment »