Esta página se muestra en inglés. Una traducción al español está en curso.
ScriptsJul 1, 2026·3 min de lectura

Revel — High-Productivity MVC Web Framework for Go

Revel is a full-stack MVC web framework for Go that provides hot code reload, a comprehensive testing suite, and batteries-included modules for routing, validation, and templating.

Listo para agents

Instalación lista para agent

Este activo puede instalarse después de elegir el runtime, revisar el plan y ejecutar el comando correspondiente.

Native · 98/100Política: permitir
Superficie agent
Cualquier agent MCP/CLI
Tipo
Skill
Instalación
Single
Confianza
Confianza: Established
Entrada
Revel Web Framework
Comando de instalación directa
npx -y tokrepo@latest install 9f9885bd-7568-11f1-9bc6-00163e2b0d79 --target codex

Ejecutar después de confirmar el plan con dry-run.

Introduction

Revel is a full-stack web framework for Go that follows the MVC pattern. It draws inspiration from Play Framework and Ruby on Rails, aiming to provide a productive developer experience with hot code reload and convention-over-configuration defaults for Go web applications.

What Revel Does

  • Provides a complete MVC architecture with controllers, models, and templates
  • Offers automatic hot code reload during development without manual restarts
  • Includes a built-in testing framework for functional and unit tests
  • Ships with a routing engine that maps URLs to controller actions via a routes file
  • Bundles validation, session management, caching, and job scheduling out of the box

Architecture Overview

Revel runs as a self-contained server process. Incoming HTTP requests are matched against a compiled route table, dispatched to controller actions, and rendered through Go's html/template engine. The framework intercepts source changes via a file watcher and triggers a recompile-and-restart cycle transparently, giving a scripting-language feel to compiled Go code.

Self-Hosting & Configuration

  • Install via go install github.com/revel/cmd/revel@latest
  • Create a new project with revel new <app-name>
  • Configuration lives in conf/app.conf with INI-style key-value pairs
  • Set http.addr and http.port for binding; TLS via http.ssl.* keys
  • Deploy as a compiled binary with revel package for production

Key Features

  • Hot code reload removes the edit-compile-run loop in development
  • Convention-based project layout reduces boilerplate decisions
  • Built-in interceptors (filters) for cross-cutting concerns like auth and logging
  • Integrated parameter validation with struct tag annotations
  • Job scheduling module for background and periodic tasks

Comparison with Similar Tools

  • Gin — minimal router; Revel is a full MVC framework with more built-in modules
  • Echo — focused on REST APIs; Revel adds templates, sessions, and job scheduling
  • Beego — similar full-stack scope; Revel emphasizes hot reload and Play-style routing
  • Buffalo — comparable productivity focus; Revel has a longer track record
  • Fiber — high-performance micro framework; Revel trades raw speed for developer convenience

FAQ

Q: Does Revel support Go modules? A: Yes. Since Revel v1.0 the framework fully supports Go modules for dependency management.

Q: Is hot reload suitable for production? A: No. Hot reload is a development feature. For production, use revel package to build a static binary.

Q: Can I use a different template engine? A: Yes. Revel's rendering layer is pluggable; you can swap in Pongo2 or any engine that satisfies the template interface.

Q: How does routing work? A: Routes are defined in conf/routes using a simple format mapping HTTP methods and URL patterns to controller actions.

Sources

Discusión

Inicia sesión para unirte a la discusión.
Aún no hay comentarios. Sé el primero en compartir tus ideas.

Activos relacionados