From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [IPv6:2a01:7e0:0:424::9]) by lore.proxmox.com (Postfix) with ESMTPS id 839861FF13C for ; Thu, 16 Apr 2026 17:55:05 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 3314DBD97; Thu, 16 Apr 2026 17:55:05 +0200 (CEST) Message-ID: Date: Thu, 16 Apr 2026 17:54:31 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH proxmox-ve-rs 02/16] frr: add support for extcommunity lists To: Stefan Hanreich , pve-devel@lists.proxmox.com References: <20260414163315.419384-1-s.hanreich@proxmox.com> <20260414163315.419384-3-s.hanreich@proxmox.com> Content-Language: en-US From: Hannes Laimer In-Reply-To: <20260414163315.419384-3-s.hanreich@proxmox.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Bm-Milter-Handled: 55990f41-d878-4baa-be0a-ee34c49e34d2 X-Bm-Transport-Timestamp: 1776354792707 X-SPAM-LEVEL: Spam detection results: 0 AWL 0.083 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% DMARC_MISSING 0.1 Missing DMARC policy KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: RJ47XVM75F4LIZJCLL2PNO5WNMDN57QH X-Message-ID-Hash: RJ47XVM75F4LIZJCLL2PNO5WNMDN57QH X-MailFrom: h.laimer@proxmox.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On 2026-04-14 18:33, Stefan Hanreich wrote: > Extended Communities are used for encoding Route Targets in the EVPN > AF, among other things. FRR provides a mechanism to match based on > them via the extcommunity lists. Implement support for creating them, > so they can be used by the SDN stack for matching extended communities > in route maps. Initially, this will be used to filter outgoing routes > in EVPN controllers, but in the future it is planned to expose > creating extcommunity lists via our API / UI as well. > > Signed-off-by: Stefan Hanreich > --- [..] > +impl std::fmt::Display for ExtendedCommunityMatch { > + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { > + let mode = self > + .mode > + .as_ref() > + .map(|mode| format!(" {mode}")) > + .unwrap_or_else(|| String::new()); nit: could use `.unwrap_or_default()` > + > + write!(f, "{}{mode}", self.name) > + } > +} [..]