Skip to content
This repository has been archived by the owner on Feb 20, 2023. It is now read-only.

[Telemetry] Add Adjust campaignID to metrics ping #1298

Closed
bbinto opened this issue Apr 1, 2019 · 18 comments
Closed

[Telemetry] Add Adjust campaignID to metrics ping #1298

bbinto opened this issue Apr 1, 2019 · 18 comments
Assignees
Labels
E8 Estimation Point: about 8 days eng:qa:verified QA Verified Feature:Telemetry
Milestone

Comments

@bbinto
Copy link
Contributor

bbinto commented Apr 1, 2019

It was identified that some basic / core pings are not included "for free" in the new Glean SDK baseline ping. This ticket is about including the additional pings product wants to track

Description & Product Manager

  • As a product marketing manager, I want to know from what campaign users installed the app from.

What questions will you answer with this data?

  • By knowing what cohort/campaign the user came from allows us to understand their usage better

Why does Mozilla need to answer these questions? Are there benefits for users? Do we need this information to address product or business requirements?

  • Be able to understand from what campaign users came from

What probes (suggested, if applicable)

Dependencies (Added by PM and Eng)

  • Core ping / baseline ping, see comment here

Acceptance Criteria (Added by PM)

  • Baseline pings can be queried via re:dash
  • We are sending telemetry events for the actions listed in the requirements
  • We have documented the telemetry
  • We have asked a data steward to review the telemetry
  • NOT an AC: Data science to create dashboard or further graphs (this will be a separate issue, this issue is only about hooking up the events described and that they can be queried in re-dash)

┆Issue is synchronized with this Jira Task

@bbinto
Copy link
Contributor Author

bbinto commented Apr 17, 2019

@vesta0 this can wait until after Beta

@vesta0 vesta0 added this to High priority backlog in Fenix Sprint Kanban Apr 30, 2019
@bifleming bifleming moved this from High priority backlog (not in the current sprint) to Ready for Dev in Fenix Sprint Kanban May 10, 2019
@bifleming bifleming added the Release Blocker Blocks a Release label May 17, 2019
@vesta0 vesta0 added P2 Upcoming release and removed P1 Current sprint Release Blocker Blocks a Release labels May 20, 2019
@vesta0 vesta0 removed this from Ready for Dev in Fenix Sprint Kanban May 23, 2019
@vesta0 vesta0 modified the milestones: MVP Backlog, Fenix 1.1 Backlog May 23, 2019
@vesta0 vesta0 removed P2 Upcoming release labels Jun 7, 2019
@vesta0 vesta0 added the must label Jul 3, 2019
@vesta0 vesta0 added the E5 Estimation Point: about 5 days label Jul 24, 2019
sblatz added a commit to sblatz/fenix that referenced this issue Oct 23, 2019
@liuche
Copy link
Contributor

liuche commented Oct 25, 2019

We're getting close, but there are problems with our Adjust integration. Will keep working w/ Loren on this. We should keep pushing on this because it's important.

Allocating another E2 for this sprint starting 10/28.

sblatz added a commit to sblatz/fenix that referenced this issue Oct 28, 2019
sblatz added a commit to sblatz/fenix that referenced this issue Oct 28, 2019
sblatz added a commit to sblatz/fenix that referenced this issue Oct 28, 2019
sblatz added a commit to sblatz/fenix that referenced this issue Oct 28, 2019
@sblatz
Copy link
Contributor

sblatz commented Oct 28, 2019

For QA to test this, please take the following steps:

Before beginning: Retrieve your Google Advertising ID. You can find this in the "Adjust Insights" app on the google play store. Also, make sure the device you're using has not previously installed Fenix. if it has, ask me to remove your device's information from the adjust dashboard.

  1. Make sure no versions of Firefox Preview are installed on your device.

  2. Replace GOOGLE_ADVERTISING_ID in the link below with your advertising ID.
    For example:
    f8bc12a4-932a-4a16-a959-4f5626fc3402 becomes
    https://app.adjust.com/ou6v41x?campaign=social&adgroup=twitter&creative=fr-gtm&gpsadid=f8bc12a4-932a-4a16-a959-4f5626fc3402
    https://app.adjust.com/ou6v41x?campaign=social&adgroup=twitter&creative=fr-gtm&gpsadid=GOOGLE_ADVERTISING_ID

  3. Click that link on the device you're wanting to test. It should redirect you to the play store. Do NOT install Fenix from the play store.

  4. Grab the APK for your device here and install it: https://tools.taskcluster.net/groups/b-q2a5bCRWK86nFalo0OUw/tasks/DwAyxjSQSUSB961ogktnrw/runs/0/artifacts (let me know if you don't have permission to see this)

  5. Launch the app. Wait 10 seconds on the home screen

  6. Force close the app and launch it again. The metric should now be sent in the core ping.

@sblatz sblatz added the eng:qa:needed QA Needed label Oct 29, 2019
@project-bot project-bot bot moved this from In Progress to Ready for QA in Fenix Sprint Kanban Oct 29, 2019
@AndiAJ
Copy link
Collaborator

AndiAJ commented Nov 1, 2019

Hi, @sblatz when trying to launch the app I've noticed this error in the log:

8625-8625/org.mozilla.fenix.debug E/glean/GleanDebugActivity: Glean is not initialized. It may be disabled by the application.

Please be kind and create a debug APK that has Glean enabled.

@sblatz
Copy link
Contributor

sblatz commented Nov 5, 2019

@AndiAJ
Copy link
Collaborator

AndiAJ commented Nov 6, 2019

@sblatz - I've retried with the new debug build you've sent but I've bumped in this startup crash:

--------- beginning of crash
2019-11-06 11:47:00.733 15453-15487/org.mozilla.fenix.debug E/AndroidRuntime: FATAL EXCEPTION: Gecko
   Process: org.mozilla.fenix.debug, PID: 15453
   java.lang.Exception: Error loading gecko libraries
       at org.mozilla.gecko.mozglue.GeckoLoader.loadGeckoLibsNative(Native Method)
       at org.mozilla.gecko.mozglue.GeckoLoader.loadGeckoLibs(GeckoLoader.java:478)
       at org.mozilla.gecko.GeckoThread.loadGeckoLibs(GeckoThread.java:271)
       at org.mozilla.gecko.GeckoThread.initGeckoEnvironment(GeckoThread.java:289)
       at org.mozilla.gecko.GeckoThread.run(GeckoThread.java:448)
2019-11-06 11:47:00.733 15453-15487/org.mozilla.fenix.debug I/mozac/CrashReporter: Received crash: UncaughtExceptionCrash(throwable=java.lang.Exception: Error loading gecko libraries, breadcrumbs=[])
2019-11-06 11:47:00.735 15453-15487/org.mozilla.fenix.debug I/mozac/CrashReporter: Showing prompt
2019-11-06 11:47:00.743 1177-4689/? I/ActivityManager: START u0 {flg=0x10018000 cmp=org.mozilla.fenix.debug/mozilla.components.lib.crash.prompt.CrashReporterActivity (has extras)} from uid 10177
2019-11-06 11:47:00.748 768-768/? D/android.hardware.power@1.3-service.bonito-libperfmgr: LAUNCH ON
2019-11-06 11:47:00.759 15453-15487/org.mozilla.fenix.debug I/Process: Sending signal. PID: 15453 SIG: 9
2019-11-06 11:47:00.763 1177-1198/? W/BroadcastQueue: Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.stats.service.DropBoxEntryAddedReceiver
2019-11-06 11:47:00.763 1177-1198/? W/BroadcastQueue: Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.chimera.GmsIntentOperationService$PersistentTrustedReceiver
2019-11-06 11:47:00.775 691-691/? I/Zygote: Process 15453 exited due to signal (9)
2019-11-06 11:47:00.775 1177-3950/? I/ActivityManager: Process org.mozilla.fenix.debug (pid 15453) has died: fore TOP
2019-11-06 11:47:00.775 1177-1201/? W/libprocessgroup: kill(-15453, 9) failed: No such process
2019-11-06 11:47:00.775 1177-1201/? I/libprocessgroup: Successfully killed process cgroup uid 10177 pid 15453 in 0ms
2019-11-06 11:47:00.779 571-608/? W/SurfaceFlinger: Attempting to set client state on removed layer: Splash Screen org.mozilla.fenix.debug#0
2019-11-06 11:47:00.779 571-608/? W/SurfaceFlinger: Attempting to destroy on removed layer: Splash Screen org.mozilla.fenix.debug#0
2019-11-06 11:47:00.780 1177-1320/? W/WindowManager: Failed looking up window callers=com.android.server.wm.WindowManagerService.windowForClientLocked:5512 com.android.server.wm.WindowManagerService.removeWindow:1641 com.android.server.wm.Session.remove:226
2019-11-06 11:47:00.797 1177-1197/? I/ActivityManager: Displayed org.mozilla.fenix.debug/mozilla.components.lib.crash.prompt.CrashReporterActivity: +1s384ms
2019-11-06 11:47:00.802 1177-1200/? I/ActivityManager: Start proc 15499:org.mozilla.fenix.debug:mozilla.components.lib.crash.CrashReporter/u0a177 for activity org.mozilla.fenix.debug/mozilla.components.lib.crash.prompt.CrashReporterActivity
`

@severinrudie severinrudie mentioned this issue Nov 6, 2019
30 tasks
@AndiAJ AndiAJ removed the eng:qa:needed QA Needed label Nov 7, 2019
@project-bot project-bot bot moved this from Ready for QA to Sprint Backlog in Fenix Sprint Kanban Nov 7, 2019
@AndiAJ
Copy link
Collaborator

AndiAJ commented Nov 7, 2019

Hi @sblatz good news! The last debug build you've sent works! 😃

On the other hand, I've generated two metrics pings and it looks like the "metrics.adjust_campaign": doesn't get populated, in my case with 06c7a972-acf2-480a-8a9f-c865d1cfa1e9 (Google advertising ID from the Adjust Insights app)

Glean dashboard

I'll remove the QA needed label until further notice.

From the Logcat :

2019-11-08 04:00:00.189 8956-9132/org.mozilla.fenix.debug D/glean/PingUploadWorker: Processing persisted pings at /data/user/0/org.mozilla.fenix.debug/glean_data/pending_pings
2019-11-08 04:00:00.190 8956-9132/org.mozilla.fenix.debug D/glean/PingUploadWorker: Processing ping: 796ea639-8f2d-4e9e-bae5-7ba4145b1df0
2019-11-08 04:00:00.198 8956-9132/org.mozilla.fenix.debug D/glean/BaseUploader: Glean ping to URL: /submit/org-mozilla-fenix-debug/metrics/1/796ea639-8f2d-4e9e-bae5-7ba4145b1df0
    {
      "client_info": {
        "android_sdk_version": "28",
        "app_build": "1",
        "app_channel": "release",
        "app_display_version": "1.0.1945",
        "architecture": "arm64-v8a",
        "client_id": "7cfa1d49-4270-4432-8376-433e14dbcb30",
        "device_manufacturer": "Google",
        "device_model": "Pixel 3a XL",
        "first_run_date": "2019-11-07+02:00",
        "os": "Android",
        "os_version": "9",
        "telemetry_sdk_build": "19.1.0"
      },
      "metrics": {
        "boolean": {
          "metrics.default_browser": false
        },
        "string": {
          "metrics.adjust_campaign": "",
          "metrics.total_uri_count": "0"
        },
        "string_list": {
          "metrics.mozilla_products": [
            "org.mozilla.firefox"
          ]
        }
      },
      "ping_info": {
        "end_time": "2019-11-08T04:00+02:00",
        "ping_type": "metrics",
        "seq": 1,
        "start_time": "2019-11-07T14:39+02:00"
      }
    }
2019-11-08 04:00:00.209 8956-9132/org.mozilla.fenix.debug D/glean/ConceptFetchHttpUploader: Submitting ping to: https://incoming.telemetry.mozilla.org/submit/org-mozilla-fenix-debug/metrics/1/796ea639-8f2d-4e9e-bae5-7ba4145b1df0
2019-11-08 04:00:01.250 8956-9132/org.mozilla.fenix.debug D/glean/ConceptFetchHttpUploader: Ping successfully sent (200)
___________________________________________________________________________________________________________

2019-11-09 04:00:00.157 9247-9418/org.mozilla.fenix.debug D/glean/PingUploadWorker: Processing persisted pings at /data/user/0/org.mozilla.fenix.debug/glean_data/pending_pings
2019-11-09 04:00:00.158 9247-9418/org.mozilla.fenix.debug D/glean/PingUploadWorker: Processing ping: 454575a7-f266-4289-9b3e-99fa8fddcfb0
2019-11-09 04:00:00.165 9247-9418/org.mozilla.fenix.debug D/glean/BaseUploader: Glean ping to URL: /submit/org-mozilla-fenix-debug/metrics/1/454575a7-f266-4289-9b3e-99fa8fddcfb0
    {
      "client_info": {
        "android_sdk_version": "28",
        "app_build": "1",
        "app_channel": "release",
        "app_display_version": "1.0.1945",
        "architecture": "arm64-v8a",
        "client_id": "7cfa1d49-4270-4432-8376-433e14dbcb30",
        "device_manufacturer": "Google",
        "device_model": "Pixel 3a XL",
        "first_run_date": "2019-11-07+02:00",
        "os": "Android",
        "os_version": "9",
        "telemetry_sdk_build": "19.1.0"
      },
      "metrics": {
        "boolean": {
          "metrics.default_browser": false
        },
        "string": {
          "metrics.adjust_campaign": "",
          "metrics.total_uri_count": "0"
        },
        "string_list": {
          "metrics.mozilla_products": [
            "org.mozilla.firefox"
          ]
        }
      },
      "ping_info": {
        "end_time": "2019-11-09T04:00+02:00",
        "ping_type": "metrics",
        "seq": 2,
        "start_time": "2019-11-08T04:00+02:00"
      }
    }
2019-11-09 04:00:00.170 9247-9418/org.mozilla.fenix.debug D/glean/ConceptFetchHttpUploader: Submitting ping to: https://incoming.telemetry.mozilla.org/submit/org-mozilla-fenix-debug/metrics/1/454575a7-f266-4289-9b3e-99fa8fddcfb0
2019-11-09 04:00:00.384 9247-9418/org.mozilla.fenix.debug D/glean/ConceptFetchHttpUploader: Ping successfully sent (200)
`

@AndiAJ AndiAJ added the eng:qa:verified QA Verified label Nov 7, 2019
@AndiAJ
Copy link
Collaborator

AndiAJ commented Nov 7, 2019

Hi, verified as fixed on the latest debug build sent by Sawyer.

   "string": {
          "metrics.adjust_campaign": "social",
          "metrics.total_uri_count": "0"
        },

Logcat
Glean dashboard

@sblatz - Great job! 😄

@AndiAJ AndiAJ closed this as completed Nov 7, 2019
Fenix Q4 Feature Backlog automation moved this from Must to Done! Nov 7, 2019
@project-bot project-bot bot moved this from Sprint Backlog to Sprint 11.1 Done in Fenix Sprint Kanban Nov 7, 2019
@severinrudie severinrudie added this to the v3.0 milestone Nov 7, 2019
@data-sync-user data-sync-user changed the title [Telemetry] Add Adjust campaignID to metrics ping FNX2-16996 ⁃ [Telemetry] Add Adjust campaignID to metrics ping Aug 3, 2020
@data-sync-user data-sync-user changed the title FNX2-16996 ⁃ [Telemetry] Add Adjust campaignID to metrics ping FNX3-15461 ⁃ [Telemetry] Add Adjust campaignID to metrics ping Aug 11, 2020
@data-sync-user data-sync-user changed the title FNX3-15461 ⁃ [Telemetry] Add Adjust campaignID to metrics ping FNX-455 ⁃ [Telemetry] Add Adjust campaignID to metrics ping Aug 11, 2020
@data-sync-user data-sync-user changed the title FNX-455 ⁃ [Telemetry] Add Adjust campaignID to metrics ping FNX2-16996 ⁃ [Telemetry] Add Adjust campaignID to metrics ping Aug 11, 2020
@data-sync-user data-sync-user changed the title FNX2-16996 ⁃ [Telemetry] Add Adjust campaignID to metrics ping [Telemetry] Add Adjust campaignID to metrics ping May 19, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
E8 Estimation Point: about 8 days eng:qa:verified QA Verified Feature:Telemetry
Projects
No open projects
Development

No branches or pull requests

10 participants