Asterisk
  1. Asterisk
  2. ASTERISK-26419

audiohooks: Remove redundant codec translations when using audiohooks

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Severity: Major Major
    • Resolution: Fixed
    • Affects Version/s: 11.23.1, 13.11.2, 14.0.1
    • Target Release Version/s: 13.17.0, 14.6.0, 15.0.0
    • Component/s: Core/Channels, Core/General
    • Security Level: None
    • Labels:
      None
    • Environment:
      All

      Description

      Channel.c currently calls audiohooks and passes channel voice data in its native format. In most cases, the native format is later transcoded to linear for bridging or other dialplan functions. When using audiohooks, e.g. for recording or conference, the required codec translation from native to linear and vice versa is instantiated separately for each hook, alongside the translation required for bridging. This can result in 2 or 3 simultaneous codec translations for a single bridged call, which is very inefficient in terms of CPU usage.

      By moving the audiohook location in the read and write functions in channel.c, we can share the expensive codec translation amongst all users of the frame data.

        Issue Links

          Activity

          Hide
          Asterisk Team added a comment -

          Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

          A good first step is for you to review the Asterisk Issue Guidelines if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

          Then, if you are submitting a patch, please review the Patch Contribution Process.

          Show
          Asterisk Team added a comment - Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution. A good first step is for you to review the Asterisk Issue Guidelines if you haven't already. The guidelines detail what is expected from an Asterisk issue report. Then, if you are submitting a patch, please review the Patch Contribution Process .
          Hide
          Joshua Colp added a comment -

          Same here.

          Show
          Joshua Colp added a comment - Same here.
          Hide
          Michael Walton added a comment -

          I have added the patch on Gerrit: https://gerrit.asterisk.org/4024

          Show
          Michael Walton added a comment - I have added the patch on Gerrit: https://gerrit.asterisk.org/4024
          Hide
          Friendly Automation added a comment -

          Change 5757 merged by Jenkins2:
          channel: ast_write frame wrongly freed after call to audiohooks

          https://gerrit.asterisk.org/5757

          Show
          Friendly Automation added a comment - Change 5757 merged by Jenkins2: channel: ast_write frame wrongly freed after call to audiohooks https://gerrit.asterisk.org/5757
          Hide
          Friendly Automation added a comment -

          Change 5759 merged by Jenkins2:
          channel: ast_write frame wrongly freed after call to audiohooks

          https://gerrit.asterisk.org/5759

          Show
          Friendly Automation added a comment - Change 5759 merged by Jenkins2: channel: ast_write frame wrongly freed after call to audiohooks https://gerrit.asterisk.org/5759
          Hide
          Friendly Automation added a comment -

          Change 5758 merged by Joshua Colp:
          channel: ast_write frame wrongly freed after call to audiohooks

          https://gerrit.asterisk.org/5758

          Show
          Friendly Automation added a comment - Change 5758 merged by Joshua Colp: channel: ast_write frame wrongly freed after call to audiohooks https://gerrit.asterisk.org/5758

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development