Build a streaming service

This tutorial will cover how to:

  • How to configure and spawn instances of the Stream Cache Server (SC-Server) programmatically.

  • How to connect the JavaScript WebViewer to a spawned SC-Server.

  • How to monitor the life cycle of SC-Server instances.


  • Working Node.js installation: Please refer to the installation instructions for your particular platform.

  • Code Editor: You may use a code editor of your choice. The editor used for this tutorial was Visual Studio Code. Please refer to the installation instructions for your platform.

Development approach

├── tutorials
│   ├── server_tutorial <- HERE
│   │   ├── complete
│   │   ├── public
│   │   │   ├── js
│   │   │   └── index.html
│   │   ├── models
│   │   ├── paths.js
│   │   ├── package.json
│   │   ├── server.js
│   │   ├── spawner.js

We will be building the application by modifying four files included in the tutorial folder:

  • paths.js: This file contains the system dependent paths that are needed for the various elements of the tutorial to work correctly.

  • server.js: This file is the main entry point for our Node.js application

  • spawner.js: This file will contain the main class for our Stream Cache Server application

  • public/index.html: This file will act as the front end for our application. It will contain the User interface for creating, removing, and monitoring web viewers.

View the content in the directory server_tutorial/complete to see what your project should contain once you have finished this tutorial.