Skip to content

feat(calling): add calling transport layer#4811

Open
rsarika wants to merge 4 commits intowebex:nextfrom
rsarika:calling-transport-layer
Open

feat(calling): add calling transport layer#4811
rsarika wants to merge 4 commits intowebex:nextfrom
rsarika:calling-transport-layer

Conversation

@rsarika
Copy link
Copy Markdown
Contributor

@rsarika rsarika commented Mar 27, 2026

COMPLETES #< INSERT LINK TO ISSUE >

This pull request addresses

< DESCRIBE THE CONTEXT OF THE ISSUE >

by making the following changes

< DESCRIBE YOUR CHANGES >

Change Type

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Tooling change
  • Internal code refactor

The following scenarios were tested

< ENUMERATE TESTS PERFORMED, WHETHER MANUAL OR AUTOMATED >

The GAI Coding Policy And Copyright Annotation Best Practices

  • GAI was not used (or, no additional notation is required)
  • Code was generated entirely by GAI
  • GAI was used to create a draft that was subsequently customized or modified
  • Coder created a draft manually that was non-substantively modified by GAI (e.g., refactoring was performed by GAI on manually written code)
  • Tool used for AI assistance (GitHub Copilot / Other - specify)
    • Github Copilot
    • Other - Please Specify
  • This PR is related to
    • Feature
    • Defect fix
    • Tech Debt
    • Automation

I certified that

  • I have read and followed contributing guidelines
  • I discussed changes with code owners prior to submitting this pull request
  • I have not skipped any automated checks
  • All existing and new tests passed
  • I have updated the documentation accordingly

Make sure to have followed the contributing guidelines before submitting.

@rsarika rsarika requested a review from a team as a code owner March 27, 2026 05:38
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: e8e73580fd

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment on lines +39 to +43
this.offlineHandler = () => {
handler({
source: CallingTransportConnectionSource.MERCURY,
state: CallingTransportConnectionState.OFFLINE,
});
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep per-callback state for connection listeners

LegacyMercuryTransportAdapter stores only one offlineHandler/onlineHandler pair on the adapter instance, so each onConnectionStateChange() call overwrites the previous callbacks while leaving the previous Mercury listeners registered. In any flow with multiple registrations (for example multiple CallingClient instances or repeated init/teardown), offConnectionStateChange() can only remove the most recently stored handlers, which leaves stale listeners active and can cause duplicate or misrouted connection-state handling.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 45a6721a29

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

const webex = SDKConnector.getWebex();

if (webex) {
CallingTransport.transportAdapter.dispose?.(webex);
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Await adapter disposal before switching transport

setAdapter() invokes transportAdapter.dispose but does not await it, even though ICallingTransportAdapter.dispose is allowed to return Promise<void>. If a custom adapter performs async teardown (for example, closing a socket or unregistering listeners), the new adapter is installed immediately and both adapters can run concurrently, causing duplicate events or resource leaks during adapter swaps.

Useful? React with 👍 / 👎.

@rsarika rsarika added the validated If the pull request is validated for automation. label Mar 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

validated If the pull request is validated for automation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant