Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cs: refactor metrics approach #3931

Merged
merged 1 commit into from
Nov 19, 2020
Merged

cs: refactor metrics approach #3931

merged 1 commit into from
Nov 19, 2020

Conversation

oncilla
Copy link
Contributor

@oncilla oncilla commented Nov 19, 2020

Namespaces bs, ps are coalesced into control, no longer valid or redundant
metrics are dropped, metric and label names are unified.

Furthermore, minor bugs are fixed and tracing support is added to the scion tool.

List of replaced metrics. Note the label changes.

# Label change: in_if_id -> ingress_interface
# HELP control_beaconing_received_beacons_total Total number of beacons received.
new:   control_beaconing_received_beacons_total{ingress_interface="41",neighbor_isd_as="1-ff00:0:110",result="ok_new"} 1
old:   bs_beaconing_received_beacons_total{in_if_id="41",neigh_ia="0-0",result="ok_new"} 1

# HELP control_segment_lookup_requests_total Total number of path segments requests received.
new:   control_segment_lookup_requests_total{dst_isd="1",result="ok_success",seg_type="down"} 1
old:   ps_requests_total{dst_isd="1",result="ok_success",seg_type="down"} 2

# HELP control_segment_lookup_segments_sent_total Total number of path segments sent in the replies.
new:   control_segment_lookup_segments_sent_total{dst_isd="1",seg_type="down"} 1
old:   ps_requests_replied_segments_total{dst_isd="1",seg_type="down"} 2

# Label change: type -> seg_type
# HELP control_segment_registry_segments_received_total Total number of path segments received through registrations.
new:   control_segment_registry_segments_received_total{result="ok_new",seg_type="down",src="isd_local"} 2
old:   ps_registrations_total{result="ok_new",src="unknown",type="down"} 2

# HELP control_fetcher_seg_requests_total The number of segment request sent.
new:   control_fetcher_seg_requests_total{result="ok_success"} 3
old:   ps_fetcher_seg_requests_total{result="ok_success"} 3

# Label change: eg_if_id -> egress_interface
# HELP control_beaconing_originated_beacons_total Total number of beacons originated.
new:   control_beaconing_originated_beacons_total{egress_interface="1",result="ok_success"} 6
old:   bs_beaconing_originated_beacons_total{eg_if_id="1",result="ok_success"} 6

# Label change: in_if_id -> ingress_interface, eg_if_id -> egress_interface, start_ia -> start_isd_as
# HELP control_beaconing_propagated_beacons_total Total number of beacons propagated.
new:   control_beaconing_propagated_beacons_total{start_isd_as="1-ff00:0:110",ingress_interface="41",egress_interface="22",result="ok_success"}
old:   bs_beaconing_propagated_beacons_total{start_ia="1-ff00:0:110",in_if_id="41",eg_if_id="22",result="ok_success"}

# HELP control_beaconing_propagator_internal_errors_total Total number of internal errors in the beacon propagator.
new:   control_beaconing_propagator_internal_errors_total
old:   bs_beaconing_propagator_errors_total

# Label change: in_if_id -> ingress_interface, eg_if_id -> egress_interface, start_ia -> start_isd_as
# HELP control_beaconing_registered_segments_total Total number of segments registered.
new:   control_beaconing_registered_segments_total{ingress_interface="41",result="ok_new",seg_type="up",start_isd_as="1-ff00:0:110"} 1
old:   bs_beaconing_registered_beacons_total{in_if_id="41",result="ok_success",seg_type="up",start_ia="1-ff00:0:110"} 1

# HELP control_beaconing_registrar_internal_errors_total Total number of internal errors in the beacon registrar.
new:   control_beaconing_registrar_internal_errors_total{seg_type="up"}
old:   bs_beaconing_registrar_errors_total{seg_type="up"}

# HELP control_pathstorage_cleaner_periodic_period_duration_seconds The period of this job.
new:   control_pathstorage_cleaner_periodic_period_duration_seconds 10
old:   periodic_period_duration_seconds 10

# HELP control_pathstorage_cleaner_periodic_runtime_duration_seconds_total Total time spend on every periodic run.
new:   control_pathstorage_cleaner_periodic_runtime_duration_seconds_total 0.060531525
old:   periodic_runtime_duration_seconds_total 0.060531525

# HELP control_pathstorage_cleaner_periodic_runtime_timestamp_seconds The unix timestamp when the periodic run started.
new:   control_pathstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09
old:   periodic_runtime_timestamp_seconds 1.603717526e+09

# HELP control_pathstorage_segments_cleaner_deleted_total Number of deleted entries total.
new:   control_pathstorage_segments_cleaner_deleted_total 0
old:   ps_segments_cleaner_deleted_total 0

# HELP control_pathstorage_segments_cleaner_results_total Results of running the cleaner, either ok or err.
new:   control_pathstorage_segments_cleaner_results_total{result="ok"} 132
old:   ps_segments_cleaner_results_total{result="ok"} 132

# HELP control_pathstorage_revocation_cleaner_deleted_total Number of deleted entries total.
new:   control_pathstorage_revocation_cleaner_deleted_total 0
old:   ps_revocation_cleaner_deleted_total 0

# HELP control_pathstorage_revocation_cleaner_results_total Results of running the cleaner, either ok or err.
new:   control_pathstorage_revocation_cleaner_results_total{result="ok"} 132
old:   ps_revocation_cleaner_results_total{result="ok"} 132

# HELP control_beaconstorage_beacon_cleaner_deleted_total Number of deleted entries total.
new:   control_beaconstorage_beacon_cleaner_deleted_total 0
old:   bs_beacon_cleaner_deleted_total 0

# HELP control_beaconstorage_beacon_cleaner_results_total Results of running the cleaner, either ok or err.
new:   control_beaconstorage_beacon_cleaner_results_total{result="ok"} 44
old:   bs_beacon_cleaner_results_total{result="ok"} 44

# HELP control_beaconstorage_cleaner_periodic_period_duration_seconds The period of this job.
new:   control_beaconstorage_cleaner_periodic_period_duration_seconds 30
old:   beaconstorage_cleaner_periodic_period_duration_seconds 30

# HELP control_beaconstorage_cleaner_periodic_runtime_duration_seconds_total Total time spend on every periodic run.
new:   control_beaconstorage_cleaner_periodic_runtime_duration_seconds_total 0.028032182999999995
old:   beaconstorage_cleaner_periodic_runtime_duration_seconds_total 0.028032182999999995

# HELP control_beaconstorage_cleaner_periodic_runtime_timestamp_seconds The unix timestamp when the periodic run started.
new:   control_beaconstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09
old:   beaconstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09

# HELP control_beaconstorage_revocation_cleaner_deleted_total Number of deleted entries total.
new:   control_beaconstorage_revocation_cleaner_deleted_total 0
old:   bs_revocation_cleaner_deleted_total 0

# HELP control_beaconstorage_revocation_cleaner_results_total Results of running the cleaner, either ok or err.
new:   control_beaconstorage_revocation_cleaner_results_total{result="ok"} 39
old:   bs_revocation_cleaner_results_total{result="ok"} 39

List of removed metrics

bs_beaconing_originator_run_durations_seconds_total
bs_beaconing_propagator_interface_duration_seconds_total
bs_beaconing_propagator_run_duration_seconds_total
bs_beaconing_registrar_run_duration_seconds_total
bs_ifstate_state
bs_ifstate_issued_revocations_total
bs_ifstate_revocations_duration_seconds_total
bs_ifstate_sent_revocations_total
bs_keepalive_sent_msgs_total
bs_keepalive_received_msgs_total
bs_revocation_received_revocations_total
ps_requests_replied_revocations_total
ps_revocation_received_revocations_total
ps_segment_sync_registrations_total
ps_segment_sync_pushes_total

This change is Reviewable

Namespaces `bs`, `ps` are coalesced into `control`, no longer valid or redundant
metrics are dropped, metric and label names are unified.

Furthermore, minor bugs are fixed and tracing support is added to the `scion` tool.

List of replaced metrics. Note the label changes.

    # Label change: in_if_id -> ingress_interface
    # HELP control_beaconing_received_beacons_total Total number of beacons received.
    new:   control_beaconing_received_beacons_total{ingress_interface="41",neighbor_isd_as="1-ff00:0:110",result="ok_new"} 1
    old:   bs_beaconing_received_beacons_total{in_if_id="41",neigh_ia="0-0",result="ok_new"} 1

    # HELP control_segment_lookup_requests_total Total number of path segments requests received.
    new:   control_segment_lookup_requests_total{dst_isd="1",result="ok_success",seg_type="down"} 1
    old:   ps_requests_total{dst_isd="1",result="ok_success",seg_type="down"} 2

    # HELP control_segment_lookup_segments_sent_total Total number of path segments sent in the replies.
    new:   control_segment_lookup_segments_sent_total{dst_isd="1",seg_type="down"} 1
    old:   ps_requests_replied_segments_total{dst_isd="1",seg_type="down"} 2

    # Label change: type -> seg_type
    # HELP control_segment_registry_segments_received_total Total number of path segments received through registrations.
    new:   control_segment_registry_segments_received_total{result="ok_new",seg_type="down",src="isd_local"} 2
    old:   ps_registrations_total{result="ok_new",src="unknown",type="down"} 2

    # HELP control_fetcher_seg_requests_total The number of segment request sent.
    new:   control_fetcher_seg_requests_total{result="ok_success"} 3
    old:   ps_fetcher_seg_requests_total{result="ok_success"} 3

    # Label change: eg_if_id -> egress_interface
    # HELP control_beaconing_originated_beacons_total Total number of beacons originated.
    new:   control_beaconing_originated_beacons_total{egress_interface="1",result="ok_success"} 6
    old:   bs_beaconing_originated_beacons_total{eg_if_id="1",result="ok_success"} 6

    # Label change: in_if_id -> ingress_interface, eg_if_id -> egress_interface, start_ia -> start_isd_as
    # HELP control_beaconing_propagated_beacons_total Total number of beacons propagated.
    new:   control_beaconing_propagated_beacons_total{start_isd_as="1-ff00:0:110",ingress_interface="41",egress_interface="22",result="ok_success"}
    old:   bs_beaconing_propagated_beacons_total{start_ia="1-ff00:0:110",in_if_id="41",eg_if_id="22",result="ok_success"}

    # HELP control_beaconing_propagator_internal_errors_total Total number of internal errors in the beacon propagator.
    new:   control_beaconing_propagator_internal_errors_total
    old:   bs_beaconing_propagator_errors_total

    # Label change: in_if_id -> ingress_interface, eg_if_id -> egress_interface, start_ia -> start_isd_as
    # HELP control_beaconing_registered_segments_total Total number of segments registered.
    new:   control_beaconing_registered_segments_total{ingress_interface="41",result="ok_new",seg_type="up",start_isd_as="1-ff00:0:110"} 1
    old:   bs_beaconing_registered_beacons_total{in_if_id="41",result="ok_success",seg_type="up",start_ia="1-ff00:0:110"} 1

    # HELP control_beaconing_registrar_internal_errors_total Total number of internal errors in the beacon registrar.
    new:   control_beaconing_registrar_internal_errors_total{seg_type="up"}
    old:   bs_beaconing_registrar_errors_total{seg_type="up"}

    # HELP control_pathstorage_cleaner_periodic_period_duration_seconds The period of this job.
    new:   control_pathstorage_cleaner_periodic_period_duration_seconds 10
    old:   periodic_period_duration_seconds 10

    # HELP control_pathstorage_cleaner_periodic_runtime_duration_seconds_total Total time spend on every periodic run.
    new:   control_pathstorage_cleaner_periodic_runtime_duration_seconds_total 0.060531525
    old:   periodic_runtime_duration_seconds_total 0.060531525

    # HELP control_pathstorage_cleaner_periodic_runtime_timestamp_seconds The unix timestamp when the periodic run started.
    new:   control_pathstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09
    old:   periodic_runtime_timestamp_seconds 1.603717526e+09

    # HELP control_pathstorage_segments_cleaner_deleted_total Number of deleted entries total.
    new:   control_pathstorage_segments_cleaner_deleted_total 0
    old:   ps_segments_cleaner_deleted_total 0

    # HELP control_pathstorage_segments_cleaner_results_total Results of running the cleaner, either ok or err.
    new:   control_pathstorage_segments_cleaner_results_total{result="ok"} 132
    old:   ps_segments_cleaner_results_total{result="ok"} 132

    # HELP control_pathstorage_revocation_cleaner_deleted_total Number of deleted entries total.
    new:   control_pathstorage_revocation_cleaner_deleted_total 0
    old:   ps_revocation_cleaner_deleted_total 0

    # HELP control_pathstorage_revocation_cleaner_results_total Results of running the cleaner, either ok or err.
    new:   control_pathstorage_revocation_cleaner_results_total{result="ok"} 132
    old:   ps_revocation_cleaner_results_total{result="ok"} 132

    # HELP control_beaconstorage_beacon_cleaner_deleted_total Number of deleted entries total.
    new:   control_beaconstorage_beacon_cleaner_deleted_total 0
    old:   bs_beacon_cleaner_deleted_total 0

    # HELP control_beaconstorage_beacon_cleaner_results_total Results of running the cleaner, either ok or err.
    new:   control_beaconstorage_beacon_cleaner_results_total{result="ok"} 44
    old:   bs_beacon_cleaner_results_total{result="ok"} 44

    # HELP control_beaconstorage_cleaner_periodic_period_duration_seconds The period of this job.
    new:   control_beaconstorage_cleaner_periodic_period_duration_seconds 30
    old:   beaconstorage_cleaner_periodic_period_duration_seconds 30

    # HELP control_beaconstorage_cleaner_periodic_runtime_duration_seconds_total Total time spend on every periodic run.
    new:   control_beaconstorage_cleaner_periodic_runtime_duration_seconds_total 0.028032182999999995
    old:   beaconstorage_cleaner_periodic_runtime_duration_seconds_total 0.028032182999999995

    # HELP control_beaconstorage_cleaner_periodic_runtime_timestamp_seconds The unix timestamp when the periodic run started.
    new:   control_beaconstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09
    old:   beaconstorage_cleaner_periodic_runtime_timestamp_seconds 1.603717526e+09

    # HELP control_beaconstorage_revocation_cleaner_deleted_total Number of deleted entries total.
    new:   control_beaconstorage_revocation_cleaner_deleted_total 0
    old:   bs_revocation_cleaner_deleted_total 0

    # HELP control_beaconstorage_revocation_cleaner_results_total Results of running the cleaner, either ok or err.
    new:   control_beaconstorage_revocation_cleaner_results_total{result="ok"} 39
    old:   bs_revocation_cleaner_results_total{result="ok"} 39

List of removed metrics

    bs_beaconing_originator_run_durations_seconds_total
    bs_beaconing_propagator_interface_duration_seconds_total
    bs_beaconing_propagator_run_duration_seconds_total
    bs_beaconing_registrar_run_duration_seconds_total
    bs_ifstate_state
    bs_ifstate_issued_revocations_total
    bs_ifstate_revocations_duration_seconds_total
    bs_ifstate_sent_revocations_total
    bs_keepalive_sent_msgs_total
    bs_keepalive_received_msgs_total
    bs_revocation_received_revocations_total
    ps_requests_replied_revocations_total
    ps_revocation_received_revocations_total
    ps_segment_sync_registrations_total
    ps_segment_sync_pushes_total
Copy link
Contributor Author

@oncilla oncilla left a comment

Choose a reason for hiding this comment

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

Reviewed 67 of 67 files at r1.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved

@oncilla oncilla merged commit 57592d6 into scionproto:master Nov 19, 2020
@oncilla oncilla deleted the pub-os-cs branch November 19, 2020 15:47
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.

1 participant