File tree Expand file tree Collapse file tree
background/tasks/multicast Expand file tree Collapse file tree Original file line number Diff line number Diff line change 55//! Mock / dummy versions of the OPTE module, for non-illumos platforms.
66//!
77//! Most methods are either `unimplemented!()` or silent no-ops.
8- //! Multicast subscribe/unsubscribe is an exception,as it maintains real
8+ //! Multicast subscribe/unsubscribe is an exception, as it maintains real
99//! in-memory state because port manager tests assert on subscription contents.
1010
1111use crate :: addrobj:: AddrObject ;
Original file line number Diff line number Diff line change @@ -1334,13 +1334,13 @@ impl MulticastGroupReconciler {
13341334 return Ok ( None ) ;
13351335 }
13361336 Err ( e) => {
1337- debug ! (
1337+ warn ! (
13381338 opctx. log,
13391339 "failed to look up instance state" ;
13401340 "member" => ?member,
13411341 "error" => ?e
13421342 ) ;
1343- return Ok ( None ) ;
1343+ return Err ( e . into ( ) ) ;
13441344 }
13451345 } ;
13461346
Original file line number Diff line number Diff line change 105105//! - **Group lifecycle**: "Creating" → "Active" → "Deleting" → hard-deleted
106106//! - **Member lifecycle**: "Joining" → "Joined" → "Left" → soft-deleted → hard-deleted
107107//! - **Dataplane updates**: DPD API calls for P4 table updates
108+ //! - **Sled propagation**: M2P mappings and forwarding entries pushed to sled-agents
109+ //! - **OPTE subscriptions**: Per-VMM multicast group subscriptions on target sleds
108110//! - **Topology mapping**: Sled-to-switch-port resolution (with caching)
109111//!
110112//! ## Deletion Semantics: Groups vs Members
Original file line number Diff line number Diff line change @@ -118,12 +118,22 @@ impl MulticastSledClient {
118118 cached_propolis_id : Option < PropolisUuid > ,
119119 ) -> Result < ( ) , anyhow:: Error > {
120120 let instance_id = InstanceUuid :: from_untyped_uuid ( member. parent_id ) ;
121+ // If the instance has no propolis_id (already stopped/destroyed),
122+ // the OPTE port is gone and there's nothing to subscribe.
121123 let propolis_id = match cached_propolis_id {
122124 Some ( id) => id,
123- None => self
124- . lookup_propolis_id ( opctx, instance_id)
125- . await ?
126- . context ( "instance has no propolis_id, cannot subscribe" ) ?,
125+ None => match self . lookup_propolis_id ( opctx, instance_id) . await ? {
126+ Some ( id) => id,
127+ None => {
128+ debug ! (
129+ opctx. log,
130+ "no propolis_id for instance, skipping subscribe" ;
131+ "member_id" => %member. id,
132+ "instance_id" => %instance_id
133+ ) ;
134+ return Ok ( ( ) ) ;
135+ }
136+ } ,
127137 } ;
128138
129139 let client = self
You can’t perform that action at this time.
0 commit comments