{"id":28474073,"url":"https://github.com/qualabs/cmcd-toolkit","last_synced_at":"2025-07-02T08:31:53.768Z","repository":{"id":294635609,"uuid":"958045613","full_name":"qualabs/cmcd-toolkit","owner":"qualabs","description":"Tools to collect and analize CMCD v2 locally and in different cloud providers.","archived":false,"fork":false,"pushed_at":"2025-05-26T08:51:10.000Z","size":5068,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-07T13:01:36.788Z","etag":null,"topics":["big-data","bigquery","cmcd","dash","dashjs","gcloud","hls","hls-live-streaming","influxdb","mpeg-dash","open-source","qoe-measurements","shaka-player","video","video-player","video-streaming"],"latest_commit_sha":null,"homepage":"https://tech.qualabs.com","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/qualabs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-03-31T14:55:10.000Z","updated_at":"2025-05-23T17:04:45.000Z","dependencies_parsed_at":"2025-05-21T11:22:51.433Z","dependency_job_id":"80e9f2d2-5ac1-45cf-9ffb-09d8cf8a581a","html_url":"https://github.com/qualabs/cmcd-toolkit","commit_stats":null,"previous_names":["qualabs/cmcd-toolkit"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/qualabs/cmcd-toolkit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qualabs%2Fcmcd-toolkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qualabs%2Fcmcd-toolkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qualabs%2Fcmcd-toolkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qualabs%2Fcmcd-toolkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/qualabs","download_url":"https://codeload.github.com/qualabs/cmcd-toolkit/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/qualabs%2Fcmcd-toolkit/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263102654,"owners_count":23414150,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["big-data","bigquery","cmcd","dash","dashjs","gcloud","hls","hls-live-streaming","influxdb","mpeg-dash","open-source","qoe-measurements","shaka-player","video","video-player","video-streaming"],"created_at":"2025-06-07T13:00:55.131Z","updated_at":"2025-07-02T08:31:53.754Z","avatar_url":"https://github.com/qualabs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# cmcd-toolkit\n\ncmcd-toolkit is a set of basic tools to collect and analyze data sent by video with [CMCD v2](https://github.com/cta-wave/common-media-client-data) support.\n\nThis repository provides tools to collect and analize CMCD v2 locally and in different cloud providers.\n\n## Project Modules\n\nThe project is organized into the following modules:\n\n*   [**collector**](collector/README.md): Responsible for receiving, processing, and forwording CMCD data to a DB or storage instance. It can be configured to work with different backends like Fluentd or Google PubSub\n*   [**fluentd**](fluentd/README.md): A data collector for unified logging. It's primarily used in the local setup to forward CMCD data from the `collector` to an InfluxDB instance for quick visualization with Grafana. It can be configured to output to other destinations like BigQuery or apply filters and data enrichment (like adding geoip data based on the user IP address)\n*   [**gcloud-big-table**](gcloud-big-table/README.md): Contains the schema definition (`bigquery-cmcdv2-schema.json`) for storing CMCD data in **Google BigQuery** within the Google Cloud flavor.\n*   [**gcloud-collector-function**](gcloud-collector-function/README.md): A Google Cloud Function implementation of the CMCD collector. This is an alternative to the Docker-based collector for serverless deployments on Google Cloud.\n*   [**grafana**](grafana/README.md): Contains Grafana configurations for visualizing CMCD data. It includes dashboards for both local and Google Cloud setups.\n*   [**player**](player/README.md): A web-based video player based in dash.js used for testing and demonstrating CMCD data collection. It can be configured to send CMCD data to the collector.\n\n\n## How to run localy\n\nThis setup allows you to run the cmcd-toolkit on your local machine using Docker.\n\nThis setup uses the following moduels: **player**, **collector**, **fluentd** and  **grafana**\n\nHow to run:\n1. Run `docker compose up` (or `docker compose -f docker-compose.local.yml up`).\n2. Player will be available at: [http://localhost:8080](http://localhost:8080), \n3. Press the \"Collector\" button to start sending CMCD v2 data to the local collector.\n4. Play any DASH content in the player.\n5. Login to grafana at [http://localhost:8081](http://localhost:8081)\n   * User: `admin`\n   * Password: `grafana`\n6. Open a grafana dashboard to start analyzing the CMCD data from the player.\n\n\n## How to deploy in Google Cloud\n\nDeployment in Google Cloud:\n![CMCD Toolkit Google Cloud Deployment Example](docs/gcloud-example.png)\n\nAssuming you already have a Google Cloud account, the high-level steps to deploy are:\n1. Create a CMCD [BigTable](https://cloud.google.com/bigtable) using schema found in the `gcloud-big-table` folder\n2. Create a [Pub/Sub](https://cloud.google.com/pubsub) topic and a suscription to the CMCD BigTable\n3. Create a [Cloud Run Function](https://cloud.google.com/functions) with the code found in `index.js` from `collector-gcloud-function`. This will give you a `{public url}` for the collector.\n4. Configure in the palyer found in the `palyer` folder the following urls:\n    * For response mode: `{public url}/cmcd/response-mode`\n    * For event mode: `{public url}/cmcd/event-mode`\n5. (Optional) Create a bucket in [Cloud Storage](https://cloud.google.com/storage) with public access and deploy the palyer for testing the system.\n6. (Optional) Create a bucket in [Cloud Storage](https://cloud.google.com/storage) and suscribe to the Pub/Sub CMCD topic for long term CMCD storage.\n7. (Optinal) Connect a Grafana instance using the BigQuery plugin. Find a Grafana config example in the `grafana` folder.\n\n## How to use other players\nTo collect CMCD data from a player other than the one pre-configured in this project, you must configure CMCD v2 and set the response and event mode endpoints to the following URLs (Note that both `collector` and `gcloud-collector-function` have the same API): \n\n* CMCD Response mode: `{collector_domain}:{collector_port}/cmcd/response-mode`\n* CMCD Event mode: `{collector_domain}:{collector_port}/cmcd/event-mode`\n\n\n## How to develop\n\nCopy `docker-comose.develop.yml` to `docker-compose.override.yml` and then run `docker compose up`. You will be able to modify the code while running the project\n\nNotice: \n* If you are making changes in the `fluentd` configuraiton, you MAY need to delete the docker volume of influxdb to se the cahnges applied\n* After changinge the codebase, you can run all the unit tests using this command: `docker compose -f docker-comose.test.yml up` \n\n## License\n\nThis project is licensed under the Apache 2.0 License. See the `LICENSE` file for more details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqualabs%2Fcmcd-toolkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fqualabs%2Fcmcd-toolkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fqualabs%2Fcmcd-toolkit/lists"}