Skip to content

Conversation

@mashalifshin
Copy link
Contributor

@mashalifshin mashalifshin commented Jan 13, 2026

Tickets or other relevant links:

https://mozilla-hub.atlassian.net/browse/AE-1142

What's Here

In preparation for rolling out OHTTP between Desktop FFox and MARS, we need to capture all the ad client's geo fields in all our pings -- specifically the interaction and request-stats ping.

Things I'd Like Feedback On

Lmk if you see any issues with capturing this. Looks like it is already available in the backend.

Testing

This can be tested via the companion PR in MARS that use the updated pings structure, see the Testing section there.

Any concerns with backwards compatibility?

No, these changes are additive.

@mashalifshin mashalifshin requested a review from a team as a code owner January 13, 2026 18:06
@mashalifshin mashalifshin force-pushed the ae-1142-add-geo-info-to-interaction-ping branch from 16fb96b to d5a6075 Compare January 13, 2026 19:16
@mashalifshin mashalifshin changed the title [AE-1142] Include ad client country, region, and dma codes in the interaction and request-stats pings [AE-1142] Include ad client country, region, and dma in the interaction and request-stats pings Jan 15, 2026
Copy link
Collaborator

@gleonard-m gleonard-m left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was a data collection review created for this?

@mashalifshin
Copy link
Contributor Author

Was a data collection review created for this?

No I didn't do a data review for this change, is it needed? My thought was we're already collecting this data in other pings, and in some cases in other fields of the same ping, but I'm happy to kick that off now if necessary

Comment on lines +299 to +308
country_code:
type: string
description: >
Country code (ISO 3166-1 alpha-2 format) associated with the client when the ad was requested.
Should not be null.
lifetime: application
send_in_pings:
- interaction
- provider-request-stats
- request-stats
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

country code is already in the interaction ping, looks like we have two metrics with the same name but under different groups

country_code:
type: string
description: >
Country code associated with the client when the ad was requested.
Should not be null.
lifetime: application
send_in_pings:
- interaction
- request-stats

send_in_pings:
- interaction
- provider-request-stats
- request-stats
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

similar for region code, we have a separately named metric in these pings

region_code:
type: string
description: >
Region code associated with the client when the ad was requested. May
be null.
lifetime: application
send_in_pings:
- interaction
- request-stats
notification_emails:

Comment on lines +342 to +344
- interaction
- provider-request-stats
- request-stats
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 I don't see dma code present on interaction or request-stats yet. One thing that may be annoying about glean is that the fields in the table get named based on the groupings in the schema, so this would make the interactions table have field ad.country_code, ad.region_code, and ad_client.dma. maybe not a real issue since the existing fields are already an arbitrary seeming mixture of prefixes https://dictionary.telemetry.mozilla.org/apps/ads_backend/pings/interaction?page=1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants