aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/initializers/constants.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-08-30 14:58:00 +0200
committerChocobozzz <me@florianbigard.com>2018-08-31 09:19:58 +0200
commit2d3741d6d92e9bd1f41694c7442a6d1da434e1f2 (patch)
tree93a1e609e14bc14ca9e77a6661ddc9c0e461d6f3 /server/initializers/constants.ts
parentd9eaee3939bf2e93e5d775d32bce77842201faba (diff)
downloadPeerTube-2d3741d6d92e9bd1f41694c7442a6d1da434e1f2.tar.gz
PeerTube-2d3741d6d92e9bd1f41694c7442a6d1da434e1f2.tar.zst
PeerTube-2d3741d6d92e9bd1f41694c7442a6d1da434e1f2.zip
Videos overview page: first version
Diffstat (limited to 'server/initializers/constants.ts')
-rw-r--r--server/initializers/constants.ts13
1 files changed, 13 insertions, 0 deletions
diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts
index 5d93c6b82..16d8dca68 100644
--- a/server/initializers/constants.ts
+++ b/server/initializers/constants.ts
@@ -58,6 +58,9 @@ const ROUTE_CACHE_LIFETIME = {
58 ROBOTS: '2 hours', 58 ROBOTS: '2 hours',
59 NODEINFO: '10 minutes', 59 NODEINFO: '10 minutes',
60 DNT_POLICY: '1 week', 60 DNT_POLICY: '1 week',
61 OVERVIEWS: {
62 VIDEOS: '1 hour'
63 },
61 ACTIVITY_PUB: { 64 ACTIVITY_PUB: {
62 VIDEOS: '1 second' // 1 second, cache concurrent requests after a broadcast for example 65 VIDEOS: '1 second' // 1 second, cache concurrent requests after a broadcast for example
63 } 66 }
@@ -464,6 +467,15 @@ const TORRENT_MIMETYPE_EXT = {
464 467
465// --------------------------------------------------------------------------- 468// ---------------------------------------------------------------------------
466 469
470const OVERVIEWS = {
471 VIDEOS: {
472 SAMPLE_THRESHOLD: 4,
473 SAMPLES_COUNT: 2
474 }
475}
476
477// ---------------------------------------------------------------------------
478
467const SERVER_ACTOR_NAME = 'peertube' 479const SERVER_ACTOR_NAME = 'peertube'
468 480
469const ACTIVITY_PUB = { 481const ACTIVITY_PUB = {
@@ -666,6 +678,7 @@ export {
666 USER_PASSWORD_RESET_LIFETIME, 678 USER_PASSWORD_RESET_LIFETIME,
667 USER_EMAIL_VERIFY_LIFETIME, 679 USER_EMAIL_VERIFY_LIFETIME,
668 IMAGE_MIMETYPE_EXT, 680 IMAGE_MIMETYPE_EXT,
681 OVERVIEWS,
669 SCHEDULER_INTERVALS_MS, 682 SCHEDULER_INTERVALS_MS,
670 REPEAT_JOBS, 683 REPEAT_JOBS,
671 STATIC_DOWNLOAD_PATHS, 684 STATIC_DOWNLOAD_PATHS,