Expose Nightly updates status to public website

NEW
Assigned to

Status

a year ago
a year ago

People

(Reporter: jlorenzo, Assigned: asilva)

Tracking

({good-first-bug})

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

PR
51 bytes, text/x-github-pull-request
jlorenzo
: feedback+
Details | Review | Splinter Review
(Reporter)

Description

a year ago
Nightly users sometimes would like to know why updates are frozen.

Thanks to bug 1325377, we now have the list of rules available as JSON at [1]. We can use it to make a public status page, like on [2]. This way, Nightly users will:
 * See on which build they should be 
 * See the comment placed on balrog. This comment usually points to a bug, with more context.

Regarding the technical implementation, we can first read the status of that rule[3]. This rule is usually the one we change when freezing updates. If mapping equals "Firefox-mozilla-central-nightly-latest", then updates are live. Otherwise, we can look at the comment value, and show it[4].

We can use mozilla-releng.net to host this service. In this case, the website has to live in the services repo[5].


[1] https://aus5.mozilla.org/api/v1/rules. You can play with the REST API at https://aus5.mozilla.org/ui/ 
[2] https://mozilla-releng.net/treestatus
[3] https://aus5.mozilla.org/api/v1/rules/3
[4] Disclaimer: This rule is not always accurate. For instance, as of today, a "watershed" rule (https://aus5.mozilla.org/api/v1/rules/622) guards 90% of the nightly users at Build ID 20170730100307. This won't be the case in the next few days.
[5] https://github.com/mozilla-releng/services
(Reporter)

Updated

a year ago
Keywords: good-first-bug
(Assignee)

Comment 1

a year ago
Hey Johan,

To get the right rule, is necessary check if channel is the "nightly" channel?

In this moment the rule mapping to "Firefox-mozilla-central-nightly-latest" is from the "nightlytest" channel:
{
  ...
  "channel": "nightlytest",
  "comment": null,
  ...
  "mapping": "Firefox-mozilla-central-nightly-latest",
  ...
}
The rule to consider can be for "nightly" or "nightly*", but "nightlytest" should be discarded, yes.
(Assignee)

Comment 3

a year ago
Do you have in mind how the page will be?
I'll like to implement the first Public AUS api client if you want.
(Reporter)

Comment 4

a year ago
Hey Allan! 

Nice, thank you very much for you interest :) 

I think we can keep the page simple, at first. Something like:

> +------------------------------------------------------------------------------------+ 
> | Mozilla Releng Header                                                              |
> +------------------------------------------------------------------------------------+
> |                                                                                    |
> |                                                                                    |
> |     [Normal text] Nightly updates are currently                                    |
> |     [Big text] Frozen to [Build ID]/Serving the latest nightly [Build ID]          |
> |                                                                                    |
> |     [Normal text if frozen] Frozen because of: "[Balrog comment + Bugzilla link]"  |
> |                                                                                    |
> |                                                                                    |
> +------------------------------------------------------------------------------------+
> | Mozilla Releng Footer                                                              |
> +------------------------------------------------------------------------------------+

Do you think this page would have enough information for the Nightly community, Pascal?
Flags: needinfo?(pascalc)
That sounds good to me
Flags: needinfo?(pascalc)
This is a fantastic idea.

Some random thoughts:
* Please ensure https://aus-api.mozilla.org/api/v1 is used for this. Although aus5.mozilla.org has the API endpoints, aus-api is the official location.
* We should probably add an alias to the primary nightly channel rule to avoid querying by rule_id (which has a small potential of changing over time) or trying to guess what the correct rule is.
* We may want to check for throttle rate, and indicate whether or not things are throttled
* The buildid available may be different depending on the platform and locale (even when frozen). It's probably not necessary to handle this edge case immediately, but I'm sure it will cause confusion at some point. Down the road, maybe we can try to find the platform/locale in the User Agent, and look up information for that in the mapping pointed at by the Rule.
catlee was looking for an alias for the main Nightly rule, so I added it. https://aus-api.mozilla.org/api/v1/rules/firefox-nightly is a thing now.
(Assignee)

Updated

a year ago
Assignee: nobody → allan.tavares
(Assignee)

Comment 8

a year ago
Hey folks!
I started this bug and opened a PR, is not finished yet, how normally I work on bugs at weekend, I think that current code can be commented and I fix de issues next time I go back this. If you prefer the full patch, feel free to close the PR.

The basic communication flow with Balrog is ready, the default view is to Firefox Nightly, but I added support to other products/channels.
(Assignee)

Comment 9

a year ago
Created attachment 8906333 [details] [review]
PR
Attachment #8906333 - Flags: review?
You need to log in before you can comment on or make changes to this bug.