Kinesis Video WebRTC Streams in SDK v3 #6534
Labels
needs-triage
This issue or PR still needs to be triaged.
v2-v3-inconsistency
Behavior has changed from v2 to v3, or feature is missing altogether
Pre-Migration Checklist
UPGRADING.md
.Which JavaScript Runtime is this issue in?
Browser
AWS Lambda Usage
Describe the Migration Issue
The documentation on the Kinesis Web Video (especially the WebRTC storage, but also the signaling client changes from v2 to v3) is very difficult to understand and seems incomplete.
The first sentence of the JoinStorageSessionCommand says this:
"Before using this API, you must call the GetSignalingChannelEndpoint API to request the WEBRTC endpoint. You then specify the endpoint and region in your JoinStorageSession API request."
No problem. I've obtained the WEBRTC endpoint easily from the GetSignalingChannelEndpoint. No where in the documentation does it show how to include the endpoint with the request. The JoinStorageSessionCommand only takes "channelArn" as input. I see "endpoint" in the KinesisVideoWebRTCStorageClient, but have been unsuccessful on figuring out how to provide it to the client.
This sample syntax does not give any indication on how to get this to work:
import { KinesisVideoWebRTCStorageClient, JoinStorageSessionCommand } from "@aws-sdk/client-kinesis-video-webrtc-storage"; // ES Modules import
// const { KinesisVideoWebRTCStorageClient, JoinStorageSessionCommand } = require("@aws-sdk/client-kinesis-video-webrtc-storage"); // CommonJS import
const client = new KinesisVideoWebRTCStorageClient(config);
const input = { // JoinStorageSessionInput
channelArn: "STRING_VALUE", // required
};
const command = new JoinStorageSessionCommand(input);
const response = await client.send(command);
I cannot figure out how to proceed. The v2 version would use callbacks on the signalingclient (for example: signalingClient.on('open',...), but that does not appear to work anymore.
Code Comparison
No response
Observed Differences/Errors
The lack of callbacks on the signaling channel in v3 and no mention I can find in the documentaton on how to handle the peerConnection to stream video into Kinesis Video where it is ingested and stored makes it nearly impossible to migrate from v2 to v3. What am I missing?
Additional Context
No response
The text was updated successfully, but these errors were encountered: