Simplify sentry logic for :lang substitutions

RESOLVED FIXED

Status

P3
normal
RESOLVED FIXED
2 years ago
11 months ago

People

(Reporter: nthomas, Assigned: oremj)

Tracking

Trunk
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 obsolete attachment)

(Reporter)

Description

2 years ago
We have this complicated logic for how sentry should replace :lang to check locations. It's from the days we had volunteer mirrors and they would rsync files in, possibly slowly and often after we had shipped, and we'd wait until they had the last locale before enabling them for a product. Last in the alphabetical-sort sense, so usually zh-TW.

These days the CDNs have all or none of the files, and we set that up before shipping, so we can just use en-US since that's reliably present.
(Reporter)

Comment 1

2 years ago
Created attachment 8889723 [details] [review]
Use en-US for all :lang substitutions
Attachment #8889723 - Flags: review?(oremj)
(Reporter)

Updated

2 years ago
See Also: → bug 1351985
(Assignee)

Comment 2

2 years ago
We are running the sentry here: https://github.com/mozilla-services/go-bouncer/tree/master/go-sentry. I can look in to porting your patch though, thanks!
(Assignee)

Comment 4

2 years ago
I'm wondering if we even need sentry anymore. We control bouncer, the CDN and mozilla.org, so there probably isn't a good reason to check, via sentry, that the file is actually in place.
(Reporter)

Updated

2 years ago
Attachment #8889723 - Attachment is obsolete: true
Attachment #8889723 - Flags: review?(oremj)
(Reporter)

Comment 5

2 years ago
So, in practical terms bouncer would enable new locations as soon as they were added, and would serve a 302. If the location isn't present yet, or someone made a typo, then we'd get a 404 from the CDN rather than bouncer  ?
(Assignee)

Comment 6

2 years ago
Yes, exactly. It would just redirect to its configured location always.
(Reporter)

Comment 7

2 years ago
I can't think of any reasons that would be a problem, but will check with other people in RelEng. Either way I probably won't be the one touching the code.
Assignee: nthomas → nobody
Flags: needinfo?(nthomas)
Currently spinning 2.49.1 and will most likely hit the issue as mentioned in https://bugzilla.mozilla.org/show_bug.cgi?id=1351985#c8.  

That said..  

I'll do a pr against https://github.com/mozilla-services/go-bouncer/blob/master/go-sentry/sentry/sentry.go#L124
(Assignee)

Comment 9

a year ago
nthomas, ewong: can you both review https://github.com/mozilla-services/go-bouncer/pull/175
Flags: needinfo?(ewong)
(In reply to Jeremy Orem [:oremj] from comment #9)
> nthomas, ewong: can you both review
> https://github.com/mozilla-services/go-bouncer/pull/175

done.
Flags: needinfo?(ewong)
(Reporter)

Comment 11

a year ago
The PR lgtm.
Flags: needinfo?(nthomas)
:oremj,  would you happen to have merged the PR to production (or whatever
the right terminology is)?
c.f. c#12
Flags: needinfo?(oremj)
(Assignee)

Comment 14

a year ago
No, I plan on doing a deploy next week.
Flags: needinfo?(oremj)
(In reply to Jeremy Orem [:oremj] from comment #14)
> No, I plan on doing a deploy next week.

:oremj, has this been deployed to production?
Flags: needinfo?(oremj)
Blocks: 1402214
(Assignee)

Updated

11 months ago
Assignee: nobody → oremj
Depends on: 1437565
(Assignee)

Comment 16

11 months ago
I'm hoping to roll this in to bug 1437565
Flags: needinfo?(oremj)
(In reply to Jeremy Orem [:oremj] from comment #16)
> I'm hoping to roll this in to bug 1437565

Good idea. I won't need to be concerned with dumping empty tr stuff to archive.mo anymore.
(Assignee)

Comment 18

11 months ago
Sentry has been disabled. I think we can call this fixed.
Status: NEW → RESOLVED
Last Resolved: 11 months ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.