pub struct Permission {
pub action: String,
pub types: Vec<String>,
}Expand description
One action and the types it covers. Types are *, domain.* or a qualified domain.Type,
except where noted. The action * stands for all actions.
- submit: submit commands of these types (CommandService.Submit).
- run: run commands of these types as a worker (Register).
- subscribe: read events of these types with EventService.Subscribe.
- listen: receive events of these types as a listener (Hello.event_types).
- query: ask queries of these types (QueryService.Query).
- answer: answer queries of these types as a read model (Hello.query_types).
- check: check commands and queries of these types as a middleware (Hello.middlewares).
- privileged: set a privileged switch; the type is the switch,
bypass_authorization. - vault_read: get the vault values of these event types in listener batches, and of these command types in middleware checks.
- vault_erase: write events of these types that erase a subject (NewEvent.erases).
- data_read, data_write: get, or put and delete, the files of a domain (
domain.*or*). - cache: use the cache of a domain (
domain.*or*). - manage: apply the membership of these services (service names, or
*). - replicate: follow the kernel as its standby (
*). - read: follow the kernel as a reader, a read-only copy (
*); never as its standby. - grant: sign grants for other keys (a delegated grant, see Grant) for these actions only;
the types are action names, never
*orgrant. Not included in the action*. - export: export the whole kernel (
*, ExportService in export.proto).
Fields§
§action: String§types: Vec<String>Trait Implementations§
Source§impl Clone for Permission
impl Clone for Permission
Source§impl Debug for Permission
impl Debug for Permission
Source§impl Default for Permission
impl Default for Permission
impl Eq for Permission
Source§impl Hash for Permission
impl Hash for Permission
Source§impl Message for Permission
impl Message for Permission
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.Source§impl PartialEq for Permission
impl PartialEq for Permission
impl StructuralPartialEq for Permission
Auto Trait Implementations§
impl Forget for Permission
impl Freeze for Permission
impl Move for Permission
impl RefUnwindSafe for Permission
impl Send for Permission
impl Sync for Permission
impl Unpin for Permission
impl UnsafeUnpin for Permission
impl UnwindSafe for Permission
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
Mutably borrows from an owned value. Read more
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
Compare self to
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request