Blog Feed Post

Greedy (IT) Algorithms

Greedy algorithms can result in the right solution in the end, but rarely do

Don and I were having a discussion with our oldest son the other night about writing a chess program. There are myriad options for implementing the learning aspects of a chess program, but this is not a task intro-algorithmsfor the timid. He ended up proposing a much simpler solution (this was just an exercise in ‘can I write it’, after all) that would have essentially used a very greedy algorithm; one that made a decision regarding the computer’s next move based on current state of the board and what move would give it the most benefit right now.

For those of you not familiar with the concept, here’s a good definition from Wikipedia:

A greedy algorithm is any algorithm that follows the problem solving meta-heuristic of making the locally optimal choice at each stage with the hope of finding the global optimum.

The relevant (for this discussion at least) part of the definition is “making the locally optimal choice at each stage with the hope of finding the global optimum.” Greedy algorithms, it turns out, are not just for programming and developers, and imitate real-life more closely than we might think.

See, IT often makes it decisions using greedy algorithms. Choices are made based on what is optimal right now with the hope that it will also be optimal in the long run. Greedy algorithms can turn out to be “the right choice” in the long run, but it’s often because of luck (karma, chance, whatever) and not because of any great strategic thinking on the part of the decision makers.

We often see the use of greedy algorithms to make decisions when there is a problem with application delivery: performance, security, reliability. Because there is a problem right now that needs to be solved, well, right now, IT uses a very greedy algorithm that chooses a solution that is optimal now, but is often not the right choice in the long run.


What generally happens is this: an application has reached capacity, but usage is still growing. IT immediately executes a greedy algorithm, the result of which is to purchase a load balancer and a second server. Problem solved. But as usage grows so do attacks, and suddenly there crops up another problem, this time one of application security. IT again executes a greedy algorithm and comes up with a web application firewall. An acquisition and a deployment later and voila! problem solved.

But relatively soon after that performance begins to be a problem. IT, falling back on what it knows best, executes yet another greedy algorithm and comes up with another locally optimal solution: application acceleration. Another point solution is purchased and deployed, with a little more difficulty due to the growing complexity in the network and application architecture, and voila! problem solved.

You can see that as this continues the number of point solutions employed to solve problems that crop up is going to continue to grow, which is going to increase the costs to manage and maintain the architecture while simultaneously making it more and more difficult to troubleshoot any issues that may crop up in the future.

Using a greedy algorithm to make decisions about IT’s “next move” does not guarantee the optimal long term solution; it merely means that the optimal solution right now has been chosen.

That’s tactical thinking, not strategic thinking. And to be successful at (IT) chess you have to fit those tactical moves – which are necessary - into a broader strategy.


IT, like a chess grandmaster, needs to think more strategically when addressing solutions regarding the delivery of applications. Rather than view the chess-board architecture of IT as a set of connected but disparate squares, it needs to be viewed as a holistic battlefield across which a strategy can be employed that results in long term success.

We know that deploying applications requires long term consideration for scalability, reliability, security, and performance. At some point one itchessgame or all of these concerns will be a problem in need of a solution in the data center. Rather than look at architecture of the data center with a greedy eye, it is more efficient – financially, architecturally, and from a management point of view – to look at the architecture with an eye toward an optimal solution that affords an opportunity later on to “make the winning move” when other issues crop up.

Early on you may have a need only for scalability or reliability. A load balancer is certainly an answer to those needs, but it is not the globally optimum solution. You need to sacrifice the pawn now in order to take the king later: investing in a platform now rather than acquiring a solution lays the foundation for a successful strategy to winning the IT chess game in the long run. A unified platform that allows IT to deploy additional solutions when (and if) needed reduces overall costs in the long run, simplifies the architecture – making troubleshooting and management less resource intense – and improves performance of applications by eliminating extraneous devices in the infrastructure that can add latency and points of failure.

Greg Ness said it best in his recent guest post here on DevCentral: “As the cloud tears down silos, one trick pony solutions (including freeware) will have an uphill battle for relevancy, especially as enterprises tear down silos. [emphasis added]”

Chess grandmasters aren’t one trick ponies; they don’t use a single ‘trick’ to win, they employ a strategy. Greedy algorithms can’t compete with a grand strategy because they don’t look far enough ahead. They buy for the now, they don’t invest in the future.

IT needs to stop using greedy algorithms if they are to architect the next generation data center and start using a strategy that takes advantage of innovations and evolutionary network and application network infrastructure to construct a data center capable of implementing solutions that are globally optimal. While it is possible to win using greedy algorithms a sound, thoughtful strategy with an eye toward the future of the entire data center will almost always trump the immediate, locally optimal solution.


Follow me on Twitter View Lori's profile on SlideShare friendfeedicon_facebook AddThis Feed Button Bookmark and Share

Related blogs & articles:

Read the original blog entry...

More Stories By Lori MacVittie

Lori MacVittie is responsible for education and evangelism of application services available across F5’s entire product suite. Her role includes authorship of technical materials and participation in a number of community-based forums and industry standards organizations, among other efforts. MacVittie has extensive programming experience as an application architect, as well as network and systems development and administration expertise. Prior to joining F5, MacVittie was an award-winning Senior Technology Editor at Network Computing Magazine, where she conducted product research and evaluation focused on integration with application and network architectures, and authored articles on a variety of topics aimed at IT professionals. Her most recent area of focus included SOA-related products and architectures. She holds a B.S. in Information and Computing Science from the University of Wisconsin at Green Bay, and an M.S. in Computer Science from Nova Southeastern University.

Latest Stories
DX World EXPO, LLC, a Lighthouse Point, Florida-based startup trade show producer and the creator of "DXWorldEXPO® - Digital Transformation Conference & Expo" has announced its executive management team. The team is headed by Levent Selamoglu, who has been named CEO. "Now is the time for a truly global DX event, to bring together the leading minds from the technology world in a conversation about Digital Transformation," he said in making the announcement.
"Space Monkey by Vivent Smart Home is a product that is a distributed cloud-based edge storage network. Vivent Smart Home, our parent company, is a smart home provider that places a lot of hard drives across homes in North America," explained JT Olds, Director of Engineering, and Brandon Crowfeather, Product Manager, at Vivint Smart Home, in this SYS-CON.tv interview at @ThingsExpo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
SYS-CON Events announced today that Conference Guru has been named “Media Sponsor” of the 22nd International Cloud Expo, which will take place on June 5-7, 2018, at the Javits Center in New York, NY. A valuable conference experience generates new contacts, sales leads, potential strategic partners and potential investors; helps gather competitive intelligence and even provides inspiration for new products and services. Conference Guru works with conference organizers to pass great deals to gre...
DevOps is under attack because developers don’t want to mess with infrastructure. They will happily own their code into production, but want to use platforms instead of raw automation. That’s changing the landscape that we understand as DevOps with both architecture concepts (CloudNative) and process redefinition (SRE). Rob Hirschfeld’s recent work in Kubernetes operations has led to the conclusion that containers and related platforms have changed the way we should be thinking about DevOps and...
The Internet of Things will challenge the status quo of how IT and development organizations operate. Or will it? Certainly the fog layer of IoT requires special insights about data ontology, security and transactional integrity. But the developmental challenges are the same: People, Process and Platform. In his session at @ThingsExpo, Craig Sproule, CEO of Metavine, demonstrated how to move beyond today's coding paradigm and shared the must-have mindsets for removing complexity from the develop...
In his Opening Keynote at 21st Cloud Expo, John Considine, General Manager of IBM Cloud Infrastructure, led attendees through the exciting evolution of the cloud. He looked at this major disruption from the perspective of technology, business models, and what this means for enterprises of all sizes. John Considine is General Manager of Cloud Infrastructure Services at IBM. In that role he is responsible for leading IBM’s public cloud infrastructure including strategy, development, and offering m...
The next XaaS is CICDaaS. Why? Because CICD saves developers a huge amount of time. CD is an especially great option for projects that require multiple and frequent contributions to be integrated. But… securing CICD best practices is an emerging, essential, yet little understood practice for DevOps teams and their Cloud Service Providers. The only way to get CICD to work in a highly secure environment takes collaboration, patience and persistence. Building CICD in the cloud requires rigorous ar...
Companies are harnessing data in ways we once associated with science fiction. Analysts have access to a plethora of visualization and reporting tools, but considering the vast amount of data businesses collect and limitations of CPUs, end users are forced to design their structures and systems with limitations. Until now. As the cloud toolkit to analyze data has evolved, GPUs have stepped in to massively parallel SQL, visualization and machine learning.
"Evatronix provides design services to companies that need to integrate the IoT technology in their products but they don't necessarily have the expertise, knowledge and design team to do so," explained Adam Morawiec, VP of Business Development at Evatronix, in this SYS-CON.tv interview at @ThingsExpo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
To get the most out of their data, successful companies are not focusing on queries and data lakes, they are actively integrating analytics into their operations with a data-first application development approach. Real-time adjustments to improve revenues, reduce costs, or mitigate risk rely on applications that minimize latency on a variety of data sources. In his session at @BigDataExpo, Jack Norris, Senior Vice President, Data and Applications at MapR Technologies, reviewed best practices to ...
Widespread fragmentation is stalling the growth of the IIoT and making it difficult for partners to work together. The number of software platforms, apps, hardware and connectivity standards is creating paralysis among businesses that are afraid of being locked into a solution. EdgeX Foundry is unifying the community around a common IoT edge framework and an ecosystem of interoperable components.
"ZeroStack is a startup in Silicon Valley. We're solving a very interesting problem around bringing public cloud convenience with private cloud control for enterprises and mid-size companies," explained Kamesh Pemmaraju, VP of Product Management at ZeroStack, in this SYS-CON.tv interview at 21st Cloud Expo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
Large industrial manufacturing organizations are adopting the agile principles of cloud software companies. The industrial manufacturing development process has not scaled over time. Now that design CAD teams are geographically distributed, centralizing their work is key. With large multi-gigabyte projects, outdated tools have stifled industrial team agility, time-to-market milestones, and impacted P&L stakeholders.
"Akvelon is a software development company and we also provide consultancy services to folks who are looking to scale or accelerate their engineering roadmaps," explained Jeremiah Mothersell, Marketing Manager at Akvelon, in this SYS-CON.tv interview at 21st Cloud Expo, held Oct 31 – Nov 2, 2017, at the Santa Clara Convention Center in Santa Clara, CA.
Enterprises are adopting Kubernetes to accelerate the development and the delivery of cloud-native applications. However, sharing a Kubernetes cluster between members of the same team can be challenging. And, sharing clusters across multiple teams is even harder. Kubernetes offers several constructs to help implement segmentation and isolation. However, these primitives can be complex to understand and apply. As a result, it’s becoming common for enterprises to end up with several clusters. Thi...