Unnecessary "text" data type on statistics DB table

RESOLVED INVALID

Status

--
minor
RESOLVED INVALID
9 years ago
3 years ago

People

(Reporter: dre, Assigned: clouserw)

Tracking

unspecified

Details

The download_counts table was altered in bug 516044 to add a new column, "src".  This column was requested as size TEXT, and I just wanted to call out that is way too large of a size for it.

The Metrics ETL process that populates the column restricts the input to 70 characters, so you could safely resize it as VARCHAR(70) and not risk losing any data.

The downsides of storing it as text are:
1. Indexing is much more expensive
2. text data is stored in a separate area making queries that return text and non-text data much more inefficient
3. General bloat of the DB.
(Assignee)

Updated

9 years ago
Assignee: nobody → clouserw
Target Milestone: --- → 5.3
Oops.  Turns out I was mistaken about the type of data that was supposed to be stored in this field.  I thought it was single values, but fligtar was expecting it to be a serialized JSON blob.  Given that, the TEXT data type makes more sense.
Status: NEW → RESOLVED
Last Resolved: 9 years ago
Resolution: --- → INVALID
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.