Skip to content

Commit

Permalink
name the controller metric ANCHOR_REQUEST_ACCEPTED
Browse files Browse the repository at this point in the history
  • Loading branch information
gvelez17 committed Apr 17, 2024
1 parent f656139 commit 4cd2e01
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/controllers/request-controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ export class RequestController {
)
}
logger.debug(`Found request for ${requestParams.cid} of stream ${requestParams.streamId}`)
Metrics.count(METRIC_NAMES.ANCHOR_ACCEPTED, 1, { source: parseOrigin(req) })
Metrics.count(METRIC_NAMES.ANCHOR_REQUEST_ACCEPTED, 1, { source: parseOrigin(req) })
return res.status(StatusCodes.ACCEPTED).json(found)
} catch (err: any) {
Metrics.count(METRIC_NAMES.REQUEST_NOT_CREATED, 1, { source: parseOrigin(req) })
Expand Down
2 changes: 2 additions & 0 deletions src/settings.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ export enum METRIC_NAMES {
ANCHOR_REQUESTS_BATCH_TIME = 'anchor_requests_batch_time',
ANCHOR_REQUESTS_BATCH_FAILURE_TIME = 'anchor_requests_batch_failure_time',

ANCHOR_REQUEST_ACCEPTED = 'anchor_request_accepted', // in controller

// *******************************************************************//
// Request Service
WRITE_TOTAL_TSDB = 'write_total_tsdb', // note _tsdb implies handles high cardinality
Expand Down

0 comments on commit 4cd2e01

Please sign in to comment.