#ci/cd
7 posts

Continuous testing - creating a testable CI/CD pipeline

For continuous testing, focus on confidence, implementation, maintainability, monitoring and speed.
Read more

Continuous testing - creating a testable CI/CD pipeline

For continuous testing, focus on confidence, implementation, maintainability, monitoring and speed (CIMMS):

  1. For greater confidence, pair testers with developers as they write code to review unit tests for coverage and to add service tests for business logic and error handling.
  2. To implement, use tools that support rapid feedback from fast running of repeatable tests. For service-level tests, inject specific responses/inputs into Docker containers or pass stubbed responses from integration points. For integration tests, run both services in paired Docker containers within the same network. Limit full-environment tests.
  3. Ensure tests are maintained and up to date. Create tests with human-readable logging, meaningful naming and commented descriptions.
  4. To monitor, use testing tools that integrate into CI/CD pipeline tools to make failures/successes visible and even send emails out automatically. In production, labeling logs to trace a user’s path and capturing system details of the user environment allows easier debugging.
  5. For speed, keep the test suite minimal. Let each test focus on only one thing and split tests to run in parallel if need be. Segregate to test only for changed areas and ignore those with no cross-dependencies.
  • Avoid automating everything. Run manual exploratory tests at each stage to understand new behaviours and determine which of those need automated tests.
  • When pushing to a new environment, test environmental rollback. Reversing changes should not impact users or affect data integrity. Test the rollout process itself for production and run smoke tests. Continue to monitor by running known error conditions and ensure monitoring captures those with sufficient information for easy debugging.

Full post here, 7 mins read

How to measure the reliability of your software throughout the CI/CD workflow

Look beyond log files and testing to determine quality of code: set up advanced quality gates to block problematic code from passing to the next stage and use feedback loops to inform more comprehensive testing.
Read more

How to measure the reliability of your software throughout the CI/CD workflow

  • In addition to CI/CD, you should consider incorporating continuous reliability in the workflow. This may mean more focus on troubleshooting than on writing code.
  • Consider whether to automate every step, or even whether some steps should be automated more than others.
  • Look beyond log files and testing to determine quality of code: set up advanced quality gates to block problematic code from passing to the next stage and use feedback loops to inform more comprehensive testing.
  • In addition to log aggregators and performance monitoring tools, get a more granular understanding of app quality by ensuring you can access the source code, variable state and stack trace at the time of an error. Aggregate this data across the app, library, class, deployment or another boundary for an insight into the functional quality of the code.
  • Based on this data, you can categorise known, reintroduced and unknown errors, classify events, understand frequency and failure rates, enabling you to write more comprehensive tests for development and pre-production environments alike, driving the higher code quality.

Full post here, 6 mins read

Modernizing your build pipelines

Keep your pipeline highly visual and avoid over-abstraction. Visualization makes builds easy to understand and allows failed builds to be traced back quickly.
Read more

Modernizing your build pipelines

  • A high-quality pipeline must be fast. This needs quick feedback. To achieve this, let your CI tool parallelize all tasks that don’t have mutual dependencies and avoid running multiple checks together.
  • Have pipelines reflect in the code and call shell scripts that also work locally for easier testing before pushing to deploy, enabling a faster feedback loop.
  • To ensure your pipeline is reliable and reproducible, use containers to run each task in isolation and build the containers within the pipeline, a fresh container at each step.
  • While a persistent workspace saves time, it can build in flakiness, for which a good tradeoff may be improving speed by caching dependencies instead of downloading them each time.
  • Keep your pipeline highly visual and avoid over-abstraction. Visualization makes builds easy to understand and allows failed builds to be traced back quickly.
  • Your system must be scalable across multiple pipelines. Avoid duplication (slows the pipelines down) and parametrize tasks instead, so that you configure them by passing variables, and build a library of tasks that lets you reuse code across pipelines, while also reducing coupling between tasks and pipelines.

Full post here, 10 mins read

Happy customers, quality code: the new trends in software development

It takes an average of 3.3 different tools to know the real status of the project and teams use an average of 4.3 tools to move code from development to production. 57% developers reported fewer bugs or outages by adopting CI/CD solutions.
Read more

Happy customers, quality code: the new trends in software development

Results from Atlassian’s research with 500 software developers & IT professionals, conducted at the beginning of 2019.

  • It takes an average of 3.3 different tools to know the real status of the project and teams use an average of 4.3 tools to move code from development to production.
  • 71% of software & IT teams who use a microservices structure believe it’s easier to test or deploy features.
  • 57% developers reported fewer bugs or outages by adopting CI/CD solutions.
  • Feature flagging reduces risks while rolling out features to customers. 63% developers who use feature flagging reported better testing of features or higher quality software.
  • Outcome-driven development is shifting the focus away from feature delivery speed to the customer value features creates.

Full post here, 4 mins read

Tips and tricks for scalable CI/CD flow

Define your VCS (version control system) flow, with help from Git Flow or Github Flow. When using a complicated manual release process, use tags to trigger production releases.
Read more

Tips and tricks for scalable CI/CD flow

Tips to help you scale up CI/CD flows for big projects if you are using Docker and Kubernetes:

  • Define your VCS (version control system) flow, with help from Git Flow or Github Flow.
  • When using a complicated manual release process, use tags to trigger production releases.
  • Adapt your Git flow for the number of environments you have.
  • Set up notification channels to track all CI flow processes.
  • Keep Docker images simple. Avoid passing env variables. Use the Run command or let Kubernetes handle this.
  • Define a Docker image naming convention - for development and UAT, where there is no rollback, you can use branch names as tags so the previous image is overridden; for production, tag with the release version number.
  • Execute database migrations as a separate step outside the Dockerfile.
  • Avoid private libraries and submodules.

Full post here, 5 mins read