Archive for July, 2008
Technology Debt? Don’t bet on it.
Written by Kendall Miller on July 27, 2008 – 3:21 pmIn the past two years I’ve heard the term Technology Debt thrown around to justify a number of technology decisions. In an effort to come up with a term that would bridge the business-technology gap, someone came up with Technology Debt to indicate that you were basically creating a future liability that would have to be paid back - rewriting a section of code or switching out a module, whatever. Since business folks deal with assets and liabilities routinely, expressing subtle technology problems in financial terms has a lot of appeal. The basic concept is most frequently used in relationship to software: Let’s say you defer something to a future release so you can get the release out the door. Perhaps the feature will only work for very few customers but you don’t have time to generalize it, or the solution won’t scale as new users are added.
This is fine as far as it goes, but like any metaphor while it may be a way of explaining some aspects where two things are in common it’s very easy to overextend because in fact it isn’t a true financial liability.
Take a hypothetical example: You are supposed to add federated identity to your web application. What you want to do is create an identity broker that will allow your SaaS application to connect with Microsoft’s ADFS, OpenID, and a few variations of SAML. You believe this will get you the market reach you need, and by creating your own identity broker you can decouple your application from changes in this still evolving space, as well as support your own native security technique.
As you dig into it, you realize that this just isn’t feasible in the time you have: You need to get a solution done in two months to meet a commitment to a customer, and it turns out this customer just uses ADFS. It just so happens that your web framework can easily work with ADFS directly, so to save the schedule you drop back and just do ADFS. From a development standpoint this is a hack - you are doing something quickly you can’t extend to meet the original requirement and you’re pretty sure that you’ll need to undo this later and do it right, which will cost more than just doing it right the first time. This is Technology Debt.
Metaphors have Limited Application
The metaphor doesn’t hold for long. First, unlike real debt there is no external requirement to pay this back. Perhaps you never will need to support more than ADFS, or that after all of the talk customers just won’t adopt federated identity. At the start of each release cycle, you can look at the competitive market and see what is the correct, most important work to be done. It might be that you’ll have to make good on something you deferred, but you might not. If you didn’t, it never was debt. How confident are you that you can tell the difference right now?
Second, all technology has future liability. The more code you write, the more you have to maintain and support. That has a cost as well for the future. Depending on the nature of your product it could mean that you have to support questionable past API decisions or obscure and intricate features of your product. Every feature has a cost to maintain, every line of code you use or reference in a third party library has weight. Only talking about deferred development as technology debt implies that what you have right now is all asset, but it isn’t.
Rampant Misuse
The biggest challenge I’ve seen is that the metaphor is used to push development team goals on the business without having to adequately justify them. By handing business folks something they can easily relate to, it’s easy to gloss over the underlying technical implications.
For example, say you have an application that’s currently written in Visual Basic 6. You can justly claim that Microsoft has dropped support for it and that the day is coming when it will no longer run on the latest operating system (Microsoft has committed that it will run on Vista and Windows Server 2008, but that will likely be the end). This sounds very alarming indeed! Naturally, the answer is to rewrite the entire application in .NET 3.5. Yes, this will take longer and cost a lot more than just adding the features you need to the existing code, but it eliminates all of the technology debt represented by that old nasty VB6 code.
Now look at it a little more objectively. Yes, you will need to eliminate that VB6 code at some point - notably when you are upgrading from Vista to whatever’s next. When will that be? Well, if you believe the hype that people love Windows XP and may just consider Vista in the future, you have some calendar time. As long as it’s done by then, Microsoft dropping support isn’t a real issue. We’ve yet to work with a client who’s VB6 application didn’t work just fine on Vista, thank you very much.
Second, with rare exception every modern technology has a half-life. The notable exceptions are COBOL, C, and C++. You can with confidence know that these languages are still going to be in active use in 15 years and that code you create now will work with minor to modest adjustment on current platforms at that time. I would dispute if a similar claim can be made for the latest crop of languages. A major reason for this is that modern languages are really whole environments - a programming language and an API/runtime. While it may be theoretically possible to write a C# compiler without toting along the .NET runtime, it isn’t going to happen. Likewise for PHP, RoR, and even Java. Java’s framework is much more shallow which ironically will likely give it more life because it can adapt to radical changes in computing environments and there is already an intent to decouple most of the code from specific frameworks.
This means that today’s latest and greatest environment will be tomorrows VB6. Just listen to people that jumped on .NET 1.1 discuss how they’re going to upgrade to .NET 2.0 or later, and that’s really not a particularly dramatic move.
Fundamentally, when you purchase software you’re making a bet in the vendor and community behind it. This is one place where the LAMP stack has a number of advantages because of the openness of the environment and the institutionalized tolerance of actively supporting releases for a long time. This is fundamentally enabled by their open source nature, but even if you had the source code for a commercial product it’s not likely you could do much with it; unless it’s fairly simple the burden of maintenance is likely higher than the cost of replacing it. Counteracting this are a lot of hidden costs to open source that may be difficult for a small team to absorb.
Easy Metaphors Seldom Produce Great Outcomes
Next time you’re trying to bridge the gap from technology to business, try to stay away from simple metaphors like Technology Debt. Instead, have real conversations to articulate the potential business impacts of the technical decisions and then hear from the business what they are concerned about. With a real dialog, everyone is in on why you deferred work to later and what bet is being made, and no one will be surprised when you do show up in a year to start porting that VB6 app to .NET.
Tags: IT Management, Requirements, Software Development Process, Technology Debt
Posted in Management, Software Development | 2 Comments »
The Best Technology For You
Written by Kendall Miller on July 13, 2008 – 11:44 pmIf you spent several hours some afternoon researching on the web what technology is the best for your next project, you’d probably come to the following conclusions: Linux is the best, or perhaps the Macintosh… Of course everything can be written in PHP or Ruby on Rails. If you’re feeling very stuffy, you might be old fashioned and use Java or .NET, Windows or any flavor of Unix that isn’t Linux. For your database you should just store everything as XML files, but if you feel compelled to have a database use MySQL. But if you’re still a slave to the 1990’s then you might decide to keep using the corporate dinosaur- Oracle or Microsoft SQL Server. In the end, the only constant is that whatever you’ve used in the past is certainly out of fashion and certainly a slow, archaic approach to solving problems.
Nearly all teams work within a relatively closed ecosystem - the technologies and people represent only a minor subset of all technologies available today. Even within these small groups the number of choices at every level are daunting. Even if you’ve selected your OS, language, framework, and database - what architecture model are you going to use? What is your data access and caching strategy? At each turn you’ll want to pick the best option but have a flood of choices to select from. Many people can tell you about how they led a project that used any particular technology and it worked like a champ with no drawbacks. On the surface it makes it possible to defend just about any new technology as the way to get your next project done.
What is very hard to find is a real comparative analysis that highlights in comparable situations the results with different technologies. It’s not a surprise this is so - such analysis is very expensive and time consuming, and few companies would try to solve the same exact problem using competing technologies because it’s not the business they’re in.
Where does this leave you? What technology should you use on the next project? Most likely, you’ll have the best success with an incremental improvement on the technologies you already have in your toolkit. Why?
Infinite Solutions in Infinite Diversity
Most conversations in technology on the web are exclusive - they advocate X over Y or Y over X. The truth is much more that X or Y can both solve the problem but do it in different ways and with different levels of effort for a team starting from scratch. What’s much more useful is to ask why you can’t solve the problem effectively with the tools and technologies that are a natural fit for your environment. Even if a new technology may be the easiest way to solve the specific problem you’re looking at it may not be the best choice when you consider everything that goes into creating the entire software system and maintaining it over time.
When confronted with a strong advocate for a technology shift, keep the conversation focused on the benefits of shifting away from the natural or familiar selections for your organization.
New Methods are Expensive
When you introduce new technologies or tools there is always a short term hit. Most respected research indicates that even technologies and tools that have a substantial improvement in effectiveness are at best neutral on the first project that uses them. The most successful technologies and tools are ones that are evolutions of things your team already knows. The more divergent it is from that, the more time it will take to get over the learning curve, establish best practices, and generally become effective.
Known Problems vs. Unknown Problems
A common challenge when comparing a new technology against existing methods is not recognizing that while you know of all of the problems with your existing technologies, you don’t know of the problems with the new ones. This can lead to a comparison that shows a number of critical problems with the current technology, and none on the new technology. It isn’t that there aren’t problems with the new technology, it’s that you don’t know what they are yet. Whenever you put in a new technology, no matter how promising it is, it is going to have new, unexpected problems.
What’s worse is that your organization most likely has workarounds for every problem you’ve encountered, so they don’t really have the impact of a new problem. Your development team may not know about them, but talk to the operations staff, support staff, and your users before you assume that a technology problem that worries you really is at the top of their list. It may be that the big memory leak in a third-party library that has you wanting to rewrite a subsystem is conquered in production by having a script reset the service every night.
Existing Code and Libraries
It’s very easy to underestimate the value of existing libraries and practices in effectively solving problems. When faced with a new assignment, your developers can draw from a large pool of existing, tested solutions to a range of the more mundane, plumbing aspects of the solution. This includes storing user information, reliably working with data storage, security systems, and other functional requirements that aren’t unique to the problem at hand. These software libraries accrue over time as developers face similar problems even in development shops that don’t place a high emphasis on modularity and reusability - as long as you have source code control and developers that aren’t paid by the line of code, they’ll naturally find ways to adapt and remold things they’ve already done to fit new needs.
When you have a major technology shift, losing the use of this common body of code will require the first project to reinvent it. On the surface this may seem straightforward but it’s usually held up by a desire to understand exactly how to best accomplish the same common tasks in the new environment. For example, you might have written your own security system for your previous environment which you’ll then need to either re-implement or drop in favor of a built-in capability of the new environment you’re targeting. What’s worse is you need to make these critical decisions at the time when you have the least experience with the new environment: Is its built in security system really sufficient for your needs? What about logging?
Your Customers Don’t Care
With the exception of a narrow range of situations (such as developer tools), your customers really don’t care what technology you use to implement your solution. After all, they’re buying your solution not the technology you wrote it in. Even if the IT representative of the evaluation team in a potential customer objects because your entire solution is written in a technology they don’t like, in the end they are often overruled unless they can point to a practical implication that you can’t mitigate. For example, you may get overruled because it’s a Unix shop and they won’t accept a solution that only runs on Windows. Even in the most extreme cases, if you provide enough customer value it will conquer any customer technology objection. If the prospect has no Windows servers, that translates into a finite cost for them to support a unique system in their environment. If your value well exceeds that, then it isn’t the key challenge to crossing the chasm to that prospect.
We often hear developers discussing internals of software development and giving them the weight of user requirements. If it isn’t visible to the customer, it isn’t a requirement. In the end, your customers don’t pay you to have a beautiful object model. They don’t care how hard it is for you to create your product or what hoops you have to run through. For them, it’s a cash for capabilities decision. It may be true that doggedly sticking with an old technology will mean you can deliver fewer features with each release, or you won’t be able to run on the latest operating system but in the eyes of your customers the question is still how compelling the functionality is and whether you can run on the operating systems they use.
Ignore the Pundits
If you’re part of a shop that has a track record of producing results, be proud. Don’t worry about what is all the rage at producing the next social networking site, focus on what is effective for you. For projects that can afford the risk, take the opportunity to incrementally improve your technologies and methods: Try out a new version of the development framework or new capabilities of the latest database version. Just remember, you can always tell the pioneers: They’re the ones lying on the ground with the arrows sticking out of their backs. Unless you’re part of a dedicated research team, most often you’ll get the best results by waiting for the first round of adopters to figure out what did and didn’t pan out with the newest release and then benefit from that experience. There’s no satisfaction in burning six months working out the kinks of version 1.0 just to have everything addressed in version 1.1 published a month later.
What’s Your Experience?
Have a great story about being the pioneer, working a project that was packed to the gills with the latest and greatest, only to fall on its face? Or perhaps you found raging success completly severing your ties with the past? Drop me a line or leave a comment about it.
Tags: Project Management, Requirements, Technology Selection
Posted in Management, Software Development | No Comments »
Pick Your Scale, any Scale.
Written by Kendall Miller on July 6, 2008 – 11:51 pmLet’s say you’re starting a project to create a new software system. How big does it need to scale? Realistically, either:
- This new system fits into an existing business, possibly replacing a prior application, so you can predict with some accuracy the different aspects of scalability that apply to it.
- It doesn’t, and you can’t.
The second scenario is the most interesting one. First off, let’s face it - your new system isn’t going to be the next Facebook, MySpace, or eBay. In short, you don’t need to worry about having your system needing to be designed front to back as a super-scalable system. This is good because the options at that level are time consuming and resource intensive.
The key question you need to understand when laying out a new software system is to what degree it needs to scale without being re-written? This scale is unlikely to be your “best case” business size, because scalability has opportunity cost. This scale should be defined as specifically as reasonable, and clearly understood and validated by both business and technical staff. This ensures that if your business grows beyond expectations that it won’t come as a surprise if you need to make even major changes to your system.
Creating facts from Air
Let’s say you’re starting to develop an application that fits into the second category above. You still need to work out what your scalability target is.
To make any decision that is better than random, you have to work out some aspects of the expected scaling of the application. In the absence of real facts to extrapolate scalability from, you need to cooperate with the business side to established presumed facts of the scalability requirements. This may sound a lot like assumptions, but they really go beyond that because these will become facts as you develop the system. As a starting point, make it clear to all involved that:
- If the targets are low, it should be assumed you’ll have to turn away business because the system can’t scale above them.
- If the targets are high, the system will cost more and take longer to create.
In most businesses, the second outcome is worse than the first. Why? Because the second is a price you pay up front, before the system goes into service. The first is based on an assumption: you might have to turn away business. You also might be able to realize it in time and address the issue. From a business standpoint, this is a better trade off. Finally, there’s the non-technical aspects:
- The sooner you have a working system, the sooner the business can validate the market and start getting real data on uptake to adjust your scalability goals
- Unless the product is a failure, you expect demand to eventually exceed the capacity of the system, it’s just a matter of when. If it does, then you should be able to afford rewriting all or part of the system. In other words, the funds to solve the problem should be available if you have the problem.
From this comes an axiom of scalability:
The system needs to be based on the lowest scale that will provide enough time and money to replace it with a new system.
Put another way, a system that is faster or more scalable than it needs to be for the business was more expensive and took longer to develop than necessary. Think of it like a race car: The ideal Indy Car would fall apart just after the judges validated it won without breaking the rules. Any stronger and that strength could have been put into something else. The time you spent making it more scalable than necessary could have added more features, fixed more defects, or gotten it out the door sooner.
Establish a Growth Curve
The growth curve needs to be sufficient to inform the developers of what decisions to make at each point. To get there, start with describing the scale from the business stand point. During design of the actual system you can keep translating this into the specific requirements for speed, storage, and capacity based on the behavior of the actual system. This will prevent you from achieving technical goals that don’t satisfy the business goals.
For most systems, you want to establish the business goals for:
- Number of Possible Users: How many accounts will there be on the system? This is an upper bound of the number of people that could access the system if they wanted to.
- Number of Simultaneous Users: Number of accounts that will be accessing the system at the same time. For most applications, at the same time is likely best thought of as in the same 15-30 minutes.
- Number of Customers: For most applications delivered to businesses the number of customers (e.g. businesses) drives the scalability of some parts of the system (such as configuration and data storage) will scale based on the number of customers, not the number of accounts those customers have.
- Data In and Out: If the system is going to have any imports and exports that aren’t user-driven (such as EDI feeds or a public API) then the number of partners (other entities that will exchange information with you) and the frequency of exchange need to be determined.
Things to not bother with:
- Response Time: For customer interactive products, response time is dictated by what end users will tolerate and is not really going to be a business decision (aside from deciding if you’re going to produce something your customers are willing to use). For non-interactive products or back-end this may need more discussion with the business, but again - the business is going to expect you to be able to figure out what will make it a success.
- Data Retention: Assume it all has to be kept and more indefinitely. In the end, storage is cheap and this design decision rarely costs a lot of made up front but is expensive to reverse. Data also has the amazing power to make heroes out of IT when the business starts posing questions later and you can answer them. Generate as many facts as you can now to help you out later.
These items are past the point of diminishing returns with the business. You should work them out within the development team and document them, but you shouldn’t believe that any business sign off you might get is binding or useful.
Build to the Scale
Once you’ve established your growth curves, pick your candidate architecture and translate the growth curves into system performance requirements.
Hypothetical Example: If you need to support 1000 simultaneous users for a web application, determine the dynamic web hits per second by determining how often an average user will request a dynamic page (say ever 5 seconds, which is very fast for most dynamic applications) These two numbers would give you a dynamic hits per second of (1000/5) = 200. Then add how long each page will take to calculate (make a goal of say 250ms) to get how many requests you need to be able to process at the same time: (200 * 0.250) = 50. This is the key scale point for your web application: When deployed, it must support 50 requests being processed in parallel. You’ll need to get to this point by either making it really scalable on a single server, or splitting the load over multiple servers.
One thing that should jump out of the math behind this is that anything you can do to make the calculation time of a single page drop pays big dividends: If you drop the average calculation time by half (125ms) then the number of requests in parallel drops by half (200*0.125) = 25. This in turn may well cut the number of servers you need in half, easing your maintenance and deployment cost. If you can’t do this, reduce the number of dynamic pages requested per second by either making more static pages (such as pre-rendering pages that change but don’t change frequently) or caching dynamic pages that have some predictable consistency (which really makes them static pages). This is often much trickier to do and test, so your best first option is to reduce the time for each page.
Side Point: This also highlights an easy way to accommodate guessing low on a system that’s been in service for a year or more: If you’re processor bound you can replace that hardware with current units and often pick up 30% per year it’s been since you purchased the original hardware. This won’t save you from network problems, disk storage problems, or some memory problems, but it is surprisingly handy.
As you look at each candidate architecture, look at each component and determine the critical “how much, how fast, how often” factors based on the business inputs. If you change your architecture or external interface design (the user interface or import/export capabilities) you need to re-evaluate if you’ve moved the targets as well because your design goals no longer reflect the business growth curves.
Really, to the Scale
Within your development team you will typically have two types of developers you need to watch: Those that never consider scale and those that obsessively consider scale. The former will build it however and then wait to see if there is a performance problem. The latter will try to make every system the next Amazon. Neither situation is good. Identify early people’s tendencies and work to manage them to the center. Remember that the system is only as scalable as its slowest part, and there is always a slowest part.
You can get good results by having the people that are most concerned about scalability move around on the project to different subsystems. This will tend to keep them too busy to earn the keeper of the nanosecond award on any one system (which they will do if you let them stay put and just work on one system) and will make it unlikely that more cavalier developers can hide a problem. It will also help the team learn from each other: It often isn’t worth making a specific feature as fast as possible, and it is always worth thinking about what will make a feature fast before coding it.
Finally, budget time in the development team to fix scalability issues. Regardless of how much work you put into it, once the real system is build and tested you’ll find places that are slower and less scalable than you expected. If nothing else, you need to develop an accurate model of how the system should perform in production so you can check the real world against it later. As your business grows, you need to be able to get ahead of it and understand when it is time to make the code faster, add hardware, or do something else to stay one step ahead.
Disk is Your Friend, but Beware the Network
If you’ve gone over the system from nose to tail and you’re disk bound, you’ve probably optimized that design as well as you can. Disk has gotten faster at a much slower pace than memory or processor, and being disk bound means you’re getting all the requests where they need to go in a timely manner and are able to process the inputs and outputs, so now it’s in the hands of the hardware. Unfortunately at that point there generally isn’t much more you can do: The difference in performance between server drives and the fastest drives money can buy isn’t very much.
If you’re finding that you aren’t disk bound and you aren’t processor bound then be worried. You’re either network throughput bound or you’re network latency bound. If you’re network throughput bound, you can probably fix it cost effectively with some basic engineering either in how you select what to send across the network or what you cache so you don’t need to send it across. You should try to give yourself some headroom here for growth, but faster networks can be purchased and you can generally tweak the software to mitigate this in minor updates.
Being network latency bound is a more serious issue because it often means that you are at the practical scalability limit of your application. The difference in network latency between relatively cheap hardware and the best hardware isn’t very much, and has been essentially constant for the last 10 years. You can’t buy your way out of this problem. It also is typically caused by a badly designed interface between components of the system which will need to be substantially or entirely rethought and rebuilt to address, which isn’t easy to do with a running system. If you find yourself in this situation and you aren’t sure you have met your business goals you should rethink your approach immediately. Because no amount of money on hardware can get you out of this problem, caution is the word of the day.
Tags: Infrastructure, IT Management, performance, Project Management, Scalability, Technology Selection
Posted in Management, Software Development | No Comments »