Skip to content

Remove serde flatten for bgp parameters in external API #635

@rcgoodfellow

Description

@rcgoodfellow

Per this comment

#584 (comment)

This causes all of these fields to be duplicated in the progenitor client, which leads to some kinda painful duplication (e.g., https://github.com/oxidecomputer/omicron/blob/8186a1d914d4297136eb0892a3881a38dc9fc68b/sled-agent/src/bootstrap/early_networking.rs#L570-L605 and https://github.com/oxidecomputer/omicron/blob/8186a1d914d4297136eb0892a3881a38dc9fc68b/sled-agent/src/bootstrap/early_networking.rs#L617-L654).

maghemite/bgp/src/params.rs

Lines 156 to 165 in 715eed9

/// Neighbor configuration with explicit per-address-family enablement (v3 API)
#[derive(Debug, Deserialize, Serialize, JsonSchema, Clone, PartialEq)]
pub struct Neighbor {
pub asn: u32,
pub name: String,
pub group: String,
pub host: SocketAddr,
#[serde(flatten)]
pub parameters: BgpPeerParameters,
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    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