Mylsm.Bytes.compact: def of mylsm-lsm-store@0.6.0.1 Import: import mylsm-lsm-store@0.6.0.1/mylsm.bend as Mylsm Lines 750-761 of mylsm-lsm-store@0.6.0.1/mylsm.bend: https://jend.leeeet.dev/read.txt?path=mylsm-lsm-store@0.6.0.1/mylsm.bend&start_line=750&end_line=761 import Base import mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend as RawByteDb import mylsm-lsm-store@0.6.0.1/src/coordinator/Client.bend as OwnerClient import mylsm-lsm-store@0.6.0.1/src/coordinator/ByteClient.bend as OwnerByteClient # Publishes a canonical byte snapshot with tombstones removed. def Bytes.compact(handle: Bytes.Handle) -> IO(Bytes.Handle & Result<&1, &1, Bytes.Error, Unit>): match handle: case ByteHandle{raw}: do IO>: pair : RawByteDb.Handle & Result<&1, &1, RawByteDb.Error, Unit> <- RawByteDb.compact(raw) return Bytes.flush.result(pair) case RemoteByteHandle{session}: do IO>: pair : OwnerClient.Session & Result<&1, &1, OwnerClient.Error, Unit> <- OwnerByteClient.compact(session) return Bytes.owner.unit.result(pair) Uses (16): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.pure https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Unit https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/mylsm.bend&name=Bytes.Error https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/mylsm.bend&name=Bytes.Handle https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/mylsm.bend&name=Bytes.flush.result https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/mylsm.bend&name=Bytes.owner.unit.result https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=Error https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=Handle https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=compact https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/coordinator/ByteClient.bend&name=compact https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/coordinator/Client.bend&name=Error https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/coordinator/Client.bend&name=Session