Continuous Refactoring at Amazon: A Case Study

Between the project deadlines, we always feel there is code which needs to be improved

Usually Developers have the following 3 options:

- Bite the bullet and do the refactoring as they go along.
- Park the issue and address it later.
- Allocate special time when the project gets out-of-control.

As customer facing stories take higher priority, usually Developers are forced to choose the last option.

However a team at Amazon took a different approach. Attend this session to listen to their first-hand story of how they changed this typical behavior to achieve Continuous Deployment on a critical service.

 
2 favorite thumb_down thumb_up 6 comments visibility_off  Remove from Watchlist visibility  Add to Watchlist
 

Outline/structure of the Session

  • A Developer's dillema for legacy code
  • Testing Enclosing
    • Unit tests
    • Shadow Mode tests
    • Integration tests
  • Do not hold the basket till it starts spilling over
  • Examples
  • Questions & Asnwers

Please refer to the attached slides.

Learning Outcome

- Why & when it is important to refactor
- How to approach refactoring
-- Changing developer mindset
- Importance of Shadow-mode Testing

Target Audience

Software Engineers, Managers

schedule Submitted 3 years ago

Comments Subscribe to Comments

comment Comment on this Proposal
  • AgileSattva Consulting LLP
    By AgileSattva Consulting LLP  ~  1 year ago
    reply Reply

    Hi Mukesh,

     While I did read your response to Sonik as you would share your experience from following the engineering practices. Would it be possible for you to add few example code bases and how you would refactor them and use TDD as shield to existing functionality. 

    I would invite you to consider including activities that would engage the audience. It could be making a list of test cases for given code and re-factor them (just a thought, could be any activity relevatn to the topic)

    Good luck!

    Deepak

    • Mukesh Bhangria
      By Mukesh Bhangria  ~  3 years ago
      reply Reply

      Hi Deepak,

      Thanks for your nice suggestion. Yes, code is the simplest tool by which we can explain things better. I assure you that I will come up with nice code examples which will let people to think in that way.

      Honestly, I want to make it a real time engagements from the audiences.

      On a side note, if I see this kind of warm interest, I can turn this to a 'workshop/tutorial' as well.

      Thanks

      Mukesh

  • steve ropa
    By steve ropa  ~  3 years ago
    reply Reply

    Mukesh,

    I wonder if the topic is a little big for the time allocated.  Also, you list software engineers and managers as the audience.   When I think of managers, I think of the business side. Your abstract seems really to be aimed more at the developers. Are you planning on going deep into the business side of understanding the need/value of refactoring?  

     

    Steve 

  • Nitin Ramrakhyani
    By Nitin Ramrakhyani  ~  3 years ago
    reply Reply

    Mukesh,

    You have shared a link of blog post by Atlassian. Have you blogged about your own viewpoint on the same? Do you intend to covert the same blogpost in a slide deck?

    Being a PO, I face this dliemma all the time where alot of product code areas need refactoring and re-refactoring and there's constant push from the market to deliver more. While we balance doing both mostly, what is lacking is an 'Objective' framework ( Cost of Delay??) that could help teams prioritize the refactoring over any other business-value generating(refering the blog post) change, then that would surely help.

    Thanks,

    Nitin

  • Sonik Chopra
    By Sonik Chopra  ~  3 years ago
    reply Reply

    Hi Mukesh

    This will be very useful for our audience. I am just curious if you'll be able to cover all of this in 20 mins as you are touching on quite a few topics. I would appreciate if you can shed some light on the presentation mode and alaborate a bit more on your thoughts

     

    • Mukesh Bhangria
      By Mukesh Bhangria  ~  3 years ago
      reply Reply

      Thanks Sonik for your comment. I have updated it to 45 minutes. I can mark it to 'workshop' if people are interested.

      My basic flow would be to start with high overview why we are not inclined to refactor (Time crunch, regression, management etc.). Then a bit deeper into What, Why, How etc..

      We'll move closure to developers' side and for high level implementation. I can provide some tasks/examples (depending upon whether talk/workshop) for the audience. I have not made presentation yet.

      Let me know, if you need more specific details.

      On a side note, Naresh Jain took our workshop on TDD & Refactoring last year. I was naive at that time but started following those religiously and improved upon my productivity.

      I believe this experiece can be useful to whole Agile community.

       


  • Naresh Jain
    Naresh Jain
    Founder
    ConfEngine.com
    schedule 3 years ago
    Sold Out!
    45 mins
    Workshop
    Advanced

    As the popularity of Agile methods have grown, so have the misconceptions or myths associated with Agile also grown. These myths get even more glorified when we talk about them in the offshore or distributed context. And to make matters worse, you can throw in a fixed-price contract spanner into the engine.

    Worry not! In this fun-filled activity, we'll collect facts from the participants that they believe are true and then we'll declare them as confirmed or busted after an interactive (heated) discussion.

  • Corey Haines
    Corey Haines
    CTO
    Wavetable
    schedule 3 years ago
    Sold Out!
    45 mins
    Tutorial
    Beginner

    Everyone has acronyms, mnemonics, and a list of rules to guide their everyday software design. In order to get the most out of these age-old gems, one needs to deliberately practices them. Rules are a good way to remind ourselves of these gems.

    Corey Haines emphasies his design guidelines in form of the "4 Rules of Simple Design." Attend this talk to understand the four rules and their importance in everyday programming.

  • Liked Corey Haines
    keyboard_arrow_down

    Stories from 10 Years of Extreme Programming

    Corey Haines
    Corey Haines
    CTO
    Wavetable
    schedule 3 years ago
    Sold Out!
    45 mins
    Talk
    Intermediate

    10 years ago I was introduced to Extreme Programming. Since then, I've been an avid practitioner, applying the techniques and values to my life as a software developer. Over that time, I've bounced between many extremes, learning and reflecting on the value that I get when building systems both for myself and for others.

    In this talk, I'll share some of those learnings and how my life as a software developer has changed with the times.

  • Liked Victoria Schiffer
    keyboard_arrow_down

    Agile Coaching? Sure thing! What about Life Coaching in Agile Thinking?

    Victoria Schiffer
    Victoria Schiffer
    Agile Coach
    SEEK
    schedule 3 years ago
    Sold Out!
    45 mins
    Talk
    Beginner

    I love being around awesome people, who build great products customers desire. 
    I love learning from and together with these amazing minds. 
    I love creating the right environment for teams to flourish. 
    I love change, and learning from new experiences. 
    I love working in Agile environments.

    How about you? 
    I bet there are some elements of this list why you're in Agile, too. And you can probably add even more elements to it.

    The Agile Manifesto states amongst others individuals and interactions, customer collaboration and responding to change.

    In our everyday life doing Agile we already respect these aspects in many ways. 
    But do we practice what we preach as best we can?

    I'd like to challenge your current way of thinking about people and processes. 
    I'd like to challenge you to focus on you, before you focus on others. 
    I'd like to challenge your current way of reflecting. 
    I'd like to inspire you to go different ways. 
    I'd like to inspire you to inspire others.

    In Agile we're already good in improving our processes and creating well performing teams and hence building the right things in the right way. And in the Agile Manifesto's communication and collaboration piece we can even get better.
    "You have not yet reached the limit of what you're capable of!" means we can always further improve. And we do follow this idea in our Agile processes, too, through continuous feedback (Retrospectives) and improvement.

    And why not take it even further? Why not go "Beyond Agile"?!

    Here's where aspects of Life Coaching come in handy: through also understanding and improving ourselves (how do we interact with people due to how we perceive our environment) we will even further improve communication and collaboration.

    Life Coaches believe our clients know the answer. And even if Agile Coaching is slightly different than Life Coaching, I see it as very relevant in Agile Coaching, too. If we apply this in Agile, instead of giving our clients (team, colleagues) the answers, asking them powerful questions to help them be more aware of what's happening at the moment, they will find their answer for it and will have a much better commitment to making the change for themselves, their teams and the company. It's not for us to TELL them what to do, but to ASK them what's going on for themselves. Here's where I see a huge chance for improvement.

    In my session I give lots of examples on how to link Life Coaching ideas to our Agile work environments. I've given the session at LAST Conference Melbourne and at the Agile Coaching Circles Meetup Melbourne. The audience was engaged and the attendees were very happy about having some new ideas on how to improve their daily work life.

    Come along to be inspired by Life Coaching and thus to benefit our Agile Thinking!

  • Liked Naresh Jain
    keyboard_arrow_down

    Scaling XP Practices inside your organization using Train-the-Trainer Model

    Naresh Jain
    Naresh Jain
    Founder
    ConfEngine.com
    schedule 3 years ago
    Sold Out!
    90 mins
    Workshop
    Advanced

    How do you effectively scale skill-based, quality training across your organization?

    Over the years, I've experimented with different ideas/models to scaling skill-based training across an organization. In the last 4 years, I've pretty much settled down on the following model. Its very useful when mentoring teams on skills like Test-Drive-Development (TDD), Behavior-Driven Development (BDD), Product Discovery, Writing User Stories, Evolutionary Design, Design Patterns, Problem Solving, etc. I've successfully implemented this model at some very prominent fortune 500 enterprises.

    The goal of this workshop is to explore what other successful models organized have used to scale skill-based training in their organization.

  • Liked Daniel Zen
    keyboard_arrow_down

    Agile Engineering Javascript with Jasmine & AngularJS, Karma & Jenkins

    Daniel Zen
    Daniel Zen
    CEO
    Zen Digital
    schedule 3 years ago
    Sold Out!
    90 mins
    Tutorial
    Intermediate

    Agile & Test Driven Development of frontend JavaScript User Interface code is often passed over using the excuse that the UI code is "declarative" (What you see is what you get) and therefore does not 'need' to be tested. Others, will dismiss testing frontend AJAX code as too difficult to maintain or unnecessary because it is only important in context with the server. We will show how these misconceptions are false. 

    We will cover several popular JavaScript tools and technologies that make Agile frontend web development easy. We will show how these front end technologies cannot only be functionally tested, but Unit Tested. If time is available will cover Continuous Integration, Dependency Injection, & Mock objects.  

    By including your front-end code in your automated testing process you can prevent the inclusion of bugs that are usually only caught with manual testing.

  • Naresh Jain
    Naresh Jain
    Founder
    ConfEngine.com
    schedule 3 years ago
    Sold Out!
    45 mins
    Demonstration
    Intermediate

    "Release Early, Release Often" is a proven mantra and many companies have taken this one step further by releasing products to real users with every commit a.k.a Continuous Deployment (CD).

    Over the years, I've built many web/infrastructure products, where we've effectively practiced CD. However at Edventure Labs, when we started building iPad games, we realized there was no easy was to practice CD, esp. given the fact that Apple review takes a few days.

    Our main question was: As mobile app developers, how should we architect/design our apps for CD?

    We were a young startup, learning new behavior about our users (kids aged 5-8) everyday. We could not afford any delay in releasing latest, greatest features to our users. To solve this problem, I believe we've built an innovative solution to enable any mobile app developer to achieve CD.

    If you are building real products, which have platform/3rd-party dependencies and you want to practice CD, this session is for you.

  • 45 mins
    Experience Report
    Intermediate

    Agile processes are the new order of IT implementations. These talk will elaborate on our experience and learnings during agile process implementation at Walmart. 

    We will touchupon following 3 key areas and our learnings that helped us scale agile in large enterprises.

    • Process Visualization - Our learnings related to visualization of existing processes and practices and how it helped us identify signals from noise

    • Product Backlog Elaboration - In a complex and large programs product backlog management and role of product owner needs to be revisited.

    • Team Working Agreement - This is particulary crucial for scaling agile as dependency management is one of the key aspects of enterpsie agile implementation.

    We will conclude with our key learning of how processes needs to be continuously evolved in large scale implementation.

  • Liked Ellen Grove
    keyboard_arrow_down

    Build Your Dreams: User Requirements Gathering with LEGO Serious Play

    90 mins
    Workshop
    Beginner

    Let your hands be the search engine for your brain! LEGO® Serious Play® is a powerful thinking, communicating and problem solving technique that can help you and your team do serious work through structured play activities using a popular and playful 3D modeling toy. Through a facilitated process of building models that, storytelling and reflection, every person at the table is engaged and actively participating in the discussion, whether the topic is individual aspirations, team relationships, developing a new product or solving a wicked organizational problem. Everyone builds and everyone tells their story – all participants have equal opportunity to put their own points of view on the table, unlocking new perspectives and exposing the answers that are already in the room.  LEGO Serious Play has been used successfully for team-building and problem solving in a variety of organizations, from NASA to RBC to academic settings and public utilities.  

    This presentation provides a hands-on introduction to LEGO Serious Play, so that you can experience firsthand how using LEGO to do real work unleashes creativity and enables meaningful conversations in a very short time. We will explore how to use this playful technique to collaboratively elicit information about user requirements and strategic design issues using the open source User Requirements with Lego methodology developed by a team at the University of Lugano, Switzerland.  This approach is particularly suited to Agile teams that want to get team members and stakeholders sharing their different perspectives on common goals in an open and light-weight manner.

  • Liked Jason Yip
    keyboard_arrow_down

    Think Like an Agilist: Deliberate practice for Agile culture

    Jason Yip
    Jason Yip
    Principal Consultant
    ThoughtWorks
    schedule 3 years ago
    Sold Out!
    90 mins
    Workshop
    Intermediate

    If I say, culture is important to adopting Agile, most people will just agree without even thinking too much about it.  But what is meant by "culture"?  Why is it important?

    Culture is not typical behaviour; it is not what we say we value (but don't actually do).  Culture is our basic assumptions of how things work.  Culture is the logic we use to think through and respond to any particular situation.

    If you imagine a pyramid, Agile practice and any other visible behaviour is on the top, stated or written Agile values and principles are in the middle, fundamental assumptions (aka culture) is at the base.

    My session is intended to expose people to the base of that pyramid.

    If culture is assumptions, then to understand Agile culture, we need to understand the basic assumptions of Agile.  To do this, I have created an approach called "Think Like an Agilist" that both exposes how we think through an "Agile situation" and allows us to deliberately practice "Agile culture".

    The general idea is that I won't just talk about Agile culture and values, what I'll call "culture theatre", but rather expose people, who nominally consider themselves part of the Agile culture, to their underlying thought processes and assumptions, given a relatively difficult scenario.  Those thought processes and assumptions are the essence of culture (reference Edgar H. Schein).  What is interesting is noting when the thought processes and assumptions are different which indicates that there is a different culture at play.  What I've noticed is that this difference is common between novice vs expert Agilists.

    Note that it isn't even about analyzing vs doing it mechanically but more about exposing what assumptions are being used to respond.

    NOTE: I will be updating the attached slides as when I created them, I was framing it more as "doctrine" rather than "culture", defined as fundamental assumptions"

  • Liked Phil Abernathy
    keyboard_arrow_down

    The Sixth Force

    45 mins
    Talk
    Intermediate

    Over the last 2 years, in small pockets all over the world, people have been experimenting with the use of Agile and Lean in formulating and executing corporate strategy.

    The finding will astound you and lay the foundations for what may become the next wave of ‘Agilean’ transformations, thus paving the way for vertically transformed ‘Agilean’ organisations that deliver outstanding profitability.

    The ‘Lean Startup’ mentality or ‘Management 3.0’ are tips of the iceberg in recent strategic thinking.

    This talk draws on experience and real life examples to outline how Agile and Lean, and not just Porter’s 5 forces, can be used effectively to not only formulate and execute corporate strategy but also to enable transformation throughout the organisation.

  • Liked Fiona Mullen
    keyboard_arrow_down

    Agile - An Australian Journey of Cultural Change

    45 mins
    Talk
    Beginner

    How did one of Australia's leading financial services organisation become the biggest Agile transformation story in the Southern hemisphere and what did we learn?

    The Suncorp Group leads in general insurance, banking, life insurance, superannuation and investment brands within Australia and New Zealand. The Group has 16,000 employees and relationships with nine million customers. It is a Top 20 ASX listed company with over $93 billion in assets.

    In 2007, we embarked on our Agile journey of cultural change. In this talk we will cover the strategy taken, the roadblocks we came across, the mistakes we made and the achievements along the way.

    You will learn how to tackle an Agile transformation, what to do and what NOT to do, where to start and what to expect and most of all what impact it will have, both negative and positive.

    Today Suncorp are seen as market leaders in Agile and are known globally for the Agile Academy http://www.agileacademy.com.au/agile/ which was designed for both staff and also the external market.

    The role of the Agile PMO, how to get infrastructure to work Agile, what about all those legal challenges, the cultural differences and the resistance to change? These are some of the learning we will share.

    There were challenges and successes and in this honest Aussie presentation will share with you both the highs and the lows.

  • Liked Andrea Heck
    keyboard_arrow_down

    Distributed Product Owner Team for an Agile Medical Development

    Andrea Heck
    Andrea Heck
    Agile Coach
    Siemens AG Healthcare
    schedule 3 years ago
    Sold Out!
    45 mins
    Case Study
    Advanced

    We are developing medical imaging and workflow software in an agile way with development teams distributed to several countries. One of the major challenges is how to set up and communicate within the Product Owner team. There we have to deal with the distribution, e.g., have the Product Owner either onsite with her peers or with her Scrum team, travelling, or with proxy. We need people who are good in two different fields of knowledge: medical and software development. As a third issues, the environment of the customers may be different in different countries.

    We have ramped up local Product Owners in different countries, have found local collaboration customers, and have developed a set of communication channels and workshops how to synchronize Product Owners in the team, share a common vision and backlog with their Scrum teams, and collaborate with customers locally and globally.

  • Prasanna Vaste
    Prasanna Vaste
    Business Analyst
    Thoughtworks
    schedule 3 years ago
    Sold Out!
    20 mins
    Experience Report
    Beginner

    On Agile projects we estimate user stories in order to allow team to

    1. 1. Track velocity
    2. 2. Decide scope for the Iteration
    3. 3. Help Prioritize stories
    4. 4. Help Release planning

    But most of the time we faced issues with estimation. It takes lot of time in estimating user stories, managers tend to relate estimate to number of days it will take to complete the story, in some teams estimate is equal to deadline. Most of the teams which use story points to estimate the work face these issues. This results in lack of confidence on development team when stories are taking more time to complete.

    Here I am going to talk about better alternative for both the suppliers of software products (financially and ethically) and their customers (internal and external). This alternative is being used in real companies delivering to real customers with great effect where team uses count of stories completed in an Iteration as measure of progress. Will talk about how this alternative can be used to track velocity, prioritize stories, planning Iteration and for release planning.

    I will share some exmples from my past projects where team did not use story points/velocty but used count of stories completed in Iteration to measure progress and also as best indicator of future performance.

  • Liked Roy Nuriel
    keyboard_arrow_down

    The Quality Assurance Journey - From Waterfall to Continuous Delivery

    45 mins
    Case Study
    Intermediate

    In the past several years we have seen more and more organization taking the decision and moving their development divisions to adopt Agile methodology. In most cases the change starts with a POC of a new and – in most cases – small project that validates the ability of the organization to make the shift to Agile. In many cases the development team takes the lead: changing the process, moving to unified teams, selecting which Agile practice to adopt, etc.

    In this session I will share how we made the shift, while focusing on the change in our quality process.

    As an R&D group that develops an Agile solution (HP Agile Manager), we wanted to get it right. We changed the way in which we develop software from waterfall to Agile, and built a process to support the teams in a complex and large enterprise. While previously we were accustomed to delivering releases in 1-2 year cycles, we now operate within a SaaS model where we update our production environment on a weekly basis. 

    We have experimented with the same process that our customers are going through and, as a result, we adapted the way our QA engineers work. In accordance with their new role, we gave them a new title – Dev Testers.

    Here are some of the dilemmas we faced:

    -          What are the differences between "Dev Tester" and "QA Engineer"?

    -          How can we measure quality in 2-week sprints?

    -          What needs to change when testing a SaaS solution that is delivered on a weekly basis?

    -          When and how should load testing be performed?

    -          Automated v. manual testing

    -          What testing should be part of the CI process?

    -          How do offshore Dev Testers take part in our Agile practices (e.g. daily meetings)?

    We dealt with all of these questions, and I would like to share the lessons we learned, our conclusions, and some of the challenges that we still face.

  • Martin Fowler
    Martin Fowler
    Chief Scientist
    ThoughtWorks
    schedule 3 years ago
    Sold Out!
    60 mins
    Keynote
    Intermediate

    In the last decade or so we've seen a number of new ideas added to the mix to help us effectively design our software. Patterns help us capture the solutions and rationale for using them. Refactoring allows us to alter the design of a system after the code is written. Agile methods, in particular Extreme Programming, give us a highly iterative and evolutionary approach which is particularly well suited to changing requirements and environments. Martin Fowler has been a leading voice in these techniques and will give a suite of short talks featuring various aspects about his recent thinking about how these and other developments affect our software development.

  • Liked Rae Abileah
    keyboard_arrow_down

    Engendering Justice: Women, War and Peace

    45 mins
    Keynote
    Beginner

    One in three women will be raped or beaten in her lifetime. Half of the seven billion global population are women so that means one billion women alive now will, or have been, beaten or raped or beaten. Women and children are disproportionately affected by war and occupation as well. And yet numerous studies illustrate how uplifting women's work and leadership can strengthen the whole society and economy. Women are at the forefront of global campaigns challenging militarism and violence, and working to redirect resources into health care, education, green jobs and other life-affirming activities. What can we learn from these women and their successes thus far? How can the technology sector support this crucial work? How do these social movements stay agile to rapidly respond to breaking news while building a long-term progressive movements for deeper social, economic and environmental justice? As Arundhati Roy said, "Another world is not only possible, she is on her way. On a quiet day, I can hear her breathing." In this talk, Rae Abileah will share visionary examples of women-led work for peace and justice and explore the paradigm shift needed for equality, human rights, and justice for all.

  • Todd Little
    Todd Little
    Executive Consultant
    Accelinnova
    schedule 3 years ago
    Sold Out!
    60 mins
    Keynote
    Intermediate

    A major challenge in agile development is the ability of test teams to keep pace with ongoing development while simultaneously ensuring that new development has not created regression failures. This case study from Halliburton shows how together with two globally distributed outsourcing partners they developed a comprehensive test automation strategy for their agile teams that effectively leveraged both in house and outsourced activities. This approach resulted in a significant quality improvement from prior releases.

  • Ash Maurya
    Ash Maurya
    Founder
    Spark59
    schedule 3 years ago
    Sold Out!
    60 mins
    Keynote
    Intermediate

    Most products fail. Not because we fail to build what we set out to build, but because we waste time, money, and effort building the wrong product.

    In this talk, I'll share our lean product development process that utilizes continuous customer feedback loops to ensure you don't go astray and instead build products people (will) want.

    What you'll learn:

    - How to track your your feature lifecycle on a validated learning kanban board
    - How to use qualitative testing techniques for early validation during the design and test phases
    - And then follow up with cohort based quantitative metrics to verify you have built something people wanted.

  • Liked Anna Obukhova
    keyboard_arrow_down

    The SCRUM and the willpower: how neuroscience can boost your productivity

    Anna Obukhova
    Anna Obukhova
    Agile Coach
    Luxoft
    schedule 3 years ago
    Sold Out!
    45 mins
    Talk
    Intermediate

    Willpower is the force that is between the brain activity (I want to do this or I need to do this) and the action itself (start coding). If there is not enough willpower, people find it difficult to start any activity (especially that involves
    decision making).


    What is the standard approach when you feel tired and find it difficult to concentrate? Take some coffee (but latest research shows that coffee depletes the brain activity, even when body has more energy), take some sweets (but sugar ends quickly and gives even more exhaustion to the body)? These widely used strategies generally do not work, and in long-term even add harm to the body and brain.


    The willpower is not endless (so-called muscle theory of willpower), it can be saved, it can be trained, there are approaches how to keep the willpower level high. To keep the willpower (and thus, productivity) on the high level, people should know and use different approaches that lay in the field on the social and cognitive science.


    There are a lot of evidences that SCRUM improves the developer’s productivity in terms of speed of development, code quality, and accuracy of design. Unfortunately mainly all recommendations from SCRUM coaches look like “believe me, if you do this, you will have better velocity”. Yes, it works. But why does it work?


    Sometimes SCRUM does not give such great results even when main elements are in place. The question “Why” and “What makes the difference” is here again.


    I will describe the model of relationship between the willpower related brain metabolism on very low level (specific amino acid cycle) and the SCRUM practices. I can prove that SCRUM addresses the productivity of the people’s brain using 3 different flows simultaneously. There are several tips that make these productivity flows working or not. You can make Agile productive, you can have non-productive Agile. I will show you where the difference is.


    Overall there are 10 productivity tips that can be put into 3 flows.


    As the outcome of this session, Agile coaches, and all people who can change the process (in fact that is any team member) will review their SCRUM: does the way they have it improve the productivity or they are losing all the power? The changes are cheap, the outcome can be huge.