Documentation

Everything you need to integrate Monaco into your institution's assessment workflow.

Architecture

Monaco follows a microservices architecture designed for security, scalability, and real-time communication.

FrontendReact/Next.jsMonaco EditorREST APIWebSocketAPI GatewayGo Backend• Request Routing• Job Queue• WebSocket HandlerExecuteExecution EngineContainer Manager• Resource Limits• Timeout Control• Output StreamingSpawnDocker ContainersPythonJavaC/C++IsolatedNo NetworkNo PersistenceLegendREST RequestWebSocket

Components

Frontend

React/Next.js application with Monaco Editor for code editing and real-time output display.

API Gateway

Go backend handling REST endpoints, WebSocket connections, and job queue management.

Execution Engine

Manages Docker container lifecycle, resource limits, timeouts, and output streaming.

Docker Containers

Isolated execution environments for each language with no network access or persistence.

Execution Flow

1

User submits code via REST API POST /api/submit

2

Backend assigns unique ID and queues the execution job

3

User connects to WebSocket for real-time updates

4

Execution Engine spawns isolated Docker container

5

Code output streams back through WebSocket

6

Container is destroyed after execution completes