Skip to content

Conversation

sgmonroy
Copy link
Contributor

@sgmonroy sgmonroy commented Sep 18, 2019

This change is Reviewable

@sgmonroy sgmonroy requested a review from oncilla September 18, 2019 14:13
Copy link
Contributor

@kormat kormat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: 0 of 28 files reviewed, 1 unresolved discussion (waiting on @oncilla and @sgmonroy)


go/lib/ringbuf/internal/metrics/ringbuf.go, line 28 at r1 (raw file):

func (l *RingbufLabels) Labels() []string {
	return []string{"RingID"}

ring_id

@sgmonroy sgmonroy removed the request for review from oncilla September 20, 2019 06:45
Copy link
Contributor Author

@sgmonroy sgmonroy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: 0 of 28 files reviewed, 1 unresolved discussion (waiting on @kormat)


go/lib/ringbuf/internal/metrics/ringbuf.go, line 28 at r1 (raw file):

Previously, kormat (Stephen Shirley) wrote…

ring_id

Done.

Copy link
Contributor

@kormat kormat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 27 of 28 files at r1, 1 of 1 files at r2.
Reviewable status: all files reviewed, 5 unresolved discussions (waiting on @karampok and @sgmonroy)


go/border/setup.go, line 68 at r2 (raw file):

	r.freePkts = ringbuf.New(1024, func() interface{} {
		return rpkt.NewRtrPkt()
	}, "free")

Maybe free_pkts would be clearer.


go/border/setup_test.go, line 315 at r2 (raw file):

		freePkts: ringbuf.New(maxNumPosixInput*inputBufCnt, func() interface{} {
			return rpkt.NewRtrPkt()
		}, "free"),

free_pkts


go/lib/ringbuf/ringbuf.go, line 20 at r2 (raw file):

	"sync"

	//"github.com/prometheus/client_golang/prometheus"

Drop.


go/lib/ringbuf/ringbuf.go, line 44 at r2 (raw file):

// New allocates a new Ring instance, with capacity for count entries. If newf
// is non-nil, it is called count times to pre-allocate the entries. labels
// are attached to the prometheus metrics, and desc is added as an extra label.

Needs updating.


go/lib/ringbuf/internal/metrics/metrics.go, line 19 at r2 (raw file):

const Namespace = "ringbuf"

var rb ringbuf

This can be simplified to var rb = newRingBuf()

Copy link
Contributor Author

@sgmonroy sgmonroy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewable status: 24 of 28 files reviewed, 5 unresolved discussions (waiting on @karampok and @kormat)


go/border/setup.go, line 68 at r2 (raw file):

Previously, kormat (Stephen Shirley) wrote…

Maybe free_pkts would be clearer.

Done.


go/border/setup_test.go, line 315 at r2 (raw file):

Previously, kormat (Stephen Shirley) wrote…

free_pkts

Done.


go/lib/ringbuf/ringbuf.go, line 20 at r2 (raw file):

Previously, kormat (Stephen Shirley) wrote…

Drop.

Done.


go/lib/ringbuf/ringbuf.go, line 44 at r2 (raw file):

Previously, kormat (Stephen Shirley) wrote…

Needs updating.

Done.


go/lib/ringbuf/internal/metrics/metrics.go, line 19 at r2 (raw file):

Previously, kormat (Stephen Shirley) wrote…

This can be simplified to var rb = newRingBuf()

Done.

Copy link
Contributor

@kormat kormat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

Reviewed 4 of 4 files at r3.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @karampok)

@sgmonroy sgmonroy merged commit 8fbe16d into scionproto:master Sep 23, 2019
@sgmonroy sgmonroy deleted the pub-ringbuf-metrics branch September 23, 2019 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants