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

arp: optimize interface name resolution #3133

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Oct 4, 2024

  1. arp: optimize netlink interface name resolution

    github.com/jsimonetti/rtnetlink provides a high level rtnl wrapper
    around the lower level rtnetlink functions, which essentially does all
    that we need. The rtnl.Conn.Neighbors uses an internal cache for
    resolving interface indexes to names, so it makes at most one rtnetlink
    call per interface to resolve the name.
    
    Using this high level wrapper hugely simplifies our code and makes it
    easier to understand and maintain.
    
    Fixes: prometheus#3075
    
    Signed-off-by: Daniel Swarbrick <daniel.swarbrick@gmail.com>
    dswarbrick committed Oct 4, 2024
    Configuration menu
    Copy the full SHA
    5ad0fdd View commit details
    Browse the repository at this point in the history