pub struct Overlay<'a> { /* private fields */ }Expand description
The repository as it would be after the merge, for the gates: every read sees the merge’s new objects on top of the store, and nothing can be written through it.
The gates (BranchProtectionGate, SignedCommitsGate, AiTrailerGate) read commits
through GitServe::read; running them here is what lets CheckMerge judge a merge
commit that does not exist yet — and the real merge judge it before it is stored.
Implementations§
Trait Implementations§
Source§impl GitOps for Overlay<'_>
impl GitOps for Overlay<'_>
Source§fn put(&self, _pack: &[u8], _refs: &[RefUpdate]) -> Result<TxId>
fn put(&self, _pack: &[u8], _refs: &[RefUpdate]) -> Result<TxId>
One push: pack bytes and ref updates, durable before this returns. Read more
Source§fn has(&self, oid: Oid<'_>) -> Result<bool>
fn has(&self, oid: Oid<'_>) -> Result<bool>
Is this object here? The negotiation call, made a thousand at a time.
Source§fn extents(&self, oids: &[Oid<'_>]) -> Result<Vec<Option<Extent>>>
fn extents(&self, oids: &[Oid<'_>]) -> Result<Vec<Option<Extent>>>
Byte extents, in bulk — the wire path.
Source§fn update_ref(
&self,
_name: &str,
_old: Option<Oid<'_>>,
_new: Option<Oid<'_>>,
) -> Result<TxId>
fn update_ref( &self, _name: &str, _old: Option<Oid<'_>>, _new: Option<Oid<'_>>, ) -> Result<TxId>
Compare-and-swap one ref.
Source§fn put_refs_cas(&self, _edits: &[RefCas<'_>]) -> Result<TxId>
fn put_refs_cas(&self, _edits: &[RefCas<'_>]) -> Result<TxId>
Apply every edit or none. The
git push --atomic primitive. Read moreSource§fn reachable(&self, want: &[Oid<'_>], have: &[Oid<'_>]) -> Result<Vec<Vec<u8>>>
fn reachable(&self, want: &[Oid<'_>], have: &[Oid<'_>]) -> Result<Vec<Vec<u8>>>
want minus have, the object closure a fetch must send.Source§fn put_pack_observed(
&self,
bytes: &[u8],
progress: &dyn PackProgress,
) -> Result<TxId, Error>
fn put_pack_observed( &self, bytes: &[u8], progress: &dyn PackProgress, ) -> Result<TxId, Error>
Source§fn publishes_pack_progress(&self) -> bool
fn publishes_pack_progress(&self) -> bool
Source§impl GitServe for Overlay<'_>
impl GitServe for Overlay<'_>
Source§fn read(&self, oid: Oid<'_>) -> Result<Option<(ObjType, Vec<u8>)>>
fn read(&self, oid: Oid<'_>) -> Result<Option<(ObjType, Vec<u8>)>>
The object, INFLATED and delta-resolved — what
GitOps::get
deliberately is not. Read moreSource§fn header(&self, oid: Oid<'_>) -> Result<Option<(ObjType, u64)>>
fn header(&self, oid: Oid<'_>) -> Result<Option<(ObjType, u64)>>
Kind and post-resolution size without the payload. The type probe. Read more
Source§fn sizes(&self, oids: &[Oid<'_>]) -> Result<Vec<Option<u64>>>
fn sizes(&self, oids: &[Oid<'_>]) -> Result<Vec<Option<u64>>>
Bulk post-resolution size. The negotiation path calls it a thousand at a
time. Read more
Source§fn set_head(&self, _target: &str) -> Result<TxId>
fn set_head(&self, _target: &str) -> Result<TxId>
Point
HEAD. The other half of the pair; point_head_at is the live
consumer.Source§fn emit_pack(
&self,
objects: &[Oid<'_>],
have: &[Oid<'_>],
caps: &Caps,
out: &mut dyn Write,
) -> Result<PackStats>
fn emit_pack( &self, objects: &[Oid<'_>], have: &[Oid<'_>], caps: &Caps, out: &mut dyn Write, ) -> Result<PackStats>
Source§fn select(&self, want: &[Oid<'_>], have: &[Oid<'_>]) -> Result<Option<ReachSet>>
fn select(&self, want: &[Oid<'_>], have: &[Oid<'_>]) -> Result<Option<ReachSet>>
Negotiation:
want minus have, with the two derived facts a caller
cannot recompute cheaply. Read moreAuto Trait Implementations§
impl<'a> !RefUnwindSafe for Overlay<'a>
impl<'a> !UnwindSafe for Overlay<'a>
impl<'a> Freeze for Overlay<'a>
impl<'a> Send for Overlay<'a>
impl<'a> Sync for Overlay<'a>
impl<'a> Unpin for Overlay<'a>
impl<'a> UnsafeUnpin for Overlay<'a>
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> 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