/go-service-guide:concurrencyfrom go-service-guide
Provides Go concurrency patterns: goroutine lifecycle management, errgroup for parallel requests, bounded concurrency, worker pools, and graceful shutdown with context cancellation.
Ships in go-service-guide. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
References: Examples
No fire-and-forget goroutines. Every goroutine must have managed lifecycle.
| Requirement | Description |
|---|---|
| Context cancellation | Pass ctx and respect ctx.Done() for graceful shutdown |
| Synchronization | Use sync.WaitGroup or errgroup.Group to wait for completion |
| Bounded concurrency | Limit parallel goroutines with semaphore or worker pool |
| Error propagation | Use errgroup when errors need to bubble up |
| Parallel requests | Always use errgroup for parallel HTTP/DB/API calls |
| Pattern | Use When |
|---|---|
sync.WaitGroup | Simple fan-out, no error collection needed |
errgroup.Group | Need first error, automatic cancellation |
errgroup.SetLimit(n) | Bounded concurrency with error handling |
| Worker pool | High-volume processing, backpressure needed |
| Do | Don't |
|---|---|
errgroup.Group with context | go func() { process() }() |
| Worker pool with fixed size | Unbounded for { go handle() } |
select on ctx.Done() | Ignore cancellation signals |
Explicit wg.Wait() | Hope goroutines finish |
g, ctx := errgroup.WithContext(ctx)
g.Go(func() error { return fetchA(ctx) })
g.Go(func() error { return fetchB(ctx) })
g.Go(func() error { return fetchC(ctx) })
if err := g.Wait(); err != nil {
return fmt.Errorf("parallel fetch: %w", err)
}
g, ctx := errgroup.WithContext(ctx)
g.SetLimit(10) // Max 10 concurrent goroutines
for _, item := range items {
item := item
g.Go(func() error { return process(ctx, item) })
}
return g.Wait()
For high-volume processing with backpressure control.
Always handle context cancellation in long-running goroutines.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
6 skills in this plugin
/architectureClean/hexagonal architecture rules, folder structure, interface ownership, and dependency direction. Use when creating new packages, services, or understanding codebase structure./go-styleUber Go style guide rules for guidelines, performance, and code style. Use when writing or reviewing Go code for style compliance./observabilityTracing with OpenTelemetry and structured logging with slog. Use when adding observability to services, handlers, or debugging production issues.npx claudepluginhub cemezgin/go-service-guide --plugin go-service-guideOther plugins' skills for the same job