Development Log: vimm-core Updates (February 8th 2025)

in #development7 days ago

Development Log: vimm-core Updates (February 8th 2025)

image.png

🔧 Core Infrastructure Improvements

Media Server Optimization

  • Fixed critical issue with duplicate Node Media Server (NMS) initialization that was causing EADDRINUSE errors on ports 1935 and 8000
  • Implemented singleton pattern for NMS instance management to prevent duplicate server instances and undefined session issues
  • Centralized NMS instance management through new src/server/nms-instance.js module

API Enhancements

  1. New Endpoints:
    • Added GET /api/streams endpoint with comprehensive features:
      • Pagination support (?page=X&limit=Y)
      • Language filtering (?language=en)
      • Category filtering (?category=gaming)
      • Stream metadata including viewer counts and quality information
    • Implemented GET /api/stream/:streamId/status endpoint providing:
      • Basic stream metadata (title, description, category)
      • Real-time statistics (viewers, uptime)
      • Quality information (resolution, bitrate, codecs)
      • Stream health metrics

Database Updates

  • Added streamCategory field to StreamKey model
  • Implemented corresponding database migration
  • Enhanced stream filtering capabilities based on new category field

Frontend Improvements

  • Fixed ad container visibility issues on initial page load

Bug Fixes

  • Resolved "Cannot convert undefined or null to object" error in streams endpoint
  • Fixed "Cannot read property of undefined" error in stream status endpoint
  • Corrected require path for streamStatusRouter
  • Fixed various migration-related issues

🔄 Migration Guide

For developers working with the codebase:

  1. Run the latest migrations to add the new streamCategory field
  2. Update any direct NMS instance references to use the new singleton pattern
  3. Review and update stream-related API calls to leverage new filtering capabilities

🔜 Next Steps

  • Continue monitoring NMS performance after singleton implementation
  • Gather feedback on new stream categorization system
  • Consider expanding stream metadata capabilities

View full commit history


This development log summarizes the major updates from the recent commits to the vimm-core repository. The changes focus on improving server stability, enhancing the streaming API capabilities, and fixing critical infrastructure issues. Notable highlights include the Node Media Server optimization and the introduction of new stream management endpoints.

Sort:  

@chiren, you're rewarding 0 replies from this discussion thread.