6b1640b753
feat(observability): Replace Prometheus package with OpenTelemetry
2022-06-18 17:48:16 +02:00
a2ea89ff96
fix(api): broken tests after linting fix
2022-06-11 22:55:13 +02:00
84cf3391f1
chore(deps): update typescript-eslint monorepo to v5
2022-06-11 19:21:00 +02:00
ee5bd41a37
feat(api): configurable max pool connections
...
This should help with failing health checks while the crawler is running.
Quick math: 10 users, 30 songs each, each song requires at least 3
queries => 900 db queries every minute.
With the default of 10 pool connections, this blocks all available db
bandwidth for some time and causes slow UI and failing healthchecks.
2022-06-11 19:21:00 +02:00
7de5e14d4e
fix(health): remove faulty health check to spotify-auth
...
The endpoint returns a 503 OFTEN (~1x per hour), which causes unnecessary
service restarts and issues in sentry.
2022-06-11 19:21:00 +02:00
f06b93efbe
fix(health): use not-deprecated sentry context
...
The setExtra function is deprecated in favor of setContext. Also update
sentry-related packages.
2022-06-11 19:21:00 +02:00
dbf4374aeb
fix(health): send healthcheck result to sentry to improve debugging
2022-06-11 14:02:48 +02:00
a0ffe108e1
feat(api): update existing artists in MusicLibrary
2021-11-21 15:53:49 +01:00
a0c28e2324
feat: top genres report
2021-11-21 15:53:49 +01:00
Renovate Bot
19d7700696
chore(deps): update dependency passport-spotify to v2
2021-08-15 16:14:52 +02:00
Renovate Bot
a3c6da2749
chore(deps): update nest monorepo
2021-08-12 17:08:23 +02:00
e476243b85
test: create initial unit tests
2021-07-18 21:57:38 +02:00
3695fb7182
refactor(api): replace deprecated DNSHealthCheck
2021-06-22 21:06:35 +02:00
73bba4ef68
refactor(api): remove deprecated function and rename exception
2021-06-22 20:34:55 +02:00
3c6f3289f1
feat(server): save genres for artists and albums
...
This can later be used for reports
2021-05-25 19:23:42 +02:00
9b96d0fab4
chore(lint): switch to eslint
2021-05-25 18:12:42 +02:00
f56548e432
chore: run prettier format
2021-05-25 16:02:00 +02:00
51fd78f6d9
feat: add top tracks report
2021-05-22 15:10:05 +02:00
0c2188c4d4
fix(api): continue crawling when access token refresh fails for one user
2021-05-20 19:19:24 +02:00
879c6a62e2
feat: add optional basic auth for metrics endpoint
2020-12-06 03:03:33 +01:00
66fd6ce1b4
feat(api): custom spotify crawler interval
2020-11-28 18:28:38 +01:00
97f5ef70ac
refactor(api): improve function naming in spotify source
2020-11-28 17:56:49 +01:00
5ca3437b59
fix(api): missed listens from spotify
...
Listory could miss some listens when the Spotify Api misbehaves.
Sometimes the listens added to the last-recently-played endpoint
are showing up are out-of-order.
Because of our optimization to only retrieve listens newer than
the lastRefreshTime we would skip retrieving those out-of-order listens.
By always retrieving the maximum 50 listens we can be reasonably
sure that we got all the listens.
We also had to improve the handling of duplicate listens, as we now
have a lot of them, curtesy of removing the lastRefreshTime
optimization.
2020-11-28 17:55:19 +01:00
e2056b4734
feat(api): add prometheus metrics
...
Currently we support metrics for the Node.js runtime and HTTP endpoints.
2020-11-21 19:55:53 +01:00
9869f0a061
refactor(api): improve logging around spotify crawling loop
2020-11-21 17:43:04 +01:00
fcc2f7d1b6
fix(api): db error on duplicate music library import
...
When the spotify crawler loop would import an artist multiple
times in parallel the first would succeed but the following queries
would throw with following exception:
QueryFailedError: duplicate key value violates unique constraint "IDX_ARTIST_SPOTIFY_ID"
This error also could happen for the album or track.
2020-11-21 17:00:33 +01:00
49b31e8e62
fix(api): exception after refreshing spotify access token
2020-11-18 21:13:16 +01:00
56db4cd2e1
feat(api): setup optional sentry error reporting
2020-11-17 22:26:08 +01:00
9896ea31ff
feat: introduce new report "Top Albums"
2020-11-15 02:43:23 +01:00
09858076bf
refactor(api): optimize imports
2020-11-15 02:37:01 +01:00
427964f255
refactor(api): remove unused constant
2020-11-15 02:36:44 +01:00
44f7e26270
feat: implement long-lived sessions
2020-11-09 18:34:23 +01:00
5fb8a99a56
refactor: fix import relative paths
2020-09-05 21:07:05 +02:00
fb9b83d440
fix(server): improve listens report response time
...
Do not unnecessarily join too many relations
2020-07-12 17:53:31 +02:00
67ea28aec7
refactor: use TimeOptions for Listens report
2020-07-12 17:53:31 +02:00
5bc76f23d0
refator: use TimeOptions for TopArtists report
2020-07-12 17:53:31 +02:00
ad0d197105
refactor(server): do not export listen repository to outside modules
2020-07-12 17:53:31 +02:00
11af91cadb
refactor(server): introduce scoped query builders for recurring filters
2020-07-12 17:53:31 +02:00
f56218602e
fix: remove debug logging
2020-07-11 19:48:18 +02:00
aecc82576a
fix: improve top-artists response time
...
By calculating the necessary counts in the database, we avoid
unncessary joins and data transmissions.
2020-07-11 19:35:36 +02:00
6fc10c40ca
feat: add top-artists report
2020-07-04 21:56:27 +02:00
b8918889a1
refactor(server): introduce TimePresets for reports
2020-06-01 21:19:50 +02:00
6f8fc0265a
fix(server): validate listens report query params
...
When using Omit<>, class-validator can not see the decorators of the base
type and skips validation.
2020-06-01 21:19:50 +02:00
8c5f495ce5
fix(api): frontend sessions expire after 15 minutes (now 1d)
2020-05-13 21:23:57 +02:00
3828b841c2
feat(api): add listen report endpoint
2020-05-09 19:24:17 +02:00
ddcdfff89b
feat(api): enable global ValidationPipeline
2020-05-09 19:24:17 +02:00
c9030937e2
feat(api): filter recent listens by timespan
2020-05-09 19:24:17 +02:00
75d3e2edbd
feat: add docs and polish
2020-05-03 21:10:31 +02:00
a27fcce03b
feat(api): add optional spotify user whitelist
2020-05-03 21:10:31 +02:00
a7c5c68540
feat(api): setup database migrations
2020-05-03 21:10:31 +02:00