examples/README.md
This directory contains runnable examples demonstrating various go-micro features and patterns.
Each example can be run with go run . from its directory.
Basic RPC service demonstrating core concepts:
Run it:
cd hello-world
go run .
HTTP web service with service discovery:
Run it:
cd web-service
go run .
Multiple services in a single binary — the modular monolith pattern:
service.GroupRun it:
cd multi-service
go run .
Docker Compose deployment with MCP gateway, Consul registry, and Jaeger tracing:
docker-compose upSee the mcp/ directory for AI agent integration examples:
Multi-service project management app (Projects, Tasks, Team) with seed data and agent playground integration.
Some examples require external dependencies:
docker run -p 4222:4222 nats:latestdocker run -p 8500:8500 consul:latest agent -dev -ui -client=0.0.0.0docker run -p 6379:6379 redis:latestTo add a new example:
go run .