microsoftgraph / microsoftgraph/microsoft-graph-comms-samples

DiagCode: 3003#7106 .NET Framework 4.8

Open
#860 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
No language data
Stars
253
Forks
275
Avg merge
1d 5h
Merged PRs (30d)
1

Description

BotMedia SDK native media engine does not bind UDP port under .NET Framework 4.8

SDK Version: Microsoft.Skype.Bots.Media 1.31.0.225
Graph Communications SDK: Latest
OS: Windows Server (x64)
Runtime tested: .NET Framework 4.8 (fails), .NET 6 (works)


Summary

The BotMedia native media engine silently fails to initialize when hosted in a .NET Framework 4.8 process. The UDP media port is never bound, causing Teams to drop the call with DiagCode: 3003#7106 after ~4 seconds. The exact same configuration and code works correctly on .NET 6 on the same machine.


Reproduction Steps
  1. Take a working .NET 6 Teams compliance recording bot (Kestrel, call.AnswerAsync(mediaSession))
  2. Port it to .NET Framework 4.8 using OWIN for HTTP hosting
  3. Keep identical MediaPlatformSettings, AudioSocketSettings, CommunicationsClientBuilder configuration
  4. Run and place a call

Observed Behavior

Signaling works correctly:

  • Webhook received ✅
  • OnIncomingCall fires ✅
  • CreateMediaSession succeeds ✅
  • AnswerAsync completes without exception ✅
  • state=establishing webhook received ✅

But media never starts:

  • UDP port is never bound by the media platform
  • Teams drops call after ~4 seconds with DiagCode: 3003#7106
  • AudioMediaReceived event never fires
  • 0 bytes recorded

Confirmed via UDP listener check immediately after builder.Build():

[DIAG] UDP 8445 is NOT bound - media platform silently failed!
[DIAG] All UDP ports bound by this process: (none in range 8000-9000)

Same check on .NET 6 version:

[DIAG] UDP 8445 IS bound on 0.0.0.0 - media platform OK

MediaPlatformSettings (identical in both versions)
var mediaPlatformSettings = new MediaPlatformSettings
{
    ApplicationId = APP_ID,
    MediaPlatformInstanceSettings = new MediaPlatformInstanceSettings
    {
        ServiceFqdn             = "bot.example.com",
        CertificateThumbprint   = CERT_THUMBPRINT,
        InstanceInternalPort    = 8445,
        InstancePublicIPAddress = IPAddress.Parse("x.x.x.x"),
        InstancePublicPort      = 8445,
    }
};

var builder = new CommunicationsClientBuilder("PolicyRecordingBot", APP_ID, logger);
builder.SetAuthenticationProvider(authProvider);
builder.SetNotificationUrl(notificationUri);
builder.SetMediaPlatformSettings(mediaPlatformSettings);
builder.SetServiceBaseUrl(new Uri("https://graph.microsoft.com/v1.0"));

var client = builder.Build();

Error Codes Observed
Condition DiagCode
UDP not bound (pure media failure) 3003#7106
SDK throws during answer processing 500#1203003

The BotMedia SDK ships native C++ DLLs that appear to depend on the .NET Core runtime hosting APIs (coreclr.dll) for initialization. When loaded into a .NET Framework 4.8 process, the native media engine silently fails to start — no exception is thrown, no error is logged, but the UDP port is never bound and no media is processed.


Questions
  1. Is Microsoft.Skype.Bots.Media officially supported on .NET Framework 4.8, or is .NET Core / .NET 6+ a hard requirement?
  2. Is there a supported way to host the BotMedia SDK inside a .NET Framework 4.8 process?
  3. If .NET Framework 4.8 is not supported, is out-of-process hosting (separate .NET 6 executable communicating via IPC) the recommended integration pattern for mixed-runtime environments?
  4. Is there any initialization API we should be calling explicitly to start the media platform that we may be missing?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the .NET 6 and .NET Framework 4.8 reproduction described in the issue, comparing initialization after CommunicationsClientBuilder.Build() and the UDP listener check on port 8445. Review the Microsoft.Skype.Bots.Media 1.31.0.225 hosting requirements and native runtime dependencies. Done means establishing whether .NET Framework 4.8 is supported, identifying a supported hosting pattern, or confirming that no initialization call is missing.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.