Closed
Bug 1001379
Opened 11 years ago
Closed 11 years ago
Add weight to JSONSnippet model
Categories
(Snippets :: Service, defect)
Snippets
Service
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: giorgos, Assigned: giorgos)
References
Details
(Whiteboard: [kb=1346111] )
* Add the same weight attribute to JSON (Fennec) Snippets
* Update the served JSON to include this information. New JSON will have the following format:
{"url": "https://mozilla.org",
"text": "This is text message for snippet #1. Links to mozilla.org",
"target_geo": "US", # optional
"id": 1,
"icon": "data:imag..."
"weight": 100 }
* 'weight' will be always present in JSON and will have a default value of 100
| Assignee | ||
Updated•11 years ago
|
OS: Linux → All
Hardware: x86_64 → All
| Assignee | ||
Updated•11 years ago
|
Whiteboard: [kb=1346111]
| Assignee | ||
Updated•11 years ago
|
Assignee: nobody → giorgos
Status: NEW → ASSIGNED
Comment 1•11 years ago
|
||
Commit pushed to master at https://github.com/mozilla/snippets-service
https://github.com/mozilla/snippets-service/commit/7d80edb8b1cddaed075275c2fc7cdf69a10f4003
[fix bug 1001379] Add JSONSnippet.weight.
Updated•11 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Comment 2•11 years ago
|
||
This is great!
Giorgos, let's hold any deploy of this until :dria or :margaret confirm that the client can handle the new JSON.
I updated the Snippet docs to include the data spec for this. Let's keep it up to date and/or improve it as this resource gets richer. https://wiki.mozilla.org/Firefox/Projects/Firefox_Start/Snippet_Service#Data_Specification
Flags: needinfo?(margaret.leibovic)
Comment 3•11 years ago
|
||
Adding an extra field to the snippets JSON won't break the client, so it should be fine to deploy that, but it would be good to test that before deploying.
I just filed bug 1002567 to add this support to the client.
Flags: needinfo?(margaret.leibovic)
| Assignee | ||
Comment 4•11 years ago
|
||
Verified on Fennec Release using snippet stage: Adding weight doesn't break the client. Pushing to prod
| Assignee | ||
Comment 5•11 years ago
|
||
Prod is up-to-date and Fennec Release still working. Yay!
Comment 6•11 years ago
|
||
Awesome! I also landed bug 1002567 on Nightly, so weights should work on Nightly now (Firefox 32).
You need to log in
before you can comment on or make changes to this bug.
Description
•