* VRFS-821 many changes for upload apis, mostly

This commit is contained in:
Seth Call 2013-12-17 19:44:30 +00:00
parent d97a960a0e
commit 8bd715c7ea
1 changed files with 30 additions and 0 deletions

View File

@ -0,0 +1,30 @@
-- there are no valid recordings and mixes at this time
DELETE FROM recorded_tracks;
DELETE FROM mixes;
-- store full path to s3 bucket for mix and recorded_track
ALTER TABLE recorded_tracks ADD COLUMN url varchar(1024) NOT NULL;
ALTER TABLE mixes ADD COLUMN url varchar(1024) NOT NULL;
-- greater than 64 bytes come back from amazon for upload ids
ALTER TABLE recorded_tracks ALTER COLUMN upload_id TYPE varchar(1024);
-- store offset on server
ALTER TABLE recorded_tracks ADD COLUMN file_offset bigint DEFAULT 0;
-- make length be a bigint, since it can in theory be that large
ALTER TABLE recorded_tracks ALTER COLUMN length TYPE bigint;
-- store the client's track_id in addition to our own
ALTER TABLE recorded_tracks ADD COLUMN client_track_id varchar(64) NOT NULL;
-- is a part being stored
ALTER TABLE recorded_tracks ADD COLUMN is_part_uploading BOOLEAN NOT NULL DEFAULT false;
-- track error counts for the recorded_track as whole
ALTER TABLE recorded_tracks ADD COLUMN upload_failures int NOT NULL DEFAULT 0;
-- track error counts for the current part
ALTER TABLE recorded_tracks ADD COLUMN part_failures int NOT NULL DEFAULT 0;