Summary:ASTERISK-07401: [patch][post 1.4] Monitor() only input or output stream
Reporter:julien23 (julien23)Labels:
Date Opened:2006-07-26 08:47:05Date Closed:2007-07-09 15:41:44
Versions:Frequency of
Environment:Attachments:( 0) patch_res_monitor_only_input_or_output_v2.diff
( 1) patch_res_monitor_only_input_or_output_v3.diff
Description:Make possibility to record only input (option 'i') or output (option 'o') stream when using the Monitor() application (res_monitor).


Can't be used with the mix option (option 'm') as it will always report an error when trying to mix one missing file.
Comments:By: Clod Patry (junky) 2006-07-30 00:21:29

If you don't use the m option, that will leave the 2 legs on the file-system (in and out) no?
You can directly use just the in or out.

By: julien23 (julien23) 2006-07-31 02:12:08

If you use one of the two new options ('i' or 'o') you will only have one recorded file (in or out) so the 'm' (mix) option will fail.

If your question is why these new options instead of don't using the 'm' option and keeping only the file of interrest (in or out) while removing the second, I answer that recording a stream that is going to be deleted immediatly is a waste of ressources (CPU, disk...).

By: jmls (jmls) 2006-10-31 14:17:50.000-0600

this patch still applies to trunk (with 1 fuzz). Is this something that people would like to see in trunk ?

By: julien23 (julien23) 2006-11-01 04:03:17.000-0600

I made this patch besause I needed it... so, at least one people would like to see it in trunk.
Anyway, the patch is not realy big and intrusive so it's not a big pain to push it in trunk.

By: jmls (jmls) 2006-11-01 04:47:03.000-0600

julien23, would you be able to upload a patch that applies cleanly to trunk without the fuzz ? Thanks.

By: julien23 (julien23) 2006-11-01 13:19:42.000-0600

OK, see patch v2 applying to trunk (46785).
I added the check so that m and i/o options are mutually exclusive (no sense to mix streams if you only record one).

By: Jason Parker (jparker) 2006-11-20 14:46:13.000-0600

This patch allows you to specify option 'i' and option 'o' at the same time.  I don't think that was intended...  Perhaps instead of adding 2 new vars to the function, you could just add one, and use a bitmask or something.

x_in = 1
x_out = 2
x_join = 4

default would be 3, 'm' would enable x_join, x_in, and x_out, 'i' would disable x_out and x_join, 'o' would disable x_in and x_join.

Maybe we could reverse the options, so that 'o' tells it to NOT record x_out, and 'i' tells it to NOT record x_in.  If it were done that way, we could in theory (it wouldn't be practical, but hey...you never know) have it record neither input NOR output (ie; record nothing at all).  If 'i' or 'o' are set, THEN disable 'm' (probably give a warning, saying something like "Not recording input stream, cannot mix streams.", instead of checking for 'm' before the others.

Does this make sense to anybody else?

By: jmls (jmls) 2006-11-20 14:54:45.000-0600

makes sense. Make it so.

By: Jason Parker (jparker) 2006-11-20 15:01:41.000-0600

Julien23, would you be willing/able to make these changes?

By: julien23 (julien23) 2006-11-21 07:28:31.000-0600

Sorry but I don't have time to do this right now. May be later if nobody make it before.

By: Anthony LaMantia (alamantia) 2006-12-15 19:45:21.000-0600

julien23 do you have the time now?

By: julien23 (julien23) 2006-12-16 17:00:58.000-0600

OK, here is the third revision of the patch including qwell suggestions and other improvements. It compiles fine but I won't be able to test it before next year.
Anybody can do it for me ?

By: Digium Subversion (svnbot) 2007-07-09 15:41:43

Repository: asterisk
Revision: 74164

r74164 | qwell | 2007-07-09 15:41:41 -0500 (Mon, 09 Jul 2007) | 6 lines

(closes issue ASTERISK-7401)
Reported by: julien23
Patches submitted by: julien23

Add the ability to disable recording the input or output streams in res_monitor.