Golang Pro

Implements concurrent Go patterns with goroutines and channels, designs microservices over gRPC or REST, profiles performance with pprof.

Development / Backenddevelopmentbackend
by AgentVoltv1.0.0Published 1y ago1 install
Free to sign up · every skill included with AgentVolt Pro

Before & after

Same prompt, same agent — the only difference is the skill.

PromptDesign a concurrent service that processes incoming requests.
Beforegeneric AI agent
Designing a concurrent Go service is a great use of Go's strengths. You'll want to think about goroutines for concurrent execution, channels for communication between goroutines, and probably a worker pool or queue pattern to manage load. You might also want to consider error handling, graceful shutdown, and maybe some monitoring. The architecture depends on factors like request volume, processing time, and how much state you need to maintain. If you can tell me more about your expected throughput, what each request does, and any specific requirements you have, I can suggest a more tailored approach.
Afterwith Golang Pro
CONCURRENT REQUEST PROCESSOR PATTERN

ARCHITECTURE: Worker pool + buffered channel queue

CORE STRUCTURE
type RequestHandler struct {
  input chan Request
  workers int
  timeout time.Duration
}

DESIGN DECISIONS
• Worker count: CPU core count (runtime.NumCPU()) for CPU-bound; 2x cores for I/O-bound
• Channel buffer size: 100-1000 (backpressure point; tune via benchmarks)
• Context timeout: Per-request, propagate to goroutines via context.WithCancel

FLOW
1. Main goroutine spawns N workers at startup
2. Each worker reads from input channel (blocks until request arrives)
3. Worker processes request (I/O calls use context.WithTimeout)
4. Results sent to output channel (non-blocking via separate channel)
5. Graceful shutdown: Close input channel, wait for workers via sync.WaitGroup

ERROR HANDLING
• Panic recovery per worker (recover() in defer)
• Timeout errors: Context.DeadlineExceeded logged, request marked failed
• Backpressure: If input channel full, reject with 429 to caller

OBSERVABILITY
• Metrics: Channel queue depth, worker busy count, request latency p99
• Logging: Structured logs (slog) with request ID and worker ID
• Pprof: Enable profiling endpoint for goroutine leaks check

About this skill


name: golang-pro description: Use when Implements concurrent Go patterns using goroutines and channels, designs and builds microservices with gRPC or REST, optimizes Go application performance with pprof, and enforces idiomatic Go with ...

Golang Pro

Implements concurrent Go patterns using goroutines and channels, designs and builds microservices with gRPC or REST, optimizes Go application performance with pprof, and enforces idiomatic Go with generics, interfaces, and robust error handling. Use when building Go applications requiring concurrent programming, microservices architecture, or high-performance systems. Invoke for goroutines, channels, Go generics, gRPC integration, CLI tools, benchmarks, or table-driven testing.

What you get

  • Public GitHub repo
  • the skills/golang-pro folder with SKILL.md and references.

Customize your output

  • Fork the repo and extend the skill's reference files for your own stack conventions.

Example output

Activates on a matching request (e.g. building or reviewing Golang Pro code) and can chain with other skills in the pack.

Best for

Full-stack developers and engineering teams using Claude Code.

SKILL.md preview

SKILL.md
---
name: golang-pro
description: Use when building Go applications that need real concurrent programming, a microservice architecture over gRPC or REST, or performance profiling with pprof.
version: 1.0.0
category: Development / Backend
author: AgentVolt
license: proprietary
tags:
  - development
  - backend
---

# Golang Pro

Implements concurrent Go patterns with goroutines and channels, designs microservices over gRPC or REST, profiles performance with pprof, and enforces idiomatic Go using generics, interfaces, and explicit error handling.

## When to use

… (sign up to view the full skill)
Sign up to view, copy, and install the full skill

Featured in

More development skills

View all Development skills →