'activitypub-follow': 60000 * 10, // 10 minutes
'video-file-import': 1000 * 3600, // 1 hour
'video-file': 1000 * 3600 * 48, // 2 days, transcoding could be long
- 'video-import': 1000 * 3600 * 5, // 5 hours
+ 'video-import': 1000 * 3600, // 1 hour
'email': 60000 * 10, // 10 minutes
'videos-views': undefined // Unlimited
}
const REDUNDANCY = {
VIDEOS: {
- EXPIRES_AFTER_MS: 48 * 3600 * 1000, // 2 days
RANDOMIZED_FACTOR: 5
}
}
CONFIG.WEBSERVER.HOST = sanitizeHost(CONFIG.WEBSERVER.HOSTNAME + ':' + CONFIG.WEBSERVER.PORT, REMOTE_SCHEME.HTTP)
}
-function buildVideosRedundancy (objs: VideosRedundancy[]): VideosRedundancy[] {
+function buildVideosRedundancy (objs: any[]): VideosRedundancy[] {
if (!objs) return []
- return objs.map(obj => Object.assign(obj, { size: bytes.parse(obj.size) }))
+ return objs.map(obj => {
+ return Object.assign(obj, {
+ minLifetime: parseDuration(obj.min_lifetime),
+ size: bytes.parse(obj.size),
+ minViews: obj.min_views
+ })
+ })
}
function buildLanguages () {