summaryrefslogtreecommitdiffstats
path: root/config/sql (follow)
AgeCommit message (Collapse)Author
2022-01-22Specify the public schema for public videosTony Finn
Unlike the other migrations, this one uses a bare table name to specify the table. This means it looks in the default search path. Unfortunately, the out of box search path is: 1. Schema with the same name as the user 2. Public Because of this, if a schema exists with the same name as the DB user, the playlist_videos table will get created in _that_ schema, rather than the public schema, and then the grant statement will fail with an error like below if check_table is enabled as it keeps trying to create the table but failing on the grant statement: ``` 2022-01-22 02:27:42 UTC [info] check_table: check_table: CREATE TABLE playlist_videos Unhandled exception: relation "public.playlist_videos" does not exist (PQ::PQError) from /usr/share/crystal/src/primitives.cr:266:3 in 'handle_error' from lib/pg/src/pq/connection.cr:184:9 in 'handle_async_frames' from lib/pg/src/pq/connection.cr:162:7 in 'read' from lib/pg/src/pq/query.cr:53:14 in 'exec_all' from lib/db/src/db/database.cr:126:9 in '__crystal_main' from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main' from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2' 2022-01-22 02:27:43 UTC [info] check_table: check_table: CREATE TABLE playlist_videos Unhandled exception: relation "public.playlist_videos" does not exist (PQ::PQError) from /usr/share/crystal/src/primitives.cr:266:3 in 'handle_error' from lib/pg/src/pq/connection.cr:184:9 in 'handle_async_frames' from lib/pg/src/pq/connection.cr:162:7 in 'read' from lib/pg/src/pq/query.cr:53:14 in 'exec_all' from lib/db/src/db/database.cr:126:9 in '__crystal_main' from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main' from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2' ```
2022-01-09Create videos caching table as UNLOGGEDÉmilien Devos
2021-01-17Make migrations (mostly) idempotent.Andre Borie
2020-06-15Add support for polymer redesignOmar Roth
2020-04-14Move privacy type into playlists.sqlOmar Roth
2019-10-15Add support for custom playlistsOmar Roth
2019-06-01Add 'needs_update' column for scheduling feed refreshOmar Roth
2019-05-30Add 'views' to channel_videosOmar Roth
2019-04-28Remove unnecessary indexOmar Roth
2019-04-15Add config option to cache annotations from IAOmar Roth
2019-03-22Add support for premieres to search and feedOmar Roth
2019-03-03Update pubsub to support lease_secondsOmar Roth
2019-02-11Update change index for channel_videos and add index for noncesOmar Roth
2019-02-10Fix typo in session_idsOmar Roth
2019-02-10Add migrate script and update READMEOmar Roth
2019-02-10Store session_ids in separate tableOmar Roth
2019-02-09Add 'deleted' to channel infoOmar Roth
2018-11-20Fix typo in nonces.sqlOmar Roth
2018-11-19Add 'expire' to filter invalid tokensOmar Roth
2018-11-17Remember nonce to prevent replay attacksOmar Roth
2018-11-02Update SQLOmar Roth
2018-10-30Fix channel_videos schemaOmar Roth
2018-10-30Add length_seconds to channel_videosOmar Roth
2018-10-13Add author_thumbnail to '/api/v1/videos'Omar Roth
2018-10-12Add subCountText and add XHR alternative for subscribing to channelsOmar Roth
2018-09-21Use hash instead of btree for channel_videos_ucid_idxOmar Roth
2018-09-09Add 'license'Omar Roth
2018-09-04Update SQL and remove migration pointsOmar Roth
2018-08-15Remove ID constrant for usersOmar Roth
2018-08-15Add support for multiple sessionsOmar Roth
2018-07-29Add watch historyOmar Roth
2018-07-27Add ucid index for channel_videosOmar Roth
2018-07-26Update videos SQLOmar Roth
2018-07-20Update users.sqlOmar Roth
2018-07-18Add separate user accountsOmar Roth
2018-07-18Fix typo in users.sqlOmar Roth
2018-07-16Add user preferencesOmar Roth
2018-06-01Move author and ucid into schemaOmar Roth
2018-03-31Add notificationsOmar Roth
2018-03-31Add email to user tableOmar Roth
2018-03-29Make user id uniqueOmar Roth
2018-03-29Add users tableOmar Roth
2018-03-28Use seperate table for videos pulled from RSSOmar Roth
2018-03-24Add channel sqlOmar Roth