Use write-only mode only if file storage and no other storage is
enabled. Use read/write for all other cases.
Change-Id: I3eea79d8a572b3985015b48cda227ab2b8d9e978
Introduce output_get_content as a central point to obtain the contents
of a recording, whether stored as a file or in memory.
Cache contents so that we don't have to read a file multiple times.
Delegate closing of the recording file to output_close.
Change-Id: Ic5471b840d86966f547b3b8ea4bac7eca012c474
Return success indicator from db_close_stream and use that to decide
whether to unlink the file. If DB storage failed then we can retain the
recording on file.
Change-Id: I91520f0ded223965a7a9cb1f200b8af06f555427
if ((output_storage & OUTPUT_STORAGE_MEMORY))
goto no_output_file;
jumps over this code, so there's no point in testing for
OUTPUT_STORAGE_MEMORY
Change-Id: I95eec8904714c9ab06f066ac4bb59ec0413e6916
Move destination format information into the sink object.
Decode each codec directly to its matching output format and leave
resampling to the sinks.
Move managing of the adjusted multi-channel output format into the mix
context.
Make sure all inputs to a mix outputs use the same audio format.
Change-Id: Ib9f334443bfee26d59f2ede6e13ac80c66c1b57e
The GLib slice allocator has been obsoleted. Having a mixture of two
allocators can lead to hidden issues on systems that use different
implementations. Take the leap and replace everything with g_new/g_free.
Change-Id: I025c8383ef47b2c2472573360407fd6a6ca339b3
... after file is opened
- Relocated chmod and chown operations from output_shutdown to output_config.
- Ensures file permissions and ownership are set immediately after file is opened.
Closes#1853
Change-Id: I1b60ce73fc44c9ac91400e7a234c30a697c48fcb
... to control output buffer flushing behavior
This commit introduces a new configuration flag `flush_packets`,
allowing control over whether the output buffer is flushed after each
packet during recording. When enabled, the file will grow continuously,
reducing latency and ensuring immediate availability for processing.
Closes#1848
Change-Id: I842bd1b2d6e6cf321cfda4cc3520bab47dafcaf4
Obsolete str_init(), rename STR_INIT() to just STR(), and replace all
instances of str_init() with STR().
no-op
Change-Id: I981529063ad2ea26089add467f7a84b638dbf423
Support a replacement pattern of %{...} to look up arbitrary keys from
the given metadata and use the respective values.
Change-Id: I2cc6c791629ed494b32e3352a555298c3b9cb4fc
Adopt the logic for flexible output names from single output files also
for mixed output files. Refactor both code paths into a single shared
function.
Updates #1667
Change-Id: I8ff4ea0a169dc39ae384e9c1e601ceded325d5df
When the `discard-recording` flag is given in one of the commands to
rtpengine (e.g. in the `delete` command), the metafile is renamed to a
.DISCARD suffix and then deleted.
The recording daemon then, seeing the .DISCARD suffix, proceeds to
immediately close all recordings, delete the files if any, and delete
the entries from the DB.
Change-Id: I3f0cac129f2d56cbccd770d43bf434dea6c0a0db
The `encoder` is actually persistent and only freed when the output is
freed, so testing for its existence is not enough to determine whether
the output is open. The `fmtctx` can be used for that.
Change-Id: I2cc3f00a0e983fafd5915736089a0421385b6ce3
The "done" label is also used when the output is already open and
established, therefore the log message should go above it.
Change-Id: Iceb218a8cffeb42de302324374c790c46557d985
This is the "type" of the recording, but sadly we already have "type"
with a slightly different meaning (i.e. the SSRC in hex for single
streams), so we name this the recording "kind".
Change-Id: I2f7c36e42f7eb075a4324e9659d2845ab40b4f07