pub enum ConnectorIntent {
AllIngress,
Egress,
}Expand description
The Lambda-managed connectors this client will name, and no others.
Named for the intent rather than for the wire value, because the intent is what a
caller has: “let the proxy reach the VM” and “let the VM reach the internet”. The
wire spellings (ConnectorIntent::wire_name) are an implementation detail of the
ARN.
Variants§
AllIngress
Lets the endpoint proxy reach the VM. Required for any session to work.
Egress
Lets the VM reach the internet.
Omitted by default, which is how you get a VM with no outbound network — the right default for a daemon that needs none.
Implementations§
Source§impl ConnectorIntent
impl ConnectorIntent
Sourcepub const ALL: [ConnectorIntent; 2]
pub const ALL: [ConnectorIntent; 2]
Both intents, so a test can enumerate the complete set.
The TRAP-11 assertion reads this: a SHELL_INGRESS variant added later would
appear here and fail the test that pins the set to two.
Sourcepub fn wire_name(self) -> &'static str
pub fn wire_name(self) -> &'static str
The connector’s name as the ARN spells it.
INTERNET_EGRESS rather than EGRESS: the wire name is not the intent’s name,
which is the second reason this is a table rather than a Display derive.
Sourcepub fn arn(self, region: &Region) -> String
pub fn arn(self, region: &Region) -> String
The fully-qualified ARN for this connector in region.
One interpolation for both directions. The Python client’s earlier shape derived
the egress ARN by string-replacing ALL_INGRESS inside the ingress one, which
produced a valid ARN only as long as the two names never became substrings of
each other (sandbox.py:391-398).
The doubled aws-network-connector segment is not a typo: the resource type and
the resource name are both present, and the format is copied from
sandbox.py:398 rather than reconstructed from the ARN grammar.
Trait Implementations§
Source§impl Clone for ConnectorIntent
impl Clone for ConnectorIntent
Source§fn clone(&self) -> ConnectorIntent
fn clone(&self) -> ConnectorIntent
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for ConnectorIntent
Source§impl Debug for ConnectorIntent
impl Debug for ConnectorIntent
impl Eq for ConnectorIntent
Source§impl Hash for ConnectorIntent
impl Hash for ConnectorIntent
Source§impl PartialEq for ConnectorIntent
impl PartialEq for ConnectorIntent
impl StructuralPartialEq for ConnectorIntent
Auto Trait Implementations§
impl Freeze for ConnectorIntent
impl RefUnwindSafe for ConnectorIntent
impl Send for ConnectorIntent
impl Sync for ConnectorIntent
impl Unpin for ConnectorIntent
impl UnsafeUnpin for ConnectorIntent
impl UnwindSafe for ConnectorIntent
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more