pub struct CloudClientTransport { /* private fields */ }Expand description
Posts OpenLineage events to an HTTP endpoint via CloudClient.
Single events go to endpoint; batches go to batch_endpoint (by default the
single endpoint with /batch appended, matching the OpenLineage HTTP API).
Implementations§
Source§impl CloudClientTransport
impl CloudClientTransport
Sourcepub fn new(client: CloudClient, endpoint: Url) -> CloudClientTransport
pub fn new(client: CloudClient, endpoint: Url) -> CloudClientTransport
Use a pre-built CloudClient (e.g. one constructed with cloud
credentials via CloudClient::new_aws / CloudClient::new_databricks).
The batch endpoint defaults to endpoint with /batch appended; the
request timeout defaults to DEFAULT_REQUEST_TIMEOUT. Override either
with Self::with_batch_endpoint / Self::with_timeout.
Sourcepub fn with_token(endpoint: Url, token: impl ToString) -> CloudClientTransport
pub fn with_token(endpoint: Url, token: impl ToString) -> CloudClientTransport
Authenticate with a static bearer token (e.g. OPENLINEAGE_API_KEY).
Sourcepub fn unauthenticated(endpoint: Url) -> CloudClientTransport
pub fn unauthenticated(endpoint: Url) -> CloudClientTransport
No authentication.
Sourcepub fn with_timeout(self, timeout: Duration) -> CloudClientTransport
pub fn with_timeout(self, timeout: Duration) -> CloudClientTransport
Override the per-request timeout (default DEFAULT_REQUEST_TIMEOUT).
Sourcepub fn with_batch_endpoint(self, batch_endpoint: Url) -> CloudClientTransport
pub fn with_batch_endpoint(self, batch_endpoint: Url) -> CloudClientTransport
Override the batch endpoint (default: endpoint with /batch appended).
Trait Implementations§
Source§impl Clone for CloudClientTransport
impl Clone for CloudClientTransport
Source§fn clone(&self) -> CloudClientTransport
fn clone(&self) -> CloudClientTransport
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CloudClientTransport
impl Debug for CloudClientTransport
Source§impl Transport for CloudClientTransport
impl Transport for CloudClientTransport
Source§fn emit<'life0, 'life1, 'async_trait>(
&'life0 self,
event: &'life1 RunEvent,
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
CloudClientTransport: 'async_trait,
fn emit<'life0, 'life1, 'async_trait>(
&'life0 self,
event: &'life1 RunEvent,
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
CloudClientTransport: 'async_trait,
Delivers a single OpenLineage event to the backend. Read more
Source§fn emit_batch<'life0, 'life1, 'async_trait>(
&'life0 self,
events: &'life1 [RunEvent],
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
CloudClientTransport: 'async_trait,
fn emit_batch<'life0, 'life1, 'async_trait>(
&'life0 self,
events: &'life1 [RunEvent],
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
'life1: 'async_trait,
CloudClientTransport: 'async_trait,
Source§fn flush<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
fn flush<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<(), TransportError>> + Send + 'async_trait>>where
'life0: 'async_trait,
Self: 'async_trait,
Flushes any internally-buffered events, blocking until they are delivered
(or fail). Called by
OpenLineageClient::shutdown
after the drain queue empties. The default is a no-op — override it only
for transports that buffer beyond a single emit call. Read moreAuto Trait Implementations§
impl !RefUnwindSafe for CloudClientTransport
impl !UnwindSafe for CloudClientTransport
impl Freeze for CloudClientTransport
impl Send for CloudClientTransport
impl Sync for CloudClientTransport
impl Unpin for CloudClientTransport
impl UnsafeUnpin for CloudClientTransport
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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> 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>
Converts
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>
Converts
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