SlideShare ist ein Scribd-Unternehmen logo
1 von 44
Gradle:
One technology to build them all
Baptiste Mesta - R&D Engineer @ Bonitasoft
@baptistemesta
1
Baptiste Mesta
R&D Engineer @ Bonitasoft since 2009
● BPM Execution engine
● Developer tooling
● IA/Analytics module
Twitter: @baptistemesta
Github: baptistemesta
About me
2
• What is Gradle?
• How it works
• Build all kinds of projects
• Enjoy the benefits of Gradle
Agenda
3
What is Gradle?
4
• Build tool written in Java
• Execute on the JVM
• Open source
• Supported by a company: Gradle Inc.
What is Gradle?
5
Comprehensive DSL to configure build
What is Gradle?
6
Easy to read build execution
What is Gradle?
7
Gradle Maven
Highly customizable and extensible
What is Gradle?
8
How it works
9
• Reads Gradle build scripts
• Creates a dependency graph of tasks
• Executes required tasks
How it works
10
Tasks: units of work
How it works
11
Tasks can have dependencies
How it works
12
How it works
13
compileJava
Inputs Outputs
src/main/java/**/*.java build/classes/java/main/**
/*.class
Simple Java project
How it works
14
How it works
15
Build all kinds of projects
16
“Java is nice… but I also have some "Go" in my project…”
Build all kinds of projects
17
... plugins to the rescue!
Use a community plugin to build a Go project
Build all kinds of projects
18
Use a community plugin to build a Go project
Build all kinds of projects
19
“What if there is no community plugin that fits my needs?”
Build all kinds of projects
20
… extract your build logic to a custom plugin
Build all kinds of projects
21
buildUIDPage
Inputs Outputs
.json + .js .html + .css + .js
Call build Get page
Build all kinds of projects
22
Go module: community plugin
UID page: custom plugin
App distrib: depends on other
modules and packages them
Java module: provided plugins
“Ok I can build all kind of technologies with Gradle…
but why should I?”
Build all kind of projects
23
Enjoy the benefits of Gradle
24
“Do I still need to install Node, npm and Go locally?”
Plugins download distributions if required
Enjoy the benefits of Gradle
25
“Do I still need to install Gradle?”
Use the Gradle wrapper
You only need a JVM on your environment and on your CI
Enjoy the benefits of Gradle
26
Work avoidance
Enjoy the benefits of Gradle
27
TaskInputs Outputs
Source files Files produced
Compare hash of
source files from
previous build Same hash: Skip the task
Hash changed: Execute
the task
Work avoidance
First build
Enjoy the benefits of Gradle
28
Java dev
Go
Java
UID
Distribution
1. Build
3. Compile
5. Zip all
2. Compile
4. Compile
My project
Work avoidance
Second build
Enjoy the benefits of Gradle
29
Java dev
Go
Java
UID
Distribution
1. Build
again 3. Compile
5. Zip all
2. Compile
4. Compile
My project
UP-TO-DATE
UP-TO-DATE
UP-TO-DATE
UP-TO-DATE
Work avoidance
Third build with code change
Enjoy the benefits of Gradle
30
Java dev
Go
Java
UID
Distribution
1. Modify
Java
code and
build
3. Compile
5. Zip all
2. Compile
4. Compile
My project
UP-TO-DATE
UP-TO-DATE
Work avoidance for your team / CI
Enjoy the benefits of Gradle
31
Back to our multi-techno build. What happens in real life?
Enjoy the benefits of Gradle
32
Java dev
Go
Java
UID
Distribution
1. Update
+ build 3. Compile
5. Zip all
2. Compile
4. Compile
My project
Back to our multi-techno build. What happens in real life?
Enjoy the benefits of Gradle
33
Java dev
Remote
cache
Go
Java
UID
Distribution
1. Update
+ build
2. Retrieve
from cache
5. Zip all
2. Compile
3. Compile
4. Compile
My project
Enjoy the benefits of Gradle
34
Our Java developer never had to build Go or UID modules
Build time gained @ Bonitasoft on a small Java project
Enjoy the benefits of Gradle
35
Without cache
With cache
Enjoy the benefits of Gradle
36
Without cache
With cache
Build time gained @ Bonitasoft on a project with
30 modules: Java + react + custom
No tools to install
Gradle distribution and other tooling
are downloaded and cached
Enjoy the benefits of Gradle
37
Each developer can focus on what matters to them
Don't need to rebuild everything locally
Enjoy the benefits of Gradle
38
No need to read setup
documentation on every project
Just run ./gradlew build
Enjoy the benefits of Gradle
39
Yes we can build everything with gradle!
Yes it is useful when mixing technologies!
Use the build cache!
Conclusion
40
Thank you!
Baptiste Mesta
Twitter: @baptistemesta
Github: baptistemesta
41
Work avoidance
First build
Enjoy the benefits of Gradle
42
Work avoidance
Second build
Enjoy the benefits of Gradle
43
Work avoidance
After some sources are modified
Enjoy the benefits of Gradle
44

Weitere ähnliche Inhalte

Was ist angesagt?

SanDiego_DevOps_Meetup_9212016-v8
SanDiego_DevOps_Meetup_9212016-v8SanDiego_DevOps_Meetup_9212016-v8
SanDiego_DevOps_Meetup_9212016-v8
Rajwinder Singh
 
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
Daniel Oh
 
Continuous integration / deployment with Jenkins
Continuous integration / deployment with JenkinsContinuous integration / deployment with Jenkins
Continuous integration / deployment with Jenkins
cherryhillco
 
Сергей Моренец: "Gradle. Write once, build everywhere"
Сергей Моренец: "Gradle. Write once, build everywhere"Сергей Моренец: "Gradle. Write once, build everywhere"
Сергей Моренец: "Gradle. Write once, build everywhere"
Provectus
 

Was ist angesagt? (20)

Git slides
Git slidesGit slides
Git slides
 
Building Big Architectures XP Conference 2016
Building Big Architectures XP Conference 2016Building Big Architectures XP Conference 2016
Building Big Architectures XP Conference 2016
 
Building a loosely coupled toolchain with Rundeck and Puppet
Building a loosely coupled toolchain with Rundeck and PuppetBuilding a loosely coupled toolchain with Rundeck and Puppet
Building a loosely coupled toolchain with Rundeck and Puppet
 
SanDiego_DevOps_Meetup_9212016-v8
SanDiego_DevOps_Meetup_9212016-v8SanDiego_DevOps_Meetup_9212016-v8
SanDiego_DevOps_Meetup_9212016-v8
 
Magento Continuous Integration & Continuous Delivery @MM17HR
Magento Continuous Integration & Continuous Delivery @MM17HRMagento Continuous Integration & Continuous Delivery @MM17HR
Magento Continuous Integration & Continuous Delivery @MM17HR
 
All Around Azure: DevOps with GitHub - Managing the Flow of Work
All Around Azure: DevOps with GitHub - Managing the Flow of WorkAll Around Azure: DevOps with GitHub - Managing the Flow of Work
All Around Azure: DevOps with GitHub - Managing the Flow of Work
 
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
ApacheCon Europe 2016 : CONTAINERS IN ACTION - Transform Application Delivery...
 
Devoxx : being productive with JHipster
Devoxx : being productive with JHipsterDevoxx : being productive with JHipster
Devoxx : being productive with JHipster
 
Continuous integration using Bamboo
Continuous integration using BambooContinuous integration using Bamboo
Continuous integration using Bamboo
 
Gitlab CI/CD
Gitlab CI/CDGitlab CI/CD
Gitlab CI/CD
 
Continuous integration / continuous delivery of web applications, Eugen Kuzmi...
Continuous integration / continuous delivery of web applications, Eugen Kuzmi...Continuous integration / continuous delivery of web applications, Eugen Kuzmi...
Continuous integration / continuous delivery of web applications, Eugen Kuzmi...
 
Continuous integration / deployment with Jenkins
Continuous integration / deployment with JenkinsContinuous integration / deployment with Jenkins
Continuous integration / deployment with Jenkins
 
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...
 
Javantura v4 - Android App Development in 2017 - Matej Vidaković
Javantura v4 - Android App Development in 2017 - Matej VidakovićJavantura v4 - Android App Development in 2017 - Matej Vidaković
Javantura v4 - Android App Development in 2017 - Matej Vidaković
 
What's new in Gradle 4.0
What's new in Gradle 4.0What's new in Gradle 4.0
What's new in Gradle 4.0
 
Continuous Integration
Continuous IntegrationContinuous Integration
Continuous Integration
 
JHipster Code 2020 keynote
JHipster Code 2020 keynoteJHipster Code 2020 keynote
JHipster Code 2020 keynote
 
Introduction to android studio 2.0 and data binding library
Introduction to android studio 2.0 and data binding libraryIntroduction to android studio 2.0 and data binding library
Introduction to android studio 2.0 and data binding library
 
Anatomy of a Continuous Integration and Delivery (CICD) Pipeline
Anatomy of a Continuous Integration and Delivery (CICD) PipelineAnatomy of a Continuous Integration and Delivery (CICD) Pipeline
Anatomy of a Continuous Integration and Delivery (CICD) Pipeline
 
Сергей Моренец: "Gradle. Write once, build everywhere"
Сергей Моренец: "Gradle. Write once, build everywhere"Сергей Моренец: "Gradle. Write once, build everywhere"
Сергей Моренец: "Gradle. Write once, build everywhere"
 

Ähnlich wie Gradle: One technology to build them all

Ähnlich wie Gradle: One technology to build them all (20)

Exploring the power of Gradle in android studio - Basics & Beyond
Exploring the power of Gradle in android studio - Basics & BeyondExploring the power of Gradle in android studio - Basics & Beyond
Exploring the power of Gradle in android studio - Basics & Beyond
 
Gradle enabled android project
Gradle enabled android projectGradle enabled android project
Gradle enabled android project
 
Gradle,the new build system for android
Gradle,the new build system for androidGradle,the new build system for android
Gradle,the new build system for android
 
Keeping your build tool updated in a multi repository world
Keeping your build tool updated in a multi repository worldKeeping your build tool updated in a multi repository world
Keeping your build tool updated in a multi repository world
 
Javaone 2013 moscow gradle english
Javaone 2013 moscow gradle   englishJavaone 2013 moscow gradle   english
Javaone 2013 moscow gradle english
 
Android gradle-build-system-overview
Android gradle-build-system-overviewAndroid gradle-build-system-overview
Android gradle-build-system-overview
 
From GitHub Source to GitHub Release: Free CICD Pipelines For JavaFX Apps
From GitHub Source to GitHub Release: Free CICD Pipelines For JavaFX AppsFrom GitHub Source to GitHub Release: Free CICD Pipelines For JavaFX Apps
From GitHub Source to GitHub Release: Free CICD Pipelines For JavaFX Apps
 
Introduction to gradle
Introduction to gradleIntroduction to gradle
Introduction to gradle
 
Gradle and Android Studio : Best of Friends
Gradle and Android Studio : Best of FriendsGradle and Android Studio : Best of Friends
Gradle and Android Studio : Best of Friends
 
Gradle explained
Gradle explainedGradle explained
Gradle explained
 
Gitlab ci e kubernetes, build test and deploy your projects like a pro
Gitlab ci e kubernetes, build test and deploy your projects like a proGitlab ci e kubernetes, build test and deploy your projects like a pro
Gitlab ci e kubernetes, build test and deploy your projects like a pro
 
Cloud Study Jam Exploring the Cloud
Cloud Study Jam Exploring the CloudCloud Study Jam Exploring the Cloud
Cloud Study Jam Exploring the Cloud
 
ICONUK 2015 - Gradle Up!
ICONUK 2015 - Gradle Up!ICONUK 2015 - Gradle Up!
ICONUK 2015 - Gradle Up!
 
DevOps & SRE at Google Scale
DevOps & SRE at Google ScaleDevOps & SRE at Google Scale
DevOps & SRE at Google Scale
 
Gradle - Build System
Gradle - Build SystemGradle - Build System
Gradle - Build System
 
Gradle - the Enterprise Automation Tool
Gradle  - the Enterprise Automation ToolGradle  - the Enterprise Automation Tool
Gradle - the Enterprise Automation Tool
 
Why Gradle?
Why Gradle?Why Gradle?
Why Gradle?
 
Gradle build automation tool
Gradle   build automation toolGradle   build automation tool
Gradle build automation tool
 
Enhance Your Kubernetes CI/CD Pipelines With GitLab & Open Source
Enhance Your Kubernetes CI/CD Pipelines With GitLab & Open SourceEnhance Your Kubernetes CI/CD Pipelines With GitLab & Open Source
Enhance Your Kubernetes CI/CD Pipelines With GitLab & Open Source
 
Gradle
GradleGradle
Gradle
 

Mehr von Bonitasoft

Digitaliser ses processus en 2020 avec le Club des Pilotes de Processus
Digitaliser ses processus en 2020 avec le Club des Pilotes de ProcessusDigitaliser ses processus en 2020 avec le Club des Pilotes de Processus
Digitaliser ses processus en 2020 avec le Club des Pilotes de Processus
Bonitasoft
 

Mehr von Bonitasoft (20)

Digitalize your processes in 2020
Digitalize your processes in 2020Digitalize your processes in 2020
Digitalize your processes in 2020
 
Digitaliser ses processus en 2020 avec le Club des Pilotes de Processus
Digitaliser ses processus en 2020 avec le Club des Pilotes de ProcessusDigitaliser ses processus en 2020 avec le Club des Pilotes de Processus
Digitaliser ses processus en 2020 avec le Club des Pilotes de Processus
 
Build a Center of Excellence
Build a Center of ExcellenceBuild a Center of Excellence
Build a Center of Excellence
 
Construir un Centro de Excellencia
Construir un Centro de ExcellenciaConstruir un Centro de Excellencia
Construir un Centro de Excellencia
 
User Centered Design: guarantee that your business process automation project...
User Centered Design: guarantee that your business process automation project...User Centered Design: guarantee that your business process automation project...
User Centered Design: guarantee that your business process automation project...
 
Bonnes pratiques #5 - Votre première application est en production. Et mainte...
Bonnes pratiques #5 - Votre première application est en production. Et mainte...Bonnes pratiques #5 - Votre première application est en production. Et mainte...
Bonnes pratiques #5 - Votre première application est en production. Et mainte...
 
Buenas Prácticas ES - Capítulo #5 - ¡Tu primera aplicación está en producción...
Buenas Prácticas ES - Capítulo #5 - ¡Tu primera aplicación está en producción...Buenas Prácticas ES - Capítulo #5 - ¡Tu primera aplicación está en producción...
Buenas Prácticas ES - Capítulo #5 - ¡Tu primera aplicación está en producción...
 
Best Practices #5: Your first application is in production! Now what?
Best Practices #5: Your first application is in production! Now what?Best Practices #5: Your first application is in production! Now what?
Best Practices #5: Your first application is in production! Now what?
 
IDC Observatoire 2020 de l'Automatisation des Métiers: vers l'Intelligent Pro...
IDC Observatoire 2020 de l'Automatisation des Métiers: vers l'Intelligent Pro...IDC Observatoire 2020 de l'Automatisation des Métiers: vers l'Intelligent Pro...
IDC Observatoire 2020 de l'Automatisation des Métiers: vers l'Intelligent Pro...
 
e-ciudadanos: la evolución de los procesos administrativos
e-ciudadanos: la evolución de los procesos administrativose-ciudadanos: la evolución de los procesos administrativos
e-ciudadanos: la evolución de los procesos administrativos
 
Best Practices - chapter #4 - Web UI development and Bonita infrastructure setup
Best Practices - chapter #4 - Web UI development and Bonita infrastructure setupBest Practices - chapter #4 - Web UI development and Bonita infrastructure setup
Best Practices - chapter #4 - Web UI development and Bonita infrastructure setup
 
Buenas Prácticas ES - Capítulo #3 - Colaboración entre negocio y desarrollo c...
Buenas Prácticas ES - Capítulo #3 - Colaboración entre negocio y desarrollo c...Buenas Prácticas ES - Capítulo #3 - Colaboración entre negocio y desarrollo c...
Buenas Prácticas ES - Capítulo #3 - Colaboración entre negocio y desarrollo c...
 
Best Practices - chapter #3 - Business and developer collaboration with Bonita
Best Practices - chapter #3 - Business and developer collaboration with BonitaBest Practices - chapter #3 - Business and developer collaboration with Bonita
Best Practices - chapter #3 - Business and developer collaboration with Bonita
 
Bonnes pratiques pour gérer l'automatisation de vos processus - Chapitre 3 - ...
Bonnes pratiques pour gérer l'automatisation de vos processus - Chapitre 3 - ...Bonnes pratiques pour gérer l'automatisation de vos processus - Chapitre 3 - ...
Bonnes pratiques pour gérer l'automatisation de vos processus - Chapitre 3 - ...
 
DPA Bonita plateforme socle de votre automatisation des processus métiers - P...
DPA Bonita plateforme socle de votre automatisation des processus métiers - P...DPA Bonita plateforme socle de votre automatisation des processus métiers - P...
DPA Bonita plateforme socle de votre automatisation des processus métiers - P...
 
Bonita 7.10 - Nathalie Cotté - Bonitaday Paris 2019
Bonita 7.10 - Nathalie Cotté - Bonitaday Paris 2019Bonita 7.10 - Nathalie Cotté - Bonitaday Paris 2019
Bonita 7.10 - Nathalie Cotté - Bonitaday Paris 2019
 
Bonita Cloud - Florent Sarat - Bonitaday Paris 2019
Bonita Cloud - Florent Sarat - Bonitaday Paris 2019Bonita Cloud - Florent Sarat - Bonitaday Paris 2019
Bonita Cloud - Florent Sarat - Bonitaday Paris 2019
 
Adaptive Case Management avec Bonita - Adrien Lachambre - Bonitaday Paris 2019
Adaptive Case Management avec Bonita - Adrien Lachambre - Bonitaday Paris 2019Adaptive Case Management avec Bonita - Adrien Lachambre - Bonitaday Paris 2019
Adaptive Case Management avec Bonita - Adrien Lachambre - Bonitaday Paris 2019
 
BPM & RPA l'automatisation de bout-en-bout - Bonitasoft et UiPath - Bonitaday...
BPM & RPA l'automatisation de bout-en-bout - Bonitasoft et UiPath - Bonitaday...BPM & RPA l'automatisation de bout-en-bout - Bonitasoft et UiPath - Bonitaday...
BPM & RPA l'automatisation de bout-en-bout - Bonitasoft et UiPath - Bonitaday...
 
Bonita et l'orchestration de micro-services - Nicolas Chabanoles - Bonitaday ...
Bonita et l'orchestration de micro-services - Nicolas Chabanoles - Bonitaday ...Bonita et l'orchestration de micro-services - Nicolas Chabanoles - Bonitaday ...
Bonita et l'orchestration de micro-services - Nicolas Chabanoles - Bonitaday ...
 

Kürzlich hochgeladen

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Kürzlich hochgeladen (20)

AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 

Gradle: One technology to build them all

  • 1. Gradle: One technology to build them all Baptiste Mesta - R&D Engineer @ Bonitasoft @baptistemesta 1
  • 2. Baptiste Mesta R&D Engineer @ Bonitasoft since 2009 ● BPM Execution engine ● Developer tooling ● IA/Analytics module Twitter: @baptistemesta Github: baptistemesta About me 2
  • 3. • What is Gradle? • How it works • Build all kinds of projects • Enjoy the benefits of Gradle Agenda 3
  • 5. • Build tool written in Java • Execute on the JVM • Open source • Supported by a company: Gradle Inc. What is Gradle? 5
  • 6. Comprehensive DSL to configure build What is Gradle? 6
  • 7. Easy to read build execution What is Gradle? 7 Gradle Maven
  • 8. Highly customizable and extensible What is Gradle? 8
  • 10. • Reads Gradle build scripts • Creates a dependency graph of tasks • Executes required tasks How it works 10
  • 11. Tasks: units of work How it works 11 Tasks can have dependencies
  • 13. How it works 13 compileJava Inputs Outputs src/main/java/**/*.java build/classes/java/main/** /*.class
  • 14. Simple Java project How it works 14
  • 16. Build all kinds of projects 16
  • 17. “Java is nice… but I also have some "Go" in my project…” Build all kinds of projects 17 ... plugins to the rescue!
  • 18. Use a community plugin to build a Go project Build all kinds of projects 18
  • 19. Use a community plugin to build a Go project Build all kinds of projects 19
  • 20. “What if there is no community plugin that fits my needs?” Build all kinds of projects 20 … extract your build logic to a custom plugin
  • 21. Build all kinds of projects 21 buildUIDPage Inputs Outputs .json + .js .html + .css + .js Call build Get page
  • 22. Build all kinds of projects 22 Go module: community plugin UID page: custom plugin App distrib: depends on other modules and packages them Java module: provided plugins
  • 23. “Ok I can build all kind of technologies with Gradle… but why should I?” Build all kind of projects 23
  • 24. Enjoy the benefits of Gradle 24
  • 25. “Do I still need to install Node, npm and Go locally?” Plugins download distributions if required Enjoy the benefits of Gradle 25
  • 26. “Do I still need to install Gradle?” Use the Gradle wrapper You only need a JVM on your environment and on your CI Enjoy the benefits of Gradle 26
  • 27. Work avoidance Enjoy the benefits of Gradle 27 TaskInputs Outputs Source files Files produced Compare hash of source files from previous build Same hash: Skip the task Hash changed: Execute the task
  • 28. Work avoidance First build Enjoy the benefits of Gradle 28 Java dev Go Java UID Distribution 1. Build 3. Compile 5. Zip all 2. Compile 4. Compile My project
  • 29. Work avoidance Second build Enjoy the benefits of Gradle 29 Java dev Go Java UID Distribution 1. Build again 3. Compile 5. Zip all 2. Compile 4. Compile My project UP-TO-DATE UP-TO-DATE UP-TO-DATE UP-TO-DATE
  • 30. Work avoidance Third build with code change Enjoy the benefits of Gradle 30 Java dev Go Java UID Distribution 1. Modify Java code and build 3. Compile 5. Zip all 2. Compile 4. Compile My project UP-TO-DATE UP-TO-DATE
  • 31. Work avoidance for your team / CI Enjoy the benefits of Gradle 31
  • 32. Back to our multi-techno build. What happens in real life? Enjoy the benefits of Gradle 32 Java dev Go Java UID Distribution 1. Update + build 3. Compile 5. Zip all 2. Compile 4. Compile My project
  • 33. Back to our multi-techno build. What happens in real life? Enjoy the benefits of Gradle 33 Java dev Remote cache Go Java UID Distribution 1. Update + build 2. Retrieve from cache 5. Zip all 2. Compile 3. Compile 4. Compile My project
  • 34. Enjoy the benefits of Gradle 34 Our Java developer never had to build Go or UID modules
  • 35. Build time gained @ Bonitasoft on a small Java project Enjoy the benefits of Gradle 35 Without cache With cache
  • 36. Enjoy the benefits of Gradle 36 Without cache With cache Build time gained @ Bonitasoft on a project with 30 modules: Java + react + custom
  • 37. No tools to install Gradle distribution and other tooling are downloaded and cached Enjoy the benefits of Gradle 37
  • 38. Each developer can focus on what matters to them Don't need to rebuild everything locally Enjoy the benefits of Gradle 38
  • 39. No need to read setup documentation on every project Just run ./gradlew build Enjoy the benefits of Gradle 39
  • 40. Yes we can build everything with gradle! Yes it is useful when mixing technologies! Use the build cache! Conclusion 40
  • 41. Thank you! Baptiste Mesta Twitter: @baptistemesta Github: baptistemesta 41
  • 42. Work avoidance First build Enjoy the benefits of Gradle 42
  • 43. Work avoidance Second build Enjoy the benefits of Gradle 43
  • 44. Work avoidance After some sources are modified Enjoy the benefits of Gradle 44