/gincache

Simple memory cache middleware for gin API.

Primary LanguageGoMIT LicenseMIT

Go Reference codecov

Simple cache for gin

Simple memory cache for gin API.

E.g.:

  • Create an API cache adding the middleware to your route:
router.POST("/cache/list", gincache.CacheMiddleware(time.Hour*24, func(c *gin.Context) {
    // handler implementation		
}))