pub struct Kurrent {
pub client: Client,
}Fields§
§client: ClientImplementations§
Source§impl Kurrent
impl Kurrent
pub fn new(settings: &ConnectionSettings) -> Result<Self, Error>
pub fn from_env() -> Result<Self, Error>
pub fn stream_builder(&self, stream_id: EventStreamId) -> EventStreamBuilder
pub fn stream_writer(&self, stream_id: EventStreamId) -> EventStreamWriter
pub async fn append_to_stream( &mut self, stream_id: EventStreamId, options: &AppendToStreamOptions, events: Vec<EventData>, ) -> Result<WriteResult, Error>
Trait Implementations§
Source§impl EventStore for Kurrent
impl EventStore for Kurrent
async fn publish<E: Event>( &mut self, stream_id: EventStreamId, events: Vec<E>, expected_version: Option<EventStreamVersion>, ) -> Result<(), Error>
async fn read_stream<E: Event>( &self, stream_id: EventStreamId, ) -> Result<EventStream<E>, Error>
Auto Trait Implementations§
impl !Freeze for Kurrent
impl !RefUnwindSafe for Kurrent
impl Send for Kurrent
impl Sync for Kurrent
impl Unpin for Kurrent
impl !UnwindSafe for Kurrent
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<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