Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate the Glean SDK to the Rust implementation #4620

Merged
merged 1 commit into from Oct 24, 2019

Conversation

@Dexterp37
Copy link
Contributor

Dexterp37 commented Oct 3, 2019

This completely removes the Kotlin implementation of the Glean SDK from this repository. It introduces aliases that are used instead.

Please note that integration tests keep living in this repository as part of the Glean sample app.

Note: this is a massive PR with deletion, mostly. I'd recommend reviewing it commit-by-commit

TODO

  • remove the glean binary;
  • depend on the maven version of the Glean SDK.

Pull Request checklist

  • Quality: This PR builds and passes detekt/ktlint checks (A pre-push hook is recommended)
  • Tests: This PR includes thorough tests or an explanation of why it does not
  • Changelog: This PR includes a changelog entry or does not need one
  • Accessibility: The code in this PR follows accessibility best practices or does not include any user facing features

After merge

  • Milestone: Make sure issues closed by this pull request are added to the milestone of the version currently in development.
  • Breaking Changes: If this is a breaking change, please push a draft PR on Reference Browser to address the breaking issues.
@Dexterp37 Dexterp37 self-assigned this Oct 3, 2019
@Dexterp37 Dexterp37 requested review from mdboom, travis79 and badboy Oct 3, 2019
@mdboom
mdboom approved these changes Oct 3, 2019
Copy link
Contributor

mdboom left a comment

+r, modulo working through the ktlint/detekt errors.

Copy link
Member

travis79 left a comment

Is adding the binary glean-0.0.1-TESTING1.aar to source control intentional?

@Dexterp37

This comment has been minimized.

Copy link
Contributor Author

Dexterp37 commented Oct 3, 2019

Is adding the binary glean-0.0.1-TESTING1.aar to source control intentional?

Yes, it's meant to be removed after the library is available on Maven (see the TODO in the PR description)

@travis79

This comment has been minimized.

Copy link
Member

travis79 commented Oct 3, 2019

Is adding the binary glean-0.0.1-TESTING1.aar to source control intentional?

Yes, it's meant to be removed after the library is available on Maven (see the TODO in the PR description)

Sorry, I totally overlooked the TODO. This makes sense, I just thought it was weird to include a binary and wanted to make sure.

@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch 2 times, most recently from 5409fda to 54a6643 Oct 3, 2019
@codecov

This comment has been minimized.

Copy link

codecov bot commented Oct 7, 2019

Codecov Report

Merging #4620 into master will decrease coverage by 0.88%.
The diff coverage is 0%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #4620      +/-   ##
============================================
- Coverage     81.35%   80.47%   -0.89%     
+ Complexity     4377     3907     -470     
============================================
  Files           561      511      -50     
  Lines         19087    17190    -1897     
  Branches       2782     2514     -268     
============================================
- Hits          15529    13833    -1696     
+ Misses         2439     2339     -100     
+ Partials       1119     1018     -101
Impacted Files Coverage Δ Complexity Δ
...ents/service/glean/net/ConceptFetchHttpUploader.kt 100% <ø> (ø) 7 <0> (ø) ⬇️
...a/components/service/glean/config/Configuration.kt 0% <0%> (-100%) 0 <0> (-10)
...ain/java/mozilla/components/service/glean/Glean.kt 0% <0%> (-84.44%) 0 <0> (-1)
...s/lib/push/firebase/AbstractFirebasePushService.kt 70.37% <0%> (-3.71%) 8% <0%> (ø)
...ponents/service/location/MozillaLocationService.kt
...ocation/search/RegionSearchLocalizationProvider.kt

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 321d499...12163f1. Read the comment docs.

@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch from 5aacd7a to 360a47c Oct 8, 2019
@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch 2 times, most recently from 1f4cab0 to ae0a1f3 Oct 9, 2019
@Dexterp37 Dexterp37 requested a review from badboy Oct 9, 2019
@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch 4 times, most recently from 7aaed8a to 766a6b9 Oct 9, 2019
@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch 3 times, most recently from 1e06c40 to 82620f9 Oct 16, 2019
@badboy
badboy approved these changes Oct 22, 2019
Copy link
Member

badboy left a comment

I built locally against this PR and even generated the Fenix APKs we used for testing and QA.
This seems to be all working.

The remaining steps:

  • Remove the mavenLocal() line
  • Wait for our Maven release
  • Re-base and push this PR again to trigger CI
  • Squash the commits into something reasonable
@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch 2 times, most recently from dd1c78d to 661a33e Oct 24, 2019
This removes the Kotlin implementation from this repository
and introduces type aliases that point to the Rust implementation,
which is now a new dependency.
@Dexterp37 Dexterp37 force-pushed the Dexterp37:gleancore_migration branch from 661a33e to 12163f1 Oct 24, 2019
@Dexterp37

This comment has been minimized.

Copy link
Contributor Author

Dexterp37 commented Oct 24, 2019

bors=mdboom,travis79,badboy
bors r+

bors bot pushed a commit that referenced this pull request Oct 24, 2019
Merge #4620
4620: Migrate the Glean SDK to the Rust implementation r=Dexterp37 a=Dexterp37

This completely removes the Kotlin implementation of the Glean SDK from this repository. It introduces aliases that are used instead.

Please note that integration tests keep living in this repository as part of the [Glean sample app](https://github.com/mozilla-mobile/android-components/tree/master/samples/glean/src/androidTest/java/org/mozilla/samples/glean).

**Note: this is a massive PR with deletion, mostly. I'd recommend reviewing it commit-by-commit**

**TODO**

- [x] remove the glean binary;
- [x] depend on the maven version of the Glean SDK.



Co-authored-by: Alessio Placitelli <alessio.placitelli@gmail.com>
@bors

This comment has been minimized.

Copy link

bors bot commented Oct 24, 2019

Build succeeded

  • complete-push
@bors bors bot merged commit 12163f1 into mozilla-mobile:master Oct 24, 2019
98 of 100 checks passed
98 of 100 checks passed
codecov/patch 0% of diff hit (target 81.35%)
Details
codecov/project 80.47% (-0.89%) compared to 321d499
Details
Decision Task Taskcluster (pull_request)
Details
bors Build succeeded
Details
build-browser-awesomebar Taskcluster (pull_request)
Details
build-browser-domains Taskcluster (pull_request)
Details
build-browser-engine-gecko Taskcluster (pull_request)
Details
build-browser-engine-gecko-beta Taskcluster (pull_request)
Details
build-browser-engine-gecko-nightly Taskcluster (pull_request)
Details
build-browser-engine-system Taskcluster (pull_request)
Details
build-browser-errorpages Taskcluster (pull_request)
Details
build-browser-icons Taskcluster (pull_request)
Details
build-browser-menu Taskcluster (pull_request)
Details
build-browser-search Taskcluster (pull_request)
Details
build-browser-session Taskcluster (pull_request)
Details
build-browser-state Taskcluster (pull_request)
Details
build-browser-storage-memory Taskcluster (pull_request)
Details
build-browser-storage-sync Taskcluster (pull_request)
Details
build-browser-tabstray Taskcluster (pull_request)
Details
build-browser-toolbar Taskcluster (pull_request)
Details
build-concept-awesomebar Taskcluster (pull_request)
Details
build-concept-engine Taskcluster (pull_request)
Details
build-concept-fetch Taskcluster (pull_request)
Details
build-concept-push Taskcluster (pull_request)
Details
build-concept-storage Taskcluster (pull_request)
Details
build-concept-sync Taskcluster (pull_request)
Details
build-concept-tabstray Taskcluster (pull_request)
Details
build-concept-toolbar Taskcluster (pull_request)
Details
build-feature-accounts Taskcluster (pull_request)
Details
build-feature-app-links Taskcluster (pull_request)
Details
build-feature-awesomebar Taskcluster (pull_request)
Details
build-feature-contextmenu Taskcluster (pull_request)
Details
build-feature-customtabs Taskcluster (pull_request)
Details
build-feature-downloads Taskcluster (pull_request)
Details
build-feature-findinpage Taskcluster (pull_request)
Details
build-feature-intent Taskcluster (pull_request)
Details
build-feature-media Taskcluster (pull_request)
Details
build-feature-privatemode Taskcluster (pull_request)
Details
build-feature-prompts Taskcluster (pull_request)
Details
build-feature-push Taskcluster (pull_request)
Details
build-feature-pwa Taskcluster (pull_request)
Details
build-feature-qr Taskcluster (pull_request)
Details
build-feature-readerview Taskcluster (pull_request)
Details
build-feature-search Taskcluster (pull_request)
Details
build-feature-sendtab Taskcluster (pull_request)
Details
build-feature-session Taskcluster (pull_request)
Details
build-feature-sitepermissions Taskcluster (pull_request)
Details
build-feature-tab-collections Taskcluster (pull_request)
Details
build-feature-tabs Taskcluster (pull_request)
Details
build-feature-toolbar Taskcluster (pull_request)
Details
build-feature-webcompat Taskcluster (pull_request)
Details
build-feature-webnotifications Taskcluster (pull_request)
Details
build-lib-crash Taskcluster (pull_request)
Details
build-lib-dataprotect Taskcluster (pull_request)
Details
build-lib-fetch-httpurlconnection Taskcluster (pull_request)
Details
build-lib-fetch-okhttp Taskcluster (pull_request)
Details
build-lib-jexl Taskcluster (pull_request)
Details
build-lib-publicsuffixlist Taskcluster (pull_request)
Details
build-lib-push-amazon Taskcluster (pull_request)
Details
build-lib-push-firebase Taskcluster (pull_request)
Details
build-lib-state Taskcluster (pull_request)
Details
build-samples-browser-beta Taskcluster (pull_request)
Details
build-samples-browser-nightly Taskcluster (pull_request)
Details
build-samples-browser-release Taskcluster (pull_request)
Details
build-samples-browser-system Taskcluster (pull_request)
Details
build-samples-crash Taskcluster (pull_request)
Details
build-samples-dataprotect Taskcluster (pull_request)
Details
build-samples-firefox-accounts Taskcluster (pull_request)
Details
build-samples-glean Taskcluster (pull_request)
Details
build-samples-glean-library Taskcluster (pull_request)
Details
build-samples-sync Taskcluster (pull_request)
Details
build-samples-sync-logins Taskcluster (pull_request)
Details
build-samples-toolbar Taskcluster (pull_request)
Details
build-service-experiments Taskcluster (pull_request)
Details
build-service-firefox-accounts Taskcluster (pull_request)
Details
build-service-fretboard Taskcluster (pull_request)
Details
build-service-glean Taskcluster (pull_request)
Details
build-service-location Taskcluster (pull_request)
Details
build-service-pocket Taskcluster (pull_request)
Details
build-service-sync-logins Taskcluster (pull_request)
Details
build-service-telemetry Taskcluster (pull_request)
Details
build-support-android-test Taskcluster (pull_request)
Details
build-support-base Taskcluster (pull_request)
Details
build-support-ktx Taskcluster (pull_request)
Details
build-support-locale Taskcluster (pull_request)
Details
build-support-migration Taskcluster (pull_request)
Details
build-support-rusthttp Taskcluster (pull_request)
Details
build-support-rustlog Taskcluster (pull_request)
Details
build-support-sync-telemetry Taskcluster (pull_request)
Details
build-support-test Taskcluster (pull_request)
Details
build-support-test-appservices Taskcluster (pull_request)
Details
build-support-utils Taskcluster (pull_request)
Details
build-support-webextensions Taskcluster (pull_request)
Details
build-tooling-detekt Taskcluster (pull_request)
Details
build-tooling-fetch-tests Taskcluster (pull_request)
Details
build-tooling-lint Taskcluster (pull_request)
Details
build-ui-autocomplete Taskcluster (pull_request)
Details
build-ui-colors Taskcluster (pull_request)
Details
build-ui-fonts Taskcluster (pull_request)
Details
build-ui-icons Taskcluster (pull_request)
Details
@Dexterp37 Dexterp37 mentioned this pull request Oct 30, 2019
0 of 6 tasks complete
bors bot pushed a commit that referenced this pull request Oct 30, 2019
Merge #4892
4892: Add back the @JvmOverloads to the Glean SDK public API r=Dexterp37 a=Dexterp37

This additionally adds unit testing in Java to make sure we're not regressing this again.

Note: this restores the annotations that were removed by #4620



Co-authored-by: Alessio Placitelli <alessio.placitelli@gmail.com>
bors bot pushed a commit that referenced this pull request Oct 30, 2019
Merge #4892
4892: Add back the @JvmOverloads to the Glean SDK public API r=Dexterp37 a=Dexterp37

This additionally adds unit testing in Java to make sure we're not regressing this again.

Note: this restores the annotations that were removed by #4620



Co-authored-by: Alessio Placitelli <alessio.placitelli@gmail.com>
bors bot pushed a commit that referenced this pull request Oct 30, 2019
Merge #4892
4892: Add back the @JvmOverloads to the Glean SDK public API r=Dexterp37 a=Dexterp37

This additionally adds unit testing in Java to make sure we're not regressing this again.

Note: this restores the annotations that were removed by #4620



Co-authored-by: Alessio Placitelli <alessio.placitelli@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.