Skip to content

Add Linux-only native library #80903

@DaveCTurner

Description

@DaveCTurner

As per #80066 we'd like to make the low-level details of our network connections more visible: things like congestion, retransmissions, keepalive timers etc. are aspects of connection health that we need to see to diagnose connectivity problems, but today we rely on folks running netstat or ss from the command line in order to capture this data.

As mentioned in #80066 (comment) on Linux I'd like to use the sock_diag interface to capture this info, but a JNA-based implementation would be ugly and brittle. It'd be much preferable to have a C library that does the work, built against libc so that it has access to all the right constants and macros. I believe Gradle has the facility to build shared libraries written in C, but I don't know exactly how nor do I know how best to package it up so that Elasticsearch could use it.

I'm opening this issue to ask for help. Are there any reasons we definitely shouldn't do such a thing? If not, could someone help me by making a module that includes a library written in C for use only on Linux? I can implement the actual sock_diag interaction myself, it's the supporting infrastructure on which I'm stuck.

Metadata

Metadata

Assignees

No one assigned

    Labels

    :Delivery/PackagingRPM and deb packaging, tar and zip archives, shell and batch scripts>enhancementTeam:DeliveryMeta label for Delivery team

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions