Ticket #831 (closed enhancement: fixed)

Opened 8 years ago

Last modified 8 years ago

Automatically switch to TCP transport when sending large request

Reported by: bennylp Owned by: bennylp
Priority: normal Milestone: release-1.3
Component: pjsip Version: trunk
Keywords: sipit24 Cc:
Backport to 1.x milestone: Backported:

Description (last modified by bennylp) (diff)

The spec says that endpoint should use TCP transport when the request is larger than 1300 bytes. This means to use DNS SRV resolution for the TCP address of the destination URI. Also when the TCP connection fails, the endpoint should revert back to using UDP.

Attachments

ticket831.patch (1.6 KB) - added by nanang 8 years ago.

Change History

comment:1 Changed 8 years ago by bennylp

  • Description modified (diff)

Changed 8 years ago by nanang

comment:2 Changed 8 years ago by nanang

  • Version changed from trunk to Sipit24
  • Milestone changed from release-1.3 to Sipit24

In r2703:

  • Quick/initial patch for automatic transport switching (to TCP) when a SIP request size is larger than 1300 and is about to send via UDP.

comment:3 Changed 8 years ago by bennylp

In r2710:

  • fixed Via address unchanged when switching transport
  • reset transaction retransmit count and timeout timer when retrying
  • handle case when TCP transport is not available
  • added macro PJSIP_UDP_SIZE_THRESHOLD
  • added API to encode transmit data (to avoid using buffer in the stack when checking message size)

comment:4 Changed 8 years ago by bennylp

In r2711:

  • bug in previous commit, message size is always detected as PJSIP_MAX_PKT_SIZE

comment:5 Changed 8 years ago by bennylp

  • Status changed from new to closed
  • Resolution set to fixed

comment:6 Changed 8 years ago by bennylp

  • Version changed from Sipit24 to trunk
  • Milestone changed from Sipit24 to release-1.3

Back-ported to trunk for milestone:release-1.3 by r2724

comment:7 Changed 8 years ago by bennylp

  • Keywords sipit24 added

comment:8 Changed 8 years ago by nanang

  • Status changed from closed to reopened
  • Resolution fixed deleted

comment:9 Changed 8 years ago by nanang

  • Status changed from reopened to closed
  • Resolution set to fixed

In r2756:

  • Added compile-time option to disable this feature.
Note: See TracTickets for help on using tickets.