[FFmpeg-devel] [PATCH] http: make caching of redirect url optional

Ronald S. Bultje rsbultje at gmail.com
Sun Dec 26 16:06:52 EET 2021


Hi,

(I was asked to respond since I'm listed as HTTP maintainer, not sure I
should be since I'm mostly working on video codecs nowadays.)

On Tue, Nov 2, 2021 at 9:00 AM Eran Kornblau <eran.kornblau at kaltura.com>
wrote:

> The motivation for this feature is S3 signatures – currently we have a
> problem where S3 signatures cannot be created
> with an expiration of more than 12H. In some cases, a transcoding task may
> execute for more than that.
> If we use a pre-signed S3 URL, and ffmpeg disconnects/seeks after the
> expiration of the URL, it will fail.
>
> The solution we are planning is to have some local server on the machine
> running ffmpeg that will generate an S3-signature,
> and redirect to the full pre-signed URL. For this to work, I need to
> disable the caching of redirects, and have ffmpeg always
> start from the initial URL.
> The nice thing about this solution is that the video data is pulled
> directly from S3 – in other words, the local server doesn’t
> hold any real load, it just builds the signature and returns a redirect.
>

Uhm... This is a really weird solution, but it does look right.

Generally speaking, we're typically concerned about the default being the
right behaviour. I would say that (maybe after some time, at the next ABI
break or so), 0 should be the default, not 1. This is the same as what
Marton/Hendrik said also, I think, so consider this consensus. I would just
do that with the appropriate ABI macros so the default behaviour changes at
the next bump.

Patch itself is fine, it has some whitespace change at line 430 and 621
that is not really necessary, but otherwise no objections from me.

Ronald


More information about the ffmpeg-devel mailing list