Developer Verification & Recruitment Platform - Microservices Architecture
VerifyDev automatically verifies developer skills by analyzing their GitHub repositories using AI, assigns Aura scores, and connects verified developers with recruiters.
- Architecture Overview
- Communication Architecture - gRPC Implementation
- Performance Analysis - Latency Metrics & Benchmarks
- Services
- API Routes
- Getting Started
βββββββββββββββββββ
β Frontend β
β (Next.js/React β
β Native) β
ββββββββββ¬βββββββββ
β JSON/HTTP
βΌ
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β NGINX API GATEWAY β
β (Port 8000) β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β β’ Request Routing β’ CORS Handling β’ Load Balancing β β
β β β’ Rate Limiting β’ Security Headers β’ Gzip Compression β β
β β β’ SSL Termination β’ Error Handling β’ Health Checks β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββ¬βββββββββββββββββββββββββββββββββββββββ
β HTTP/JSON (proxy_pass)
βββββββββββββββββββββββββββββΌββββββββββββββββββββββββββββ
β β β
βΌ βΌ βΌ
βββββββββββββββββββ βββββββββββββββββββ βββββββββββββββββββ
β Auth Service β β User Service β β Job Service β
β HTTP :3001 β β HTTP :3002 β β HTTP :3004 β
β β β gRPC :50051 β β β
β β’ GitHub OAuth β β β’ User Profile β β β’ Job Listings β
β β’ JWT Tokens β β β’ Skills CRUD β β β’ Applications β
β β’ Sessions β β β’ Projects β β β’ Recruiter API β
β β’ OTP Auth β β β’ Experience β β β’ Messages β
βββββββββββββββββββ ββββββββββ¬βββββββββ βββββββββββββββββββ
β
β β‘ gRPC (Binary Protocol Buffers)
β Inter-service communication
βΌ
ββββββββββββββββββββββββββββββββ
β Recruiter Service β
β HTTP :3005 β
β gRPC :50054 β
β β
β β’ Candidate Search (gRPC) β
β β’ BatchGetUsers (gRPC) β
β β’ Profile Fetch (gRPC) β
ββββββββββββββββββββββββββββββββ
ββββββββββββββββββββββββββββββββ
β Project Analyzer (Go) β
β (Port 8001) β
β β
β β’ Clone GitHub Repos β
β β’ Detect Tech Stack β
β β’ AI Analysis (Gemini) β
β β’ Extract Skills β
ββββββββββββββββββββββββββββββββ
β
β (RabbitMQ)
βΌ
ββββββββββββββββββββββββββββββββ
β Aura Processor β
β β
β β’ Calculate Aura Score β
β β’ Update User Stats β
ββββββββββββββββββββββββββββββββ
βββββββββββββββββββ βββββββββββββββββββ
βRecruiter Serviceβ β Resume Service β
β (Port 3005) β β (Port 8003) β
β β β β
β β’ Candidates β β β’ PDF Generate β
β β’ Interviews β β β’ Templates β
β β’ Shortlists β β β
βββββββββββββββββββ βββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β INFRASTRUCTURE β
β βββββββββββββββββ βββββββββββββββββ βββββββββββββββββββββββββ β
β β Redis β β RabbitMQ β β MongoDB (Atlas) β β
β β (Port 6379) β β (Port 5672) β β β β
β β β β β β β’ Users, Sessions β β
β β β’ Sessions β β β’ Async Jobs β β β’ Projects, Skills β β
β β β’ Cache β β β’ Events β β β’ Jobs, Applications β β
β βββββββββββββββββ βββββββββββββββββ βββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Protocol Legend:
JSON/HTTP- Frontend to Gateway and Gateway to Servicesβ‘ gRPC- Service-to-Service (low latency, binary)RabbitMQ- Async event-driven communication
The backend uses a Hybrid Communication Pattern optimized for low latency and scalability:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β COMMUNICATION FLOW β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Frontend/Mobile (Next.js, React Native) β
β β β
β β JSON/HTTP REST (Human-readable, debuggable) β
β βΌ β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β API GATEWAY (Nginx - Port 8000) β β
β β β’ CORS Handling β’ Rate Limiting β’ Load Balance β β
β β β’ SSL Termination β’ Request Routing β’ Compression β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β β
β β HTTP/JSON (proxy_pass) β Simple, Compatible β
β βΌ β
β ββββββββββββ ββββββββββββ ββββββββββββ ββββββββββββββββ β
β β Auth β β User β β Job β β Recruiter β β
β β :3001 β β :3002 β β :3004 β β :3005 β β
β ββββββββββββ ββββββ¬ββββββ ββββββββββββ ββββββββ¬ββββββββ β
β β β β
β β gRPC (Binary Protocol Buffers) β
β β β‘ Low latency, High throughput β
β βΌ β β
β ββββββββββββββ β β
β β gRPC :50051βββββββββββββββββββββββββ β
β ββββββββββββββ β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
| Layer | Protocol | Why? |
|---|---|---|
| Frontend β Gateway | JSON/HTTP | Human-readable, debuggable, browser-native |
| Gateway β Services | HTTP/JSON | Nginx compatibility, simple routing, easy monitoring |
| Service β Service | gRPC | β‘ Binary protocol, 10x faster, streaming, strict contracts |
gRPC is used for internal service communication where performance matters most:
ββββββββββββββββββββββ gRPC ββββββββββββββββββββββ
β Recruiter Service β ββββββββββββΊ β User Service β
β :3005 β (Binary) β :50051 β
β β β β
β β’ BatchGetUsers() β β β’ GetUser() β
β β’ SearchCandidates β β β’ BatchGetUsers() β
β β’ GetUserProfile() β β β’ SearchCandidates β
ββββββββββββββββββββββ ββββββββββββββββββββββ
- β‘ 10x Lower Latency: Binary Protocol Buffers vs JSON parsing
- π¦ Smaller Payload: ~30% smaller than JSON
- π Strict Contracts: Proto files are the single source of truth
- π Streaming: Bi-directional streaming for real-time updates
- π Built-in Retries: Automatic retry with exponential backoff
-
Proto Definitions (
backend/proto/)- Source of truth for service-to-service contracts
- Organized by domain:
user/,job/,recruiter/,common/ - Dynamic loading with
@grpc/proto-loader(no compilation step)
-
Shared Utilities (
backend/shared/)GrpcServer: Standardized server setup with keepalive, error handlingGrpcClient: Connection pooling, automatic retries, timeoutsGrpcClientPool: Singleton pattern for connection reuse
-
Port Configuration
Service HTTP Port gRPC Port User Service 3002 50051 Recruiter Service 3005 50054 Job Service 3004 50052* *Planned
Recruiter Service calling User Service via gRPC:
// recruiter-service/src/grpc/user-client.ts
import { GrpcClient } from '../../../shared/grpc-client';
const userClient = new GrpcClient(UserServiceProto, {
address: 'user-service:50051',
serviceName: 'UserService',
maxRetries: 3,
timeout: 10000,
});
// Get multiple users in ONE call (instead of N HTTP calls)
const users = await batchGetUsers(['user1', 'user2', 'user3']);
// β‘ Single TCP connection, binary payload, parallel fetchπ Detailed Guide: See GRPC_IMPLEMENTATION_GUIDE.md for step-by-step tutorial.
| Service | HTTP Port | gRPC Port | Language | Description |
|---|---|---|---|---|
| Gateway | 8000 | - | Nginx | API Gateway - routing, CORS, rate limiting |
| Auth Service | 3001 | - | TypeScript | GitHub OAuth, JWT tokens, sessions |
| User Service | 3002 | 50051 | TypeScript | Profiles, skills, projects, experience |
| Job Service | 3004 | 50052* | TypeScript | Jobs, applications, recruiter management |
| Recruiter Service | 3005 | 50054 | TypeScript | Candidate search, interviews, messaging |
| Chat Service | 3006 | - | TypeScript | Real-time messaging (Socket.IO) |
| Resume Service | 8003 | - | Go | PDF resume generation |
| Project Analyzer | 8001 | - | Go | GitHub analysis, tech detection, AI |
| Aura Processor | - | - | TypeScript | Score calculations (worker) |
| Redis | 6379 | - | - | Session cache, rate limiting |
| RabbitMQ | 5672 | - | - | Message queue for async tasks |
*Planned | **Active gRPC server
- Languages: TypeScript (Node.js), Go
- Framework: Express.js
- ORM: Prisma
- Database: MongoDB Atlas
- Cache: Redis
- Message Queue: RabbitMQ
- API Gateway: Nginx
- Container: Docker + Docker Compose
- LLM: Google Gemini API
- Use: Code analysis, skill extraction
- CI/CD: GitHub Actions
- Cloud: Azure VM
- Reverse Proxy: Nginx
| Route | β Service | Description |
|---|---|---|
/api/v1/auth/* |
auth-service:3001 | Authentication |
/api/v1/users/* |
user-service:3002 | User profiles |
/api/v1/projects/* |
user-service:3002 | Project management |
/api/v1/skills/* |
user-service:3002 | Skills management |
/api/v1/experiences/* |
user-service:3002 | Experience entries |
/api/v1/jobs/* |
job-service:3004 | Job listings |
/api/v1/applications/* |
job-service:3004 | Job applications |
/api/v1/recruiter/* |
job-service:3004 | Recruiter job mgmt |
/api/v1/recruiters/* |
recruiter-service:3005 | Recruiter accounts |
/api/v1/candidates/* |
recruiter-service:3005 | Candidate search |
/api/v1/interviews/* |
recruiter-service:3005 | Interview scheduling |
/api/v1/messages/* |
job-service:3004 | Messaging |
/api/v1/templates/* |
recruiter-service:3005 | Message templates |
/api/v1/resumes/* |
resume-service:8003 | Resume generation |
/health |
gateway | Health check |
| Queue | Producer | Consumer | Purpose |
|---|---|---|---|
project.analyze.request |
user-service | project-analyzer | Trigger analysis |
project.analyzed |
project-analyzer | aura-processor | Analysis results |
resume.generate.request |
user-service | resume-service | Resume generation |
User adds project
β
βΌ
ββββββββββββββββββββ publish βββββββββββββββββββββ
β User Service β ββββββββββΊ β project.analyze β
ββββββββββββββββββββ β .request β
βββββββββββ¬ββββββββββ
β consume
βΌ
βββββββββββββββββββββ
β Project Analyzer β
β (Go) β
βββββββββββ¬ββββββββββ
β publish
βΌ
βββββββββββββββββββββ
β project.analyzed β
βββββββββββ¬ββββββββββ
β consume
βΌ
βββββββββββββββββββββ
β Aura Processor β
β (updates user) β
βββββββββββββββββββββ
1. User clicks "Login with GitHub"
2. Frontend β GET /api/v1/auth/github
3. Gateway β Auth Service
4. Auth Service redirects to GitHub OAuth
5. User authorizes on GitHub
6. GitHub β /api/v1/auth/github/callback
7. Auth Service:
β’ Exchanges code for GitHub token
β’ Fetches user info from GitHub API
β’ Creates/updates user in MongoDB
β’ Creates session in DB
β’ Generates JWT tokens (access + refresh)
8. Redirect to Frontend with tokens
// Each service verifies JWT independently
// No inter-service auth calls needed
// Access Token: 15 min expiry
{
userId: "xxx",
sessionId: "yyy",
type: "access"
}
// Refresh Token: 7 days expiry
{
userId: "xxx",
sessionId: "yyy",
type: "refresh"
}All services share JWT_ACCESS_SECRET for verification.
- User selects GitHub repo
- User Service creates project record (status:
pending) - User Service publishes to RabbitMQ:
{ "projectId": "xxx", "userId": "yyy", "repoUrl": "https://github.com/user/repo", "repoName": "repo", "defaultBranch": "main" } - Project Analyzer (Go) consumes and:
- Clones repository
- Scans file structure
- Detects tech stack (package.json, go.mod, docker-compose, etc.)
- Identifies architecture patterns (microservices, monolith)
- Sends to Gemini AI for deep analysis
- Extracts skills with confidence scores
- Project Analyzer publishes results
- Aura Processor consumes and:
- Updates project status to
completed - Adds verified skills to user profile
- Recalculates Aura score
- Updates project status to
Detects:
βββ Languages: TypeScript, JavaScript, Go, Python, Rust, Java
βββ Frameworks: Next.js, React, Express, Gin, FastAPI, Spring
βββ Databases: MongoDB, PostgreSQL, Redis, MySQL
βββ Infrastructure: Docker, Kubernetes, AWS, Terraform
βββ DevOps: GitHub Actions, Jenkins, ArgoCD
βββ Architecture: Microservices, Monolith, Serverless
backend/
βββ .github/
β βββ workflows/
β βββ deploy-dev.yml # CI/CD pipeline
β
βββ gateway/ # Nginx API Gateway
β βββ nginx.conf # Main config
β βββ conf.d/
β β βββ api.conf # Route definitions
β βββ Dockerfile
β
βββ auth-service/ # Authentication
β βββ src/
β β βββ api/v1/
β β β βββ controllers/
β β β βββ routes/
β β βββ middlewares/
β β βββ utils/
β βββ prisma/
β β βββ schema.prisma
β βββ Dockerfile
β
βββ user-service/ # User Management
β βββ src/
β β βββ api/v1/
β β βββ domain/ # Business logic
β β βββ rabbitmq/ # Message publisher
β β βββ ...
β βββ prisma/
β βββ Dockerfile
β
βββ job-service/ # Jobs & Applications
β βββ src/
β βββ prisma/
β βββ Dockerfile
β
βββ recruiter-service/ # Recruiter Features
β βββ src/
β βββ prisma/
β βββ Dockerfile
β
βββ resume-service/ # PDF Generation (Go)
β βββ Dockerfile
β
βββ aura-processor/ # Score Calculator
β βββ Dockerfile
β
βββ project-analyzer/ # GitHub Analysis (Go)
β βββ cmd/
β βββ internal/
β β βββ analyzer/ # Analysis logic
β β βββ github/ # GitHub API client
β β βββ gemini/ # AI integration
β βββ Dockerfile
β
βββ docker-compose.yml # Container orchestration
βββ README.md
- Docker & Docker Compose
- MongoDB Atlas account
- GitHub OAuth App
- Google Gemini API key
# 1. Clone
git clone https://github.com/verifydev-me/backend.git
cd backend
# 2. Create .env file
cp .env.example .env
# Edit .env with your values
# 3. Start services
docker-compose up -d
# 4. Check status
docker-compose ps
# 5. View logs
docker-compose logs -f# Required in .env or docker-compose
# Database
DATABASE_URL=mongodb+srv://...
# JWT (same across all services)
JWT_ACCESS_SECRET=your-32-char-secret
JWT_REFRESH_SECRET=your-32-char-secret
# GitHub OAuth
GITHUB_CLIENT_ID=xxx
GITHUB_CLIENT_SECRET=xxx
GITHUB_CALLBACK_URL=https://api.yourdomain.com/api/v1/auth/github/callback
# GitHub Token (for repo cloning)
GITHUB_TOKEN=ghp_xxx
# AI
GEMINI_API_KEY=xxx
# Frontend
FRONTEND_URL=https://verifydev.me
ALLOWED_ORIGINS=https://verifydev.me,http://localhost:3000Trigger: Push to dev branch
1. Checkout code
2. SSH into Azure VM
3. Setup deploy keys
4. Pull latest code
5. docker-compose down
6. docker-compose up -d --build
7. Health check all services
8. Cleanup old images
- API: https://api.verifydev.me
- Frontend: https://verifydev.me
# Gateway
curl https://api.verifydev.me/health
# Individual services (internal)
curl http://localhost:3001/health # Auth
curl http://localhost:3002/health # User
curl http://localhost:3004/health # Job
curl http://localhost:3005/health # Recruiter
curl http://localhost:8001/health # Analyzer
curl http://localhost:8003/health # Resume| Pattern | Implementation |
|---|---|
| API Gateway | Nginx routes all requests, handles CORS/rate limiting |
| Microservices | Independent services with own databases |
| Event-Driven | RabbitMQ for async communication |
| Stateless Auth | JWT verified independently by each service |
| Repository | Prisma ORM for data access |
| Dead Letter Queue | Failed messages go to DLX for retry |
- Backend Architecture: Keshav Sharma
Built with β€οΈ for developers who want their skills verified