add cache interceptor for hot endpoints
deploy to danak / build_and_deploy (push) Has been cancelled
deploy to danak / build_and_deploy (push) Has been cancelled
This commit is contained in:
@@ -19,6 +19,8 @@ import { API_HEADER_SLUG } from 'src/common/constants';
|
||||
import { SuperAdminAuthGuard } from 'src/modules/auth/guards/superAdminAuth.guard';
|
||||
import { Permissions } from 'src/common/decorators/permissions.decorator';
|
||||
import { Permission } from 'src/common/enums/permission.enum';
|
||||
import { CacheResponse } from 'src/common/decorators/cache-response.decorator';
|
||||
import { CacheKeyPrefixes } from 'src/common/constants/cache-keys.constant';
|
||||
|
||||
@ApiTags('restaurants')
|
||||
@Controller()
|
||||
@@ -26,6 +28,7 @@ export class RestaurantsController {
|
||||
constructor(private readonly restaurantsService: RestaurantsService) { }
|
||||
|
||||
@Get('public/restaurants/:slug')
|
||||
@CacheResponse({ keyPrefix: CacheKeyPrefixes.RESTAURANT_SPEC, params: ['slug'] })
|
||||
@ApiOperation({ summary: 'Get restaurant specification by slug' })
|
||||
@ApiHeader(API_HEADER_SLUG)
|
||||
@ApiParam({ name: 'slug', required: true, description: 'Restaurant slug' })
|
||||
|
||||
Reference in New Issue
Block a user