DZone
DevOps Zone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
  • Refcardz
  • Trend Reports
  • Webinars
  • Zones
  • |
    • Agile
    • AI
    • Big Data
    • Cloud
    • Database
    • DevOps
    • Integration
    • IoT
    • Java
    • Microservices
    • Open Source
    • Performance
    • Security
    • Web Dev
DZone > DevOps Zone > Why You Should Integrate Frequently

Why You Should Integrate Frequently

Continuous Integration requires that you have the right tests and a testable system, but given these things, it can be a cost-effective way to build and maintain.

David Bernstein user avatar by
David Bernstein
CORE ·
Nov. 23, 16 · DevOps Zone · Opinion
Like (6)
Save
Tweet
3.67K Views

Join the DZone community and get the full member experience.

Join For Free

You want to create a build system that’s so easy to use that it’s invisible to the developers on the team. It should be able to be invoked with a single click and should automatically build, test, and validate new code that’s added to the system.

Teams that are first adopting Continuous Integration sometimes ask me how often their developers should integrate their code and I say: “Tell your developers to integrate at least once a day,” but this is a little bit of a trick.

It often turns out that the last person to integrate that day ends up with a huge burden of failing tests so they wind up not getting home in time for dinner.

Instead, developers learn quickly that whenever they have even the slightest bit of functionality to add to the system they do it. By integrating code a little piece of a time, you take a very difficult problem and make it so small it’s barely noticeable. If something does go wrong, it’s easy to remedy because you know the problem was introduced between now and the last time you integrated.

The very best developers I know integrate all the time. When I look at their server logs, I see them running their tests on average of about three times a minute. This is an enormous amount of feedback they’re getting. Think about how much more successful we can be with that level of feedback coming into us all the time as we’re building a system.

Continuous Integration does require that you have the right tests and requires having a testable system, but given these things, Continuous Integration can become a cost-effective way of building and maintaining a system.

I like my builds to happen in a matter of seconds and usually, if a system is well-partitioned and architected, then the dependencies for the code I’m working on shouldn’t be huge, and the dependent unit tests can run fast.

One key to making this work is to have a well-defined dependency tree for the build. It often reflects the nature of an architecture, so cleaning up and improving the dependency tree also improves architecture.

Continuous Integration is a core prerequisite to emergent design. It’s far safer than doing emergent design with code under test. It’s valuable to write automated tests for code whose design is going to evolve.

We want to make it so that clicking the build button is so easy and uneventful we do it all the time.

Integration CI/CD unit test

Published at DZone with permission of David Bernstein, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Is Your Code DRY or WET?
  • Writing Beautiful, Optimized, and Better .NET Code With NDepend Static Analysis
  • Getting Started With RSocket Kotlin
  • Event-Driven Hello World Program

Comments

DevOps Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • MVB Program
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends:

DZone.com is powered by 

AnswerHub logo