34
Marcus Fonseca Miguel Lemos Saindo de 2 para 50 releases semanais do app do Nubank

Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

  • Upload
    others

  • View
    4

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Marcus FonsecaMiguel Lemos

Saindo de 2 para 50 releases semanais do app do Nubank

Page 2: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.0

android-bonafont3.0.0

Page 3: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.1

android-bonafont3.0.0

5.0.1

Page 4: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.1

android-bonafont3.0.1

Page 5: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.1

android-bonafont3.0.1

android-help4.0.1

Page 6: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.2

android-bonafont3.0.1

android-help4.0.1

5.0.2

Page 7: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.2

android-bonafont3.0.2

android-help4.0.1

5.0.2

Page 8: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.2

android-bonafont3.0.2

android-help4.0.1

5.0.25.0.2

Page 9: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.3

android-bonafont3.0.2

android-help4.0.1

Page 10: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.3

android-bonafont3.0.2

android-help4.0.1

5.0.3

Page 11: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.3

android-bonafont3.0.3

android-help4.0.1

5.0.3

Page 12: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation5.0.3

android-bonafont3.0.3

android-help4.0.2

5.0.35.0.3

App

● ●●

Page 13: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

android-foundation

nu-x

android-help

credit-cardghostflame android-app

android-bonafont

microlibraries

android-shell

3~4 Days

Page 14: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source
Page 15: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Problems

Distributed source code

1 Harder dependency management

2 Non-atomic changes

3

Page 16: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

MONOREPO

Page 17: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Monorepo

Software development strategy where code for many projects are stored in the same repository.

Page 18: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

MONOREPO

● Single source of truth

All code in one place, including assets, icon, mock files and etc.

● Discoverability

Sharing knowledge passively. Everyone can see what everyone is doing.

● Atomic changes

Backwards incompatible changes are easy to make, Single PR affecting changes in many projects.

● No versioning

No need for versions, no semantic versions.

Page 19: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

MONOREPO

~68kCommits

~50Weekly releases

170Contributors

~1.5MLines of code

Page 20: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Monorepo challenges The monorepo might be the solution to our problems

but it also comes with some other problems

1 CI/CD TOOL CHANGES

3 HIGHER INFLUX OF CONTRIBUTORS

2 SMART PIPELINES

4 MORE ROBUST INFRASTRUCTURE

Page 21: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

CI/CD TOOL CHANGES GoCD didn't fit our needs.

1 PIPELINE VERSIONING

3 MULTIPLE PIPELINES TO THE SAME REPO

2 PARALLEL RUNS

4 EXPLICIT SUPPORT TO PULL REQUESTS

Page 22: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Monorepo challenges The monorepo might be the solution to our problems

but it also comes with some other problems

1 CI/CD TOOL CHANGES

3 HIGHER INFLUX OF CONTRIBUTORS

2 SMART PIPELINES

4 MORE ROBUST INFRASTRUCTURE

Page 23: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

SMART PIPELINES

Page 24: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

DYNAMIC PIPELINE

Page 25: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

DYNAMIC PIPELINE

Page 26: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Monorepo challenges The monorepo might be the solution to our problems

but it also comes with some other problems

1 CI/CD TOOL CHANGES

3 HIGHER INFLUX OF CONTRIBUTORS

2 SMART PIPELINES

4 MORE ROBUST INFRASTRUCTURE

Page 27: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

BORS

Page 28: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

BORS

Page 29: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source
Page 30: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source
Page 31: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source
Page 32: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Monorepo challenges The monorepo might be the solution to our problems

but it also comes with some other problems

1 CI/CD TOOL CHANGES

3 HIGHER INFLUX OF CONTRIBUTORS

2 SMART PIPELINES

4 MORE ROBUST INFRASTRUCTURE

Page 33: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

Infrastructure

Jenkins’ master and agents are on our k8s cluster using AWS and virtualized on Docker.

We use MacStadium and Ansible for iOS.

Using Prometheus for monitoring and Splunk for logging on Jenkins.

Page 34: Saindo de 2 - Amazon S3 · android-foundation nu-x android-help ghostflame android-app credit-card android-bonafont microlibraries android-shell 3~4 Days. Problems Distributed source

RESULT