Add local storage metrics #420

Merged
fyrchik merged 1 commit from dstepanov-yadro/frostfs-node:feat/local_storage_metrics into master 2023-07-26 21:07:58 +00:00

Closes #373

Closes #373
dstepanov-yadro force-pushed feat/local_storage_metrics from 1edb7d530c to 252485732e 2023-06-05 07:26:19 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 252485732e to 1e6d587cd1 2023-06-05 15:01:40 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 1e6d587cd1 to 8e01185bef 2023-06-05 15:17:26 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 8e01185bef to 07eeff247a 2023-06-05 15:22:18 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 07eeff247a to 8803b9ca1a 2023-06-05 15:23:48 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from d608597b0f to 0c38c55ecd 2023-06-06 10:22:07 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 0c38c55ecd to 392bff6c16 2023-06-07 09:28:44 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 392bff6c16 to 0410c3093e 2023-06-07 11:01:25 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from f8e2a2f095 to b9b46b909c 2023-06-07 14:07:50 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from b9b46b909c to c88455d515 2023-06-07 15:10:07 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from c88455d515 to 8c072bc306 2023-06-07 15:24:14 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from c05a213923 to ae3441c6a3 2023-06-09 12:46:24 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from ae3441c6a3 to 2411f37ff9 2023-06-09 12:53:15 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 4e44ca56b4 to 34c9416b84 2023-06-09 13:41:41 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 34c9416b84 to 81a57cbe3a 2023-06-09 13:51:36 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 81a57cbe3a to 7c58bca226 2023-06-09 14:31:17 +00:00 Compare
dstepanov-yadro changed title from WIP: Add local storage metrics to Add local storage metrics 2023-06-09 14:33:54 +00:00
dstepanov-yadro requested review from storage-core-committers 2023-06-09 14:33:59 +00:00
dstepanov-yadro requested review from storage-core-developers 2023-06-09 14:34:00 +00:00
aarifullin approved these changes 2023-06-13 09:42:42 +00:00
aarifullin left a comment
Member

LGTM. Brilliant work 👍

LGTM. Brilliant work :+1:
acid-ant requested changes 2023-06-14 10:51:08 +00:00
@ -179,2 +181,4 @@
if err == nil {
db.metrics.Close()
}
return nil
Member

Looks like needs to return err here.

Looks like needs to return err here.
Author
Member

fixed

fixed
acid-ant marked this conversation as resolved
@ -19,0 +30,4 @@
_, span := tracing.StartSpanFromContext(ctx, "metabase.FilterExpired",
trace.WithAttributes(
attribute.String("epoch", fmt.Sprintf("%v", epoch)),
Member

Is it possible to use strconv.FormatBool here and below?

Is it possible to use `strconv.FormatBool` here and below?
Author
Member

fixed

fixed
acid-ant marked this conversation as resolved
@ -281,1 +300,4 @@
func (db *DB) IsLocked(ctx context.Context, prm IsLockedPrm) (res IsLockedRes, err error) {
var (
startedAt = time.Now()
success = false
Member

Is it necessary to define success if it is unused?

Is it necessary to define `success` if it is unused?
Author
Member

fixed

fixed
acid-ant marked this conversation as resolved
dstepanov-yadro force-pushed feat/local_storage_metrics from 7c58bca226 to 2ea612af71 2023-06-14 11:48:55 +00:00 Compare
dstepanov-yadro requested review from acid-ant 2023-06-14 11:50:22 +00:00
acid-ant approved these changes 2023-06-14 14:14:02 +00:00
dstepanov-yadro force-pushed feat/local_storage_metrics from 2ea612af71 to 4cad86c21c 2023-06-16 07:15:04 +00:00 Compare
Author
Member

Also moved label keys and other consts to consts.go file.

Also moved label keys and other consts to `consts.go` file.
acid-ant approved these changes 2023-06-16 07:39:31 +00:00
fyrchik reviewed 2023-06-16 11:51:18 +00:00
@ -7,3 +13,3 @@
// Exists check if object with the specified address is stored in b.
func (b *Blobovnicza) Exists(addr oid.Address) (bool, error) {
func (b *Blobovnicza) Exists(ctx context.Context, addr oid.Address) (bool, error) {
Owner

Seems unrelated to the metrics addition, can we move it to a separate commit?

Seems unrelated to the metrics addition, can we move it to a separate commit?
Author
Member

Fixed

Fixed
fyrchik marked this conversation as resolved
@ -127,2 +131,3 @@
blobovnicza.WithReadOnly(b.readOnly),
blobovnicza.WithPath(filepath.Join(b.rootPath, p)),
blobovnicza.WithPath(path),
blobovnicza.WithMetrics(b.metrics.BlobovnicaMetrics(path)),
Owner

We currently can have a thousand of blobovniczas, I am not sure having a separate metric (not one!) for each is a good idea.
We have blobovniczatree as a part of blobstor, blobovnicza looks like an implementation detail.

We currently can have a _thousand_ of blobovniczas, I am not sure having a separate metric (not one!) for each is a good idea. We have `blobovniczatree` as a part of blobstor, `blobovnicza` looks like an implementation detail.
Author
Member

Fixed. Now blobovnizca metrics exports only open blobovnizca counter and total open blobovnizca size for blobovnizcas tree.

Fixed. Now blobovnizca metrics exports only open blobovnizca counter and total open blobovnizca size for blobovnizcas tree.
fyrchik marked this conversation as resolved
dstepanov-yadro force-pushed feat/local_storage_metrics from 4cad86c21c to 3b364959ba 2023-06-20 08:14:12 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from 3b364959ba to 037bfbb99e 2023-06-20 08:25:29 +00:00 Compare
fyrchik approved these changes 2023-06-20 13:24:59 +00:00
dstepanov-yadro force-pushed feat/local_storage_metrics from 037bfbb99e to f34878a574 2023-06-20 14:27:02 +00:00 Compare
dstepanov-yadro force-pushed feat/local_storage_metrics from f34878a574 to 03aa210145 2023-06-21 12:13:47 +00:00 Compare
fyrchik merged commit 03aa210145 into master 2023-06-21 12:17:29 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
4 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#420
No description provided.