SlideShare uma empresa Scribd logo
1 de 21
Continuous Integration Lior Tal Automation Developer
Continuous Integration Automated Builds Tools DVCS (Git) Agenda
Continuous Integration How good is our code? I think it’s pretty good… Does the code work? I tested it, it seems to do what it should… Does the code have bugs? I hope not…
Continuous Integration Need to simplify complex integration of code Need a good criteria for measuring our code quality Need to have “Self-testing” code
“a software development practice where members of a team integrate their work frequently, leading to multiple integrations per day. Each integration is verified by an automated build (including test) to detect integration errors as quickly as possible.  Continuous Integration
Developer checks in new code An automated build is kicked off with all latest code changes Unit tests and [optional] other tools are executed Developer receives a notification if the build succeeded or failed [optional] Failing commits are rejected from the source code repository Continuous Integration
The code should build directly from source control The code should be built in a single automated command This makes it easier in multiple scenarios: New developer joins the team Code is built automatically on a build server Automated Builds
Build script can be created using standard technologies MSBuild Batch file Multiple build configurations should be defined “Small” build that runs on every check in Should be very fast “Big” build that runs nightly Can have a bigger scope (build MSI, run integration tests) Automated Builds
Many tools can be integrated into the build process Some examples (.NET): Code Coverage – Coverage (in %) by unit tests. Code Duplications – find duplicated code Code Analysis StyleCop – Find styling errors in code FXCop – Static code analysis Tools
Tools – Code Coverage
Tools – Code Coverage
Define a set of styling rules: These can be run from the IDE or from a build script Show warnings/errors when compiling: Tools - StyleCop
Many tools can be integrated into the build process Some examples (.NET): Code Coverage – Coverage (in %) by unit tests. Code Duplications – find duplicated code Code Analysis StyleCop – Find styling errors in code FXCop – Static code analysis Tools – FXCop
Older VCS tools are centralized (central server model) Subversion, ClearCase Centralized tools suffer from a few issues: Network latency (server needed for most operations). Submitting “half-ready” code can break other people’s work. DVCS (Git)
Many modern VCS tools are distributed This means a central server is optional Each developer gets a copy of the entire repository A central server can still be setup Used as a sync point for team members DVCS (Git)
Git offers a command line tool (comes from Linux) On Windows: Shell Extension Visual Studio integration using plugins DVCS (Git)
Git Workflow Centralized Workflow
Git Workflow Integration-Manager
CI Implementation #1 CI Server Source Control (Git) TeamCity Build Agent CI Build Nightly Build
CI Implementation #1 What we gained: Basic framework for more complicated tasks Source control contains a “clean” copy of the code Fast notification on build issues Starting to incorporate basic unit tests Installer (.MSI) creation is automatic Using a modern source control system (Git)
CI Implementation #2 CI Server Git CI Build Build Agent Build Agent Build Agent … Nightly Build VM Server Win7 x64 Win7 Win XP …

Mais conteúdo relacionado

Mais procurados

Serverless Architecture Patterns - Manoj Ganapathi - Serverless Summit
Serverless Architecture Patterns - Manoj Ganapathi - Serverless SummitServerless Architecture Patterns - Manoj Ganapathi - Serverless Summit
Serverless Architecture Patterns - Manoj Ganapathi - Serverless SummitCodeOps Technologies LLP
 
Modern Tools for Building Progressive Web Apps
Modern Tools for Building Progressive Web AppsModern Tools for Building Progressive Web Apps
Modern Tools for Building Progressive Web AppsAll Things Open
 
Infrastructure as Code
Infrastructure as CodeInfrastructure as Code
Infrastructure as CodeLeandro Rosa
 
Infrastructure as Code
Infrastructure as CodeInfrastructure as Code
Infrastructure as CodeMatt Cowger
 
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHERE
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHEREECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHERE
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHEREEuropean Collaboration Summit
 
ASP.NET Core Demos
ASP.NET Core DemosASP.NET Core Demos
ASP.NET Core DemosErik Noren
 
Azure DevOps for the Data Professional
Azure DevOps for the Data ProfessionalAzure DevOps for the Data Professional
Azure DevOps for the Data ProfessionalSarah Dutkiewicz
 
ASP.NET Core Demos Part 2
ASP.NET Core Demos Part 2ASP.NET Core Demos Part 2
ASP.NET Core Demos Part 2Erik Noren
 
Debugging your Way through .NET with Visual Studio 2015
Debugging your Way through .NET with Visual Studio 2015Debugging your Way through .NET with Visual Studio 2015
Debugging your Way through .NET with Visual Studio 2015Ido Flatow
 
How to setup a development environment for ONAP
How to setup a development environment for ONAPHow to setup a development environment for ONAP
How to setup a development environment for ONAPVictor Morales
 
Training And Serving ML Model Using Kubeflow by Jayesh Sharma
Training And Serving ML Model Using Kubeflow by Jayesh SharmaTraining And Serving ML Model Using Kubeflow by Jayesh Sharma
Training And Serving ML Model Using Kubeflow by Jayesh SharmaCodeOps Technologies LLP
 
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless Summit
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless SummitBuild a Chatbot in Ten Minutes - Dave Kerr - Serverless Summit
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless SummitCodeOps Technologies LLP
 
Netflix Architecture and Open Source
Netflix Architecture and Open SourceNetflix Architecture and Open Source
Netflix Architecture and Open SourceAll Things Open
 
DAIS Europe Nov. 2020 presentation on MLflow Model Serving
DAIS Europe Nov. 2020 presentation on MLflow Model ServingDAIS Europe Nov. 2020 presentation on MLflow Model Serving
DAIS Europe Nov. 2020 presentation on MLflow Model Servingamesar0
 
Serverless in azure
Serverless in azureServerless in azure
Serverless in azureVeresh Jain
 

Mais procurados (19)

Serverless Architecture Patterns - Manoj Ganapathi - Serverless Summit
Serverless Architecture Patterns - Manoj Ganapathi - Serverless SummitServerless Architecture Patterns - Manoj Ganapathi - Serverless Summit
Serverless Architecture Patterns - Manoj Ganapathi - Serverless Summit
 
Modern Tools for Building Progressive Web Apps
Modern Tools for Building Progressive Web AppsModern Tools for Building Progressive Web Apps
Modern Tools for Building Progressive Web Apps
 
Infrastructure as Code
Infrastructure as CodeInfrastructure as Code
Infrastructure as Code
 
ONAP on Vagrant
ONAP on VagrantONAP on Vagrant
ONAP on Vagrant
 
Infrastructure as Code
Infrastructure as CodeInfrastructure as Code
Infrastructure as Code
 
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHERE
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHEREECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHERE
ECS19 - Daniel Neumann - AZURE FUNCTIONS 2.0 - RUNNING SERVERLESS EVERYWHERE
 
ASP.NET Core Demos
ASP.NET Core DemosASP.NET Core Demos
ASP.NET Core Demos
 
Azure DevOps for the Data Professional
Azure DevOps for the Data ProfessionalAzure DevOps for the Data Professional
Azure DevOps for the Data Professional
 
ASP.NET Core Demos Part 2
ASP.NET Core Demos Part 2ASP.NET Core Demos Part 2
ASP.NET Core Demos Part 2
 
Javantura v4 - Java and lambdas and streams - are they better than for loops ...
Javantura v4 - Java and lambdas and streams - are they better than for loops ...Javantura v4 - Java and lambdas and streams - are they better than for loops ...
Javantura v4 - Java and lambdas and streams - are they better than for loops ...
 
Debugging your Way through .NET with Visual Studio 2015
Debugging your Way through .NET with Visual Studio 2015Debugging your Way through .NET with Visual Studio 2015
Debugging your Way through .NET with Visual Studio 2015
 
How to setup a development environment for ONAP
How to setup a development environment for ONAPHow to setup a development environment for ONAP
How to setup a development environment for ONAP
 
Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
 
Training And Serving ML Model Using Kubeflow by Jayesh Sharma
Training And Serving ML Model Using Kubeflow by Jayesh SharmaTraining And Serving ML Model Using Kubeflow by Jayesh Sharma
Training And Serving ML Model Using Kubeflow by Jayesh Sharma
 
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless Summit
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless SummitBuild a Chatbot in Ten Minutes - Dave Kerr - Serverless Summit
Build a Chatbot in Ten Minutes - Dave Kerr - Serverless Summit
 
Netflix Architecture and Open Source
Netflix Architecture and Open SourceNetflix Architecture and Open Source
Netflix Architecture and Open Source
 
DAIS Europe Nov. 2020 presentation on MLflow Model Serving
DAIS Europe Nov. 2020 presentation on MLflow Model ServingDAIS Europe Nov. 2020 presentation on MLflow Model Serving
DAIS Europe Nov. 2020 presentation on MLflow Model Serving
 
Serverless in azure
Serverless in azureServerless in azure
Serverless in azure
 
Javantura v4 - Support SpringBoot application development lifecycle using Ora...
Javantura v4 - Support SpringBoot application development lifecycle using Ora...Javantura v4 - Support SpringBoot application development lifecycle using Ora...
Javantura v4 - Support SpringBoot application development lifecycle using Ora...
 

Destaque

Lessons Learned with Unity and WebGL
Lessons Learned with Unity and WebGLLessons Learned with Unity and WebGL
Lessons Learned with Unity and WebGLLior Tal
 
Speech-Enabling Web Apps
Speech-Enabling Web AppsSpeech-Enabling Web Apps
Speech-Enabling Web AppsMojo Lingo
 
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In Sight
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In SightFreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In Sight
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In SightMojo Lingo
 
Advanced Software Test Automation
Advanced Software Test AutomationAdvanced Software Test Automation
Advanced Software Test AutomationUnmesh Ballal
 
Sustainable Automation Frameworks by Kelsey Shannahan
Sustainable Automation Frameworks by Kelsey ShannahanSustainable Automation Frameworks by Kelsey Shannahan
Sustainable Automation Frameworks by Kelsey ShannahanQA or the Highway
 
Software Testing for International Students
Software Testing for International StudentsSoftware Testing for International Students
Software Testing for International Studentscristianoribeirosilva
 
Testing web services by Stan Jónsson
Testing web services by Stan JónssonTesting web services by Stan Jónsson
Testing web services by Stan JónssonQA or the Highway
 
Test Automation and Continuous Integration
Test Automation and Continuous Integration Test Automation and Continuous Integration
Test Automation and Continuous Integration TestCampRO
 
Scrum gathering Paris 2013 - test automation strategy for Scrum Projects
Scrum gathering Paris 2013 -  test automation strategy for Scrum ProjectsScrum gathering Paris 2013 -  test automation strategy for Scrum Projects
Scrum gathering Paris 2013 - test automation strategy for Scrum ProjectsEliane Collins
 
Distributed Testing Environment
Distributed Testing EnvironmentDistributed Testing Environment
Distributed Testing EnvironmentŁukasz Morawski
 
Make ruby talk to your users - literally
Make ruby talk to your users - literallyMake ruby talk to your users - literally
Make ruby talk to your users - literallyBhavin Javia
 
Continuous test automation
Continuous test automationContinuous test automation
Continuous test automationViresh Doshi
 
Victoria's Secret Angels Campaign
Victoria's Secret Angels CampaignVictoria's Secret Angels Campaign
Victoria's Secret Angels CampaignJohn White
 

Destaque (13)

Lessons Learned with Unity and WebGL
Lessons Learned with Unity and WebGLLessons Learned with Unity and WebGL
Lessons Learned with Unity and WebGL
 
Speech-Enabling Web Apps
Speech-Enabling Web AppsSpeech-Enabling Web Apps
Speech-Enabling Web Apps
 
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In Sight
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In SightFreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In Sight
FreeSWITCH, FreeSWITCH Everywhere, and Not A Phone In Sight
 
Advanced Software Test Automation
Advanced Software Test AutomationAdvanced Software Test Automation
Advanced Software Test Automation
 
Sustainable Automation Frameworks by Kelsey Shannahan
Sustainable Automation Frameworks by Kelsey ShannahanSustainable Automation Frameworks by Kelsey Shannahan
Sustainable Automation Frameworks by Kelsey Shannahan
 
Software Testing for International Students
Software Testing for International StudentsSoftware Testing for International Students
Software Testing for International Students
 
Testing web services by Stan Jónsson
Testing web services by Stan JónssonTesting web services by Stan Jónsson
Testing web services by Stan Jónsson
 
Test Automation and Continuous Integration
Test Automation and Continuous Integration Test Automation and Continuous Integration
Test Automation and Continuous Integration
 
Scrum gathering Paris 2013 - test automation strategy for Scrum Projects
Scrum gathering Paris 2013 -  test automation strategy for Scrum ProjectsScrum gathering Paris 2013 -  test automation strategy for Scrum Projects
Scrum gathering Paris 2013 - test automation strategy for Scrum Projects
 
Distributed Testing Environment
Distributed Testing EnvironmentDistributed Testing Environment
Distributed Testing Environment
 
Make ruby talk to your users - literally
Make ruby talk to your users - literallyMake ruby talk to your users - literally
Make ruby talk to your users - literally
 
Continuous test automation
Continuous test automationContinuous test automation
Continuous test automation
 
Victoria's Secret Angels Campaign
Victoria's Secret Angels CampaignVictoria's Secret Angels Campaign
Victoria's Secret Angels Campaign
 

Semelhante a Continuous integration

Continuous Integration and development environment approach
Continuous Integration and development environment approachContinuous Integration and development environment approach
Continuous Integration and development environment approachAleksandr Tsertkov
 
Hudson
HudsonHudson
Hudson8x8
 
Software engineering
Software engineeringSoftware engineering
Software engineeringbartlowe
 
Continuous integration and delivery for java based web applications
Continuous integration and delivery for java based web applicationsContinuous integration and delivery for java based web applications
Continuous integration and delivery for java based web applicationsSunil Dalal
 
devops ppt for hjs jsdjhjd hsdbusinees.pptx
devops ppt for hjs jsdjhjd hsdbusinees.pptxdevops ppt for hjs jsdjhjd hsdbusinees.pptx
devops ppt for hjs jsdjhjd hsdbusinees.pptxDeepakgupta273447
 
Part 2 improving your software development v1.0
Part 2   improving your software development v1.0Part 2   improving your software development v1.0
Part 2 improving your software development v1.0Jasmine Conseil
 
Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile Poonam Panday
 
Continuous Integration
Continuous IntegrationContinuous Integration
Continuous IntegrationXPDays
 
Using Continuous Integration To Ensure Project Health New
Using Continuous Integration To Ensure Project Health NewUsing Continuous Integration To Ensure Project Health New
Using Continuous Integration To Ensure Project Health Newbartlowe
 
Presentation 1 open source tools in continuous integration environment v1.0
Presentation 1   open source tools in continuous integration environment v1.0Presentation 1   open source tools in continuous integration environment v1.0
Presentation 1 open source tools in continuous integration environment v1.0Jasmine Conseil
 
Continous integration and delivery for single page applications
Continous integration and delivery for single page applicationsContinous integration and delivery for single page applications
Continous integration and delivery for single page applicationsSunil Dalal
 
Jenkins_1679702972.pdf
Jenkins_1679702972.pdfJenkins_1679702972.pdf
Jenkins_1679702972.pdfMahmoudAlnmr1
 
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...eleksdev
 
Intro to CI/CD using Docker
Intro to CI/CD using DockerIntro to CI/CD using Docker
Intro to CI/CD using DockerMichael Irwin
 
Delivering Quality Software with Continuous Integration
Delivering Quality Software with Continuous IntegrationDelivering Quality Software with Continuous Integration
Delivering Quality Software with Continuous IntegrationAspire Systems
 
Smart development environments
Smart development environmentsSmart development environments
Smart development environmentsWojciech Sznapka
 
Building a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP appsBuilding a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP appsJuan Manuel Torres
 

Semelhante a Continuous integration (20)

Continuous Integration and development environment approach
Continuous Integration and development environment approachContinuous Integration and development environment approach
Continuous Integration and development environment approach
 
Hudson
HudsonHudson
Hudson
 
Software engineering
Software engineeringSoftware engineering
Software engineering
 
Continuous integration and delivery for java based web applications
Continuous integration and delivery for java based web applicationsContinuous integration and delivery for java based web applications
Continuous integration and delivery for java based web applications
 
devops ppt for hjs jsdjhjd hsdbusinees.pptx
devops ppt for hjs jsdjhjd hsdbusinees.pptxdevops ppt for hjs jsdjhjd hsdbusinees.pptx
devops ppt for hjs jsdjhjd hsdbusinees.pptx
 
Part 2 improving your software development v1.0
Part 2   improving your software development v1.0Part 2   improving your software development v1.0
Part 2 improving your software development v1.0
 
Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile Lets talk about CI CD Pipeline in Agile
Lets talk about CI CD Pipeline in Agile
 
Continuous Integration
Continuous IntegrationContinuous Integration
Continuous Integration
 
Using Continuous Integration To Ensure Project Health New
Using Continuous Integration To Ensure Project Health NewUsing Continuous Integration To Ensure Project Health New
Using Continuous Integration To Ensure Project Health New
 
Presentation 1 open source tools in continuous integration environment v1.0
Presentation 1   open source tools in continuous integration environment v1.0Presentation 1   open source tools in continuous integration environment v1.0
Presentation 1 open source tools in continuous integration environment v1.0
 
Continous integration and delivery for single page applications
Continous integration and delivery for single page applicationsContinous integration and delivery for single page applications
Continous integration and delivery for single page applications
 
Build Time Hacking
Build Time HackingBuild Time Hacking
Build Time Hacking
 
Enter the Team City
Enter the Team CityEnter the Team City
Enter the Team City
 
Jenkins_1679702972.pdf
Jenkins_1679702972.pdfJenkins_1679702972.pdf
Jenkins_1679702972.pdf
 
jenkins.pdf
jenkins.pdfjenkins.pdf
jenkins.pdf
 
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...
Continuous Delivery concept overview. Continuous Integration Systems. DevOps ...
 
Intro to CI/CD using Docker
Intro to CI/CD using DockerIntro to CI/CD using Docker
Intro to CI/CD using Docker
 
Delivering Quality Software with Continuous Integration
Delivering Quality Software with Continuous IntegrationDelivering Quality Software with Continuous Integration
Delivering Quality Software with Continuous Integration
 
Smart development environments
Smart development environmentsSmart development environments
Smart development environments
 
Building a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP appsBuilding a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP apps
 

Último

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?XfilesPro
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphNeo4j
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAndikSusilo4
 

Último (20)

Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?How to Remove Document Management Hurdles with X-Docs?
How to Remove Document Management Hurdles with X-Docs?
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge GraphSIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & ApplicationAzure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
 

Continuous integration

  • 1. Continuous Integration Lior Tal Automation Developer
  • 2. Continuous Integration Automated Builds Tools DVCS (Git) Agenda
  • 3. Continuous Integration How good is our code? I think it’s pretty good… Does the code work? I tested it, it seems to do what it should… Does the code have bugs? I hope not…
  • 4. Continuous Integration Need to simplify complex integration of code Need a good criteria for measuring our code quality Need to have “Self-testing” code
  • 5. “a software development practice where members of a team integrate their work frequently, leading to multiple integrations per day. Each integration is verified by an automated build (including test) to detect integration errors as quickly as possible. Continuous Integration
  • 6. Developer checks in new code An automated build is kicked off with all latest code changes Unit tests and [optional] other tools are executed Developer receives a notification if the build succeeded or failed [optional] Failing commits are rejected from the source code repository Continuous Integration
  • 7. The code should build directly from source control The code should be built in a single automated command This makes it easier in multiple scenarios: New developer joins the team Code is built automatically on a build server Automated Builds
  • 8. Build script can be created using standard technologies MSBuild Batch file Multiple build configurations should be defined “Small” build that runs on every check in Should be very fast “Big” build that runs nightly Can have a bigger scope (build MSI, run integration tests) Automated Builds
  • 9. Many tools can be integrated into the build process Some examples (.NET): Code Coverage – Coverage (in %) by unit tests. Code Duplications – find duplicated code Code Analysis StyleCop – Find styling errors in code FXCop – Static code analysis Tools
  • 10. Tools – Code Coverage
  • 11. Tools – Code Coverage
  • 12. Define a set of styling rules: These can be run from the IDE or from a build script Show warnings/errors when compiling: Tools - StyleCop
  • 13. Many tools can be integrated into the build process Some examples (.NET): Code Coverage – Coverage (in %) by unit tests. Code Duplications – find duplicated code Code Analysis StyleCop – Find styling errors in code FXCop – Static code analysis Tools – FXCop
  • 14. Older VCS tools are centralized (central server model) Subversion, ClearCase Centralized tools suffer from a few issues: Network latency (server needed for most operations). Submitting “half-ready” code can break other people’s work. DVCS (Git)
  • 15. Many modern VCS tools are distributed This means a central server is optional Each developer gets a copy of the entire repository A central server can still be setup Used as a sync point for team members DVCS (Git)
  • 16. Git offers a command line tool (comes from Linux) On Windows: Shell Extension Visual Studio integration using plugins DVCS (Git)
  • 19. CI Implementation #1 CI Server Source Control (Git) TeamCity Build Agent CI Build Nightly Build
  • 20. CI Implementation #1 What we gained: Basic framework for more complicated tasks Source control contains a “clean” copy of the code Fast notification on build issues Starting to incorporate basic unit tests Installer (.MSI) creation is automatic Using a modern source control system (Git)
  • 21. CI Implementation #2 CI Server Git CI Build Build Agent Build Agent Build Agent … Nightly Build VM Server Win7 x64 Win7 Win XP …

Notas do Editor

  1. This presentation’s title is “Continuous Integration” and is meant for introducing the basic concepts of CI to a development team.As CI is tightly related to other concepts (such as automated builds, unit testing), these will be brought here as well.
  2. Main agenda for this presentation.Continuous Integration is directly tied with other concepts such as unit testing, automated build and tools that perform various verifications to maintain high code quality.Although not directly related, I’d like to present Git and its advantages as a Distributed version control system (DVCS).
  3. One problem with measuring how ‘good’ a code project is, is that often the measurement is objective and not based on solid data.Team members integrate their work not often enough, leading to complex merging and integration of their work.Lack of code that tests the codebase (unit tests) brings us to a state that we “believe” our code is working, however as we progress and the project becomes more complex, we cannot be certain that everything is works as expected.
  4. What we would like to achieve is:Have criteria to tell us if our project is doing good.Integrate often to prevent complicated integration points between developers on a team.Create small pieces of code that test and exercise the code of the project we’re working on.
  5. Definition of Continuous Integration, as brought by Martin Fowler’s essay on the subject.The full essay can be found here: http://martinfowler.com/articles/continuousIntegration.html
  6. Without CI, a developer had to update to latest code before committing, and verify (locally) that all source code compiles and tests are OK.Using CI, the build server will build the project from the latest code checked in, and report if anything went wrong.Typically this is done quickly enough (recommended is less than 10 minutes).
  7. Automated builds are what allows CI to be effective.It is essential that the entire project can be built using some script in a single command.Setting this up involves a few other steps, such as keeping ALL files related to building the project under source control (for example, external 3rd party libraries, configuration files, images, etc.).This removes the need to do manual work that only certain team members have or the risk of a human error when running any manual step.This also has an added value that new team members can directly build the project without installing any software on their environments, and build servers do not need any special prerequisite software for running a build.
  8. Multiple technologies exist for constructing a build script (simple batch files, MSBuild, Nant).Upon check in (commit) to the source control system, the smallest subset of actions need to be performed, in order to deliver results as fast as possible.To this end, it is typical to set up multiple building scenarios that are invoked at different times. For example, a “small” build runs for every check in to source control.Every night a “Full” build runs that builds an MSI, documentation runs an extensive test suite, etc.
  9. These are examples of tools that are very easy to integrate into the build.Some of them ship with an MSBuild task to be directly invoked from a build script.Most also integrate well into popular CI server software.
  10. Code coverage shows in numbers how much of the code is actually covered.A typical scenario for this is when running unit tests, monitoring the actual code that runs during the tests.This generates a report of how much of the codebase was actually exercised during unit testing.A report is presented showing how many classes were used, methods were called, etc.
  11. Source code highlighting shows which lines of code get called or not.This can also be integrated into the IDE (Visual Studio) to show what part of the code was used.Areas shown in red should be exercised by a unit test.
  12. StyleCop is a tool that scans the code, enforcing a set of predefined rules.There are many styling rules, not all of them are mandatory for a consistent and high quality code.Once a set of rules is defined, it is stored in a StyleCop.settings file.This file can be placed at the root folder of a project, affecting all folders under it.StyleCop can be configured to output build errors instead of warnings. This can ensure all code checked into the source control repository is consistent with the team’s rules.
  13. These are examples of tools that are very easy to integrate into the build.Some of them ship with an MSBuild task to be directly invoked from a build script.Most also integrate well into popular CI server software.
  14. Older generation VCS tools were mostly centralized. A central server used to hold the master repository.Every action had to pass through this server, making it potentially slow, depending on the networking protocol used, and the proximity to the server.
  15. Modern tools like Git and Hg are distributed.Every developer gets a copy of the entire repository, maintaining it locally.A central server can be setup to sync between team members.In this method, a developer can develop a new feature locally, check in changes as he makes progress.When the code reaches a certain stage where it’s stable enough, the developer can submit (push) the changes to a central server, making it visible for other team members.
  16. Git originates from Linux.On Windows, It can be used in various different ways:Command line interface.Shell (explorer) extensionVisual Studio integration.
  17. Central server, developers access and update it.Taken from: http://progit.org/book/ch5-1.htmlIn centralized systems, there is generally a single collaboration model—the centralized workflow. One central hub, or repository, can accept code, and everyone synchronizes their work to it. A number of developers are nodes — consumers of that hub — and synchronize to that one place (see Figure 5-1).This means that if two developers clone from the hub and both make changes, the first developer to push their changes back up can do so with no problems. The second developer must merge in the first one’s work before pushing changes up, so as not to overwrite the first developer’s changes. This concept is true in Git as it is in Subversion (or any CVCS), and this model works perfectly in Git.If you have a small team or are already comfortable with a centralized workflow in your company or team, you can easily continue using that workflow with Git. Simply set up a single repository, and give everyone on your team push access; Git won’t let users overwrite each other. If one developer clones, makes changes, and then tries to push their changes while another developer has pushed in the meantime, the server will reject that developer’s changes. They will be told that they’re trying to push non-fast-forward changes and that they won’t be able to do so until they fetch and merge. This workflow is attractive to a lot of people because it’s a paradigm that many are familiar and comfortable with.
  18. Taken from: http://progit.org/book/ch5-1.html#integrationmanager_workflowBecause Git allows you to have multiple remote repositories, it’s possible to have a workflow where each developer has write access to their own public repository and read access to everyone else’s. This scenario often includes a canonical repository that represents the “official” project. To contribute to that project, you create your own public clone of the project and push your changes to it. Then, you can send a request to the maintainer of the main project to pull in your changes. They can add your repository as a remote, test your changes locally, merge them into their branch, and push back to their repository. The process works as follow (see Figure 5-2):The project maintainer pushes to their public repository.A contributor clones that repository and makes changes.The contributor pushes to their own public copy.The contributor sends the maintainer an e-mail asking them to pull changes.The maintainer adds the contributor’s repo as a remote and merges locally.The maintainer pushes merged changes to the main repository.This is a very common workflow with sites like GitHub, where it’s easy to fork a project and push your changes into your fork for everyone to see. One of the main advantages of this approach is that you can continue to work, and the maintainer of the main repository can pull in your changes at any time. Contributors don’t have to wait for the project to incorporate their changes — each party can work at their own pace.
  19. For first implementation, an automated build + CI server is setup.Software used:Source Control – GitCI – TeamCity (free for small teams)Build Agent is on the same server as TeamCity. This is the actual component that runs the build. For scalability, many agents can be deployed on additional servers, making it possible to have multiple concurrent builds.Two build configurations are created:CI Build – triggered on every check in to the source control. Very quick (~ 1 minute).Nightly Build – slightly longer, also builds an installer using NSIS build script (~ 5 minutes).
  20. Implementation #1 is not perfect yet, but it gives us a solid framework to build upon.Tasks that were manual before (such as creating an installer) are replaced with a 1-click automatic, repeatable action.A developer submitting new code can receive in ~ 1 minute a notification that his code passed some basic tests and is considered good.
  21. Second implementation expands on the first one.In this example, more build agents are introduced, and can accommodate more concurrent builds by a larger development team.After passing all initial tests, a build is passed on to a VM server, where it is automatically deployed to virtual machines, according to the needs of the built applications.For example, a client application can be deployed to multiple client operating systems, where a set of automated integration tests occur.