[Android stories] Duolingo 리팩토리 이야기

박주호·2022년 4월 24일
0
post-thumbnail

Duolingo refactors on Android with MVVM and Jetpack libraries

원본 글

Duolingo is the world’s most popular language learning app because it’s managed to make something people have found daunting in the past feel easy and fun.
This breezy language experience requires a constant stream of new features and experiments — and a smooth-running app that can deliver all of them.

듀오링고는 세계에서 가장 인기있는 언어 학습 앱이다 왜냐하면 듀오링고는 과거의 몇몇 사람들이 힘들다고 생각하는 것들을 쉽고 재밌게 만들어주기 때문이다
이 상쾌한 언어는 새로운 기능과 실험의 지속적인 흐름이 요구된다. 그리고 이 모든 것을 전달 할 수 있는 부드러운 앱 실행이 필요하다.

To Duolingo, an unresponsive app on a device anywhere in the world could mean a potentially discouraged learner.
This commits them to app excellence, particularly on the Android devices used by sixty percent of their learners, including their CEO, who keeps track of the app from an entry-level phone.
And so, when Duolingo's Android development team noticed an increase in “App not Responding” errors, dropped frames — and even received hand-written complaints — they took action immediately.

듀오링고에게 전 세계 어디든 기기에 응답하지 않는 앱은 궁극적으로 의욕을 상실한 수강생을 의미한다.
특히 초기 핸드폰을 유지하는 ceo를 포함한 60%의 안드로이드 사용자들에게 그들에게 좋은 앱을 약속한다.
그래서 듀오링고 안드로이드 개발자팀은 프레임이 떨어지고 심지어 그들이 자필로 쓴 컴플레인들인 ANR에러가 증가했을 때 즉각적으로 조치했다.

They soon uncovered the source of the app’s performance issues: the existing software architecture wasn’t scaling well with the growth of their team.
Necessary updates were causing painful performance regressions on the app. Their developers were devoting more time to fixing bugs, and less to shipping new revenue-generating features.
Their outdated software architecture was starting to become an unacceptable drag — on them, their team velocity, and, above all, on their users’ experience. They needed to rebuild their codebase from the ground up.

그들은 곧 앱 성능 문제의 원인을 발견했다. 기존 소프트웨어 아키텍저는 팀의 성장에 따라 잘 확장되지 않았다.
필수 업데이트로 인해 고통스러운 앱 성능 저하가 발생했다. 개발자들은 버그수정에 더 많은 시간을 할애하고 수익창출 기능에 더 적은 시간을 할애했다.
구식 소프트웨어 아키텍처는 수용할 수 없게 개발팀의 속도, 모든 것, 사용자 경험에서 차질이 생기기 시작했다. 그들은 코드베이스를 다시 구축할 필요가 있었다.

How they did it

At the beginning, the team was torn. Should this be their sole priority now? One group felt that it was more important to continue shipping new features and driving revenue,
while the other believed that focusing all their attention on an Android reboot was the way forward.
Eventually, they reached the consensus that the increasing effort of fighting regressions risked derailing their road map entirely. They had to go all-in.

시작할 때 팀은 흩어졌다. 현재 리빌드가 유일한 우선순위인가? 한 그룹은 지속적으로 새로운 기능과 이익창출을 더 중요하게 생각하고 반면 다른 그룹은 안드로이드 리부트에 초점을 맞추는 것이 앞으로 나아가야할 방향이라고 믿었다.
결국 성능 저하와 싸우는 노력이 증가하면 그들의 로드맵 전체를 탈선할 위험이 있다는 의견일치에 이르렀다. 그들은 올인 해야했다.

The team settled on an increasingly popular solution. They decided to rewrite their app using Model-View-ViewModel,
a software pattern supported by Google that allows developers to streamline an app’s architecture by creating clear separation of concerns.
With MVVM, they could separate the development of the graphical user interface (the view) from the development of the business logic (the model).
They could establish clear and agreed upon patterns, making it easier to both align their approach to new features and onboard incoming developers.

팀은 점점 인기있는 해결책에 정착했다. 그들은 앱에서 발생하는 문제들을 구분하여 개발자들이 앱 아키텍처를 간소화할 수 있는 구글에서 지원하는 소프트웨어 패턴인 MVV을 사용하여 앱을 만들기로 결정했다.
mvvm과 함께 그들은 그래픽 유저 인터페이스(뷰)와 비지니스 로직(모델)을 구분할 수 있었다.
명확하고 합의된 패턴으로 새기능 구축과 신규 개발자들을 온보드하기에 더 쉽게 만들었다.

Breaking each feature into its own modular piece allowed the team to quickly regain productivity, as they could assign small groups to work on each feature in parallel, increasing velocity while reducing errors.
They implemented this new architecture with libraries from Android’s Jetpack, including Dagger and Hilt, to help them write code that works consistently across Android versions and devices.
These two additions enabled them to create better encapsulated features and utilize Android’s built-in modules more efficiently.

각 기능을 자체 모듈식 부분으로 나누면 팀이 신속하게 생산성을 회복할 수 있었다. 작은 그룹을 할당하여 각 기능을 병렬로 작업하도록 할당하여 오류를 줄이면서 속도를 높일 수 있었다.
dagger와 hilt를 포함한 잿팩 라이브러리를 사용하여서 안드로이드 버전 및 기기에 일관되게 작동하는 코드를 작성할 수 있었다.
추가된 이 두가지는 더 나은 캡슐화 기능을 만들고 안드로이드 내장 모듈을 효과적으로 사용할 수 있게 해주었다.

Result

These performance gains significantly improved learners' experience on Android and in particular on entry-level devices.

이런 성능 이점들은 안드로이드와 특정 보급형 기기 수강자들의 경험을 상당히 향상시켰습니다.

They also led to a more responsive app with smoother animations on flagship devices. The daily “App Not Responding” or ANR rate dropped 41%.

그들은 또한 플래그십 디디에서 부드러운 애니메이션에 있어 앱을 좀 더 반응하도록 이끌었습니다.

The percentage of time that the app fell below its target frame rate decreased by 28%. Most importantly, their users experienced a 40% increase in speed when scrolling through key screens.

앱이 목표 프레임 비율 아래로 떨어진 시간이 28퍼센트 내려갔습니다. 가장 중요한점은 화면 스크롤 시 속도에 있어 유저 경험이 40퍼센트 향상되었습니다.


📗 단어 정리 📘

영어한글
daunting벅찬, 힘든
breezy경쾌한
regressions역행 -> 저하
outdated구식인
drag(힘들여)끌다
velocity속도
consensus의견일치, 합의
separation분리, 구분
encapsulated캡슐화
utilize활용하다
significantly상당히
entry-level devices보급형 기기
profile
항상 배우려는 자세로

0개의 댓글