I've run into one additional issue related to the rtmp streaming. Though I've used FFMpeg and Wirecast for testing (and am able to get those working fine), our actual video source for this project comes from the DJI Go iOS application, which provides a "custom RTMP" output feed as an option (in addition to YouTube, Facebook, etc.). While I can stream from this fine into WCS, the server code doesn't seem to be parsing the query string arguments correctly. I have a couple of entries from logs/server_logs/flashphoner.log that seem to illustrate the problem. There seems to be code in WCS that identifies the rtmp feed source type - so far I'm seeing "flashVer=Wirecast/FM 1.0 (compatible; MSS/1.0)" and "flashVer=FMLE/3.0 (compatible; Lavf56.15.102)".
For both examples, I'm using the URL rtmp://198.144.49.134:1935/live/cgwstream2?appKey=StreamingInput&token=12345/. (If I omit the trailing "/" in DjiGo, the stream goes to the default flashStreamingApp rather than the "StreamingInput" app I set up.)
This entry is generated via a Wirecast stream. This stream shows up via the "StreamingInput" app, with the stream name "cgwstream1":
12:07:15,939 INFO ServerHandler - RTMP-pool-4-thread-5 [0 COMMAND_AMF0 c3 #0 t0 (0) s279] name: connect, transactionId: 1, object: TransferObject{dataMap={app=live/cgwstream1?appKey=StreamingInput&token=12345, tcUrl=rtmp://198.144.49.134:1935/live/cgwstream1?appKey=StreamingInput&token=12345, type=nonprivate, audioCodecs=1026.0, videoCodecs=128.0, flashVer=Wirecast/FM 1.0 (compatible; MSS/1.0)}typeMap={app=class java.lang.String, tcUrl=class java.lang.String, audioCodecs=class java.lang.Double, videoCodecs=class java.lang.Double, flashVer=class java.lang.String, type=class java.lang.String}}, args: []
This entry is from my DJI Go stream. It shows up via the "StreamingInput" app, but the stream name is empty.
12:04:25,025 INFO ServerHandler - RTMP-pool-4-thread-4 [0 COMMAND_AMF0 c3 #0 t0 (0) s234] name: connect, transactionId: 1, object: TransferObject{dataMap={app=live/cgwstream2?appKey=StreamingInput&token=12345, type=nonprivate, flashVer=FMLE/3.0 (compatible; Lavf56.15.102), tcUrl=rtmp://198.144.49.134:1935/live/cgwstream2?appKey=StreamingInput&token=12345}typeMap={app=class java.lang.String, tcUrl=class java.lang.String, flashVer=class java.lang.String, type=class java.lang.String}}, args: []
To understand things further, I downloaded and installed Adobe FMLE and created a live stream, called "cgwflestream". FMLE requires the stream field be filled in - it's not allowed as a part of the RTMP URL. It results in this set of log entries, where it appears the stream name comes in some way other than in the URL.
12:29:18,222 INFO ServerHandler - RTMP-pool-4-thread-7 [0 COMMAND_AMF0 c3 #0 t0 (0) s283] name: connect, transactionId: 1, object: TransferObject{dataMap={app=live?appKey=StreamingInput&toke
n=12345, tcUrl=rtmp://198.144.49.134:1935/live?appKey=StreamingInput&token=12345, type=nonprivate, flashVer=FMLE/3.0 (compatible; FMSc/1.0), swfUrl=rtmp://198.144.49.134:1935/live?appKey=StreamingIn
put&token=12345}typeMap={app=class java.lang.String, tcUrl=class java.lang.String, swfUrl=class java.lang.String, flashVer=class java.lang.String, type=class java.lang.String}}, args: []
12:29:18,256 INFO ServerHandler - RTMP-pool-4-thread-7 command - releaseStream
12:29:18,257 INFO ServerHandler - RTMP-pool-4-thread-7 received not used message: [0 COMMAND_AMF0 c3 #0 t0 (0) s41] name: releaseStream, transactionId: 2, object: null, args: [cgwflestream]
Any suggestions on how I might get this to function the way I need it to? Seems the issue is in how WCS is identifying the RTMP source and handling arguments differently.