Project Name | Stars | Downloads | Repos Using This | Packages Using This | Most Recent Commit | Total Releases | Latest Release | Open Issues | License | Language |
---|---|---|---|---|---|---|---|---|---|---|
Fiber | 25,420 | 656 | a day ago | 275 | September 08, 2022 | 41 | mit | Go | ||
⚡️ Express inspired web framework written in Go | ||||||||||
Iris | 23,794 | 320 | 2 days ago | 212 | September 21, 2022 | 78 | bsd-3-clause | Go | ||
The fastest HTTP/2 Go Web Framework. New, modern and easy to learn. Fast development with Code you control. Unbeatable cost-performance ratio :leaves: :rocket: | 谢谢 | #Go | ||||||||||
Locust | 20,965 | 7 days ago | 41 | September 21, 2022 | 17 | mit | Python | |||
Write scalable load tests in plain Python 🚗💨 | ||||||||||
Fasthttp | 19,305 | 645 | 1,957 | 2 days ago | 175 | September 03, 2022 | 69 | mit | Go | |
Fast HTTP package for Go. Tuned for high performance. Zero memory allocations in hot paths. Up to 10x faster than net/http | ||||||||||
Nginx Admins Handbook | 12,393 | a year ago | 1 | mit | Shell | |||||
How to improve NGINX performance, security, and other important things. | ||||||||||
Web Frameworks | 6,623 | a day ago | 13 | April 27, 2021 | 185 | mit | PHP | |||
Which is the fastest web framework? | ||||||||||
Webserver | 5,970 | 18 days ago | 99 | mit | C++ | |||||
A C++ High Performance Web Server | ||||||||||
Vibora | 5,639 | 2 years ago | 145 | mit | Python | |||||
Fast, asynchronous and elegant Python web framework. | ||||||||||
Jsdelivr | 4,819 | a month ago | 18 | mit | JavaScript | |||||
A free, fast, and reliable Open Source CDN for npm, GitHub, Javascript, and ESM | ||||||||||
Bombardier | 3,948 | 2 months ago | 10 | October 15, 2020 | 22 | mit | Go | |||
Fast cross-platform HTTP benchmarking tool written in Go |
gearbox ⚙️ is a web framework for building micro services written in Go with a focus on high performance. It's built on fasthttp which is up to 10x faster than net/http
⚙️ gearbox requires version 1.14
or higher of Go (Download Go)
Just use go get to download and install gearbox
go get -u github.com/gogearbox/gearbox
package main
import (
"github.com/gogearbox/gearbox"
)
func main() {
// Setup gearbox
gb := gearbox.New()
// Define your handlers
gb.Get("/hello", func(ctx gearbox.Context) {
ctx.SendString("Hello World!")
})
// Start service
gb.Start(":3000")
}
package main
import (
"github.com/gogearbox/gearbox"
)
func main() {
// Setup gearbox
gb := gearbox.New()
// Handler with parameter
gb.Get("/users/:user", func(ctx gearbox.Context) {
ctx.SendString(ctx.Param("user"))
})
// Start service
gb.Start(":3000")
}
package main
import (
"log"
"github.com/gogearbox/gearbox"
)
func main() {
// Setup gearbox
gb := gearbox.New()
// create a logger middleware
logMiddleware := func(ctx gearbox.Context) {
log.Printf("log message!")
// Next is what allows the request to continue to the next
// middleware/handler
ctx.Next()
}
// create an unauthorized middleware
unAuthorizedMiddleware := func(ctx gearbox.Context) {
ctx.Status(gearbox.StatusUnauthorized)
.SendString("You are unauthorized to access this page!")
}
// Register the log middleware for all requests
gb.Use(logMiddleware)
// Define your handlers
gb.Get("/hello", func(ctx gearbox.Context) {
ctx.SendString("Hello World!")
})
// Register the routes to be used when grouping routes
routes := []*gearbox.Route{
gb.Get("/id", func(ctx gearbox.Context) {
ctx.SendString("User X")
}),
gb.Delete("/id", func(ctx gearbox.Context) {
ctx.SendString("Deleted")
}),
}
// Group account routes
accountRoutes := gb.Group("/account", routes)
// Group account routes to be under api
gb.Group("/api", accountRoutes)
// Define a route with unAuthorizedMiddleware as the middleware
// you can define as many middlewares as you want and have
// the handler as the last argument
gb.Get("/protected", unAuthorizedMiddleware, func(ctx gearbox.Context) {
ctx.SendString("You accessed a protected page")
})
// Start service
gb.Start(":3000")
}
package main
import (
"github.com/gogearbox/gearbox"
)
func main() {
// Setup gearbox
gb := gearbox.New()
// Serve files in assets directory for prefix static
// for example /static/gearbox.png, etc.
gb.Static("/static", "./assets")
// Start service
gb.Start(":3000")
}
For more results, check Our Docs
Check Our Docs for more information about gearbox and how to contribute
Organizations that are helping to manage, promote, and support Gearbox ⚙️
![]() |
---|
trella: A B2B technology platform and trucking marketplace that connects shippers with carriers |
Gearbox ⚙️ is being used by multiple organizations including but not limited to
Feel free to chat with us on Discord, or email us at [email protected] if you have questions, or suggestions
gearbox is licensed under MIT License
Logo is created by Mahmoud Sayed and distributed under Creative Commons License