Skip to content

InnoScripts2/Midle-OP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Midle OP Projects Suite

Comprehensive Node.js solutions for task orchestration, real-time collaboration, and operational log analysis. The workspace hosts three independent services that share common engineering principles: consistent validation, observable error handling, and automation-friendly tooling.

Repository Layout

  • task-management-api/ – RESTful service that secures, schedules, and monitors tasks for distributed teams.
  • websocket-chat/ – Event-driven WebSocket gateway enabling instant messaging and presence updates.
  • log-parser-cli/ – Command-line utility for parsing application logs and extracting actionable metrics.

Project Highlights

Task Management API

  • Purpose: Delivers authenticated CRUD endpoints for tasks, providing filtering, prioritisation, and deadline management.
  • Stack: Node.js 18+, Express, Mongoose, JSON Web Tokens, express-validator, Jest.
  • Key Capabilities:
    • Token-based authentication with role-ready structure.
    • Centralised validation middleware and consistent problem-detail responses.
    • MongoDB persistence with lifecycle hooks for password hashing.
  • Quick Start:
    1. cd task-management-api
    2. npm install
    3. Copy .env.example to .env and set MONGO_URI, JWT_SECRET.
    4. npm run dev
  • Testing: npm test

WebSocket Chat

  • Purpose: Provides bi-directional real-time messaging with room-based isolation.
  • Stack: Node.js, ws (WebSocket library), Redis (optional) for pub/sub scaling.
  • Key Capabilities:
    • Broadcast and direct messaging channels.
    • Connection lifecycle hooks for join/leave notifications.
    • Extensible event schema for future moderation features.
  • Quick Start:
    1. cd websocket-chat
    2. npm install
    3. npm start
  • Integration Tip: Use the provided sample HTML client or integrate via native WebSocket clients with JSON payloads.

Log Parser CLI

  • Purpose: Extracts insights from structured and semi-structured logs to support operational reporting.
  • Stack: Node.js, commander, chalk.
  • Key Capabilities:
    • Pluggable parsers for JSON, CSV, and delimited formats.
    • Filters by severity, timestamp, and custom predicates.
    • Export to CSV or JSON for downstream analytics.
  • Quick Start:
    1. cd log-parser-cli
    2. npm install
    3. node ./src/index.js --help
  • Example: node ./src/index.js parse --input ./logs/app.log --format json --level error

Engineering Standards

  • Code Quality: ESLint and Prettier configurations ensure consistent formatting and linting across projects.
  • Testing: Unit and integration suites run via npm test; new features require coverage extensions.
  • Security: Environment variables hold secrets; avoid committing .env files. JWT secrets must be strong and rotated periodically.
  • Observability: Each service includes structured logging helpers ready for integration with centralized log platforms.

License

This repository is distributed under the MIT License. See LICENSE for details.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published