Open agusting opened 6 years ago
Agustin,
You don’t need a “virtual” version of nmos-cpp to create Virtual NMOS End points… All you need to do is start a new instance and bind it to a different TCP Port.
For load testing, I’ve previously used a small shell script to do this… An example is below:
for number in $(seq -f "%03g" 1 99) do ./nmos-cpp-node "{\"logging_level\": -40, \"registration_port\": 8235, \"settings_port\": 10$number, \"logging_port\": 11$number, \"node_port\": 12$number, \"admin_port\": 13$number, \"connection_port\": 14$number, \"error_log\": \"log$number.txt\"}" > /dev/null 2>&1 & sleep 1 done
This uses a shell “for loop” to start 99 instances by incrementing $number from 1 to 99 thereby starting each instance on a new port.
If you do need a truly virtualized version of nmos-cpp I have created a Docker containerized implementation available at Docker Hub – Use “docker pull mellanox/nmos-cpp-avahi:latest” to retrieve it. It is principally designed to run the registry but it does have the node software code implemented inside the container as well – it means you can connect to the terminal and start up an instance.
Thanks, Rich.
Hi Rich, Thank you for your prompt reply.
I'll try what you suggest and report back. Thanks again.
Agustin
Hi @agusting
As @rhastie has said, basically speaking nmos-cpp-node is a virtual NMOS Node.
The nmos-cpp-node application includes a complete implementation of the Node API, and implementations or stubs for each of the endpoints of the Connection API.
It's intended to serve as a test Node out of the box, and as a starting point for C++ developers building their own NMOS Nodes backed by real media devices. To be clear, it doesn't do any video/audio/data streaming itself.
The application is configurable via a long-winded command-line (see the Tutorial) to adjust the ports it uses and other settings, as Rich has mentioned. So you can even run thousands of nmos-cpp-node instances on one PC.
The NMOS resources it exposes via the Node API (and registers with the Registration API) is currently hard-coded - the node resource itself and 1 each of the other types. We have recently refactored (5c6758a52ce2fd249d5082e9fc91ff4bbd62c570) the node implementation somewhat to enable developers to adjust that to their own liking. (Too late for @billt-hlit and others already building nodes, sorry!)
We're currently in the process of making it easier for developers to implement the Connection API too.
One idea that I've had no time to pursue is to provide hooks between the nmos-cpp-node Connection API and an open-source software-based ST 2110 implementation. It sounds like something that might fit with what you're doing?
Any more questions, let us know.
Gareth
Hi Gareth, Thanks for your reply. Regarding the ST2110 software based implementation you might want to take a look at what CBCRC did with GStreamer and FFMPEG https://github.com/cbcrc/FFmpeg
I´m not a programmer so I don´t think I could of much help. I´ll try to move forward with all the information you´ve gave me and let you know. Hope to fins some time next week. Regards.
Thanks for the link, that's interesting. I'm tagging this documentation as I don't think this is an issue per se, but I'll at least add some of the explanation above and the link to cbcrc/FFmpeg to the docs.
@garethsb-sony, any progress on that topic? As a dev, I'd like to have some guidelines and effort estimate required to integrate a media application to a virtual NMOS device. Thank you.
Hi Patrick,
Thanks for your interest. No progress here on a bigger example app, integrating software-based streaming with nmos-cpp, although it is something I'd like to have. PR #49, and the experience of other devs who've built Nodes with nmos-cpp, will be a starting point for this.
Focus recently has been on implementing NMOS API security, extending the NMOS test suite, and now adding NMOS Event & Tally to nmos-cpp.
As of https://github.com/sony/nmos-cpp/commit/9ce86373049c62e8a34c16fc763fd6f8a134786f on master, I hope we've finally got something that is easier to integrate into a larger application. Perhaps someone could try integrating nmos-cpp with the CBC work on ST 2110 with ffmpeg as a trial...
@pkeroulas Hi Patrick. What's the status of the ffmpeg ST 2110 fork?
@garethsb-sony, nothing has moved for a while.
Hi, first of all thankyou for your develpment!
I'm trying to build a ST2110 lab to test NMOS and I'm finding difficult to test due to the lack of NMOS Devices. I've been able to generate ST2110 streams with Gstreamer and consume them with SDPs but NMOS seems to be more difficult.
Do you know any way to create Virtual NMOS End points or generators in order to do some tests?
Thanks in advance. Agustin.