<PackageReference Include="OpenTelemetry.Exporter.OpenTelemetryProtocol" Version="1.21.0-rc.1" />

OpenTelemetry.PersistentStorage.Abstractions.PersistentBlob

abstract class PersistentBlob
Represents a persistent blob.
protected PersistentBlob()

protected abstract bool OnTryDelete()

protected abstract bool OnTryLease(int leasePeriodMilliseconds)

protected abstract bool OnTryRead(out byte buffer)

protected abstract bool OnTryWrite(byte[] buffer, int leasePeriodMilliseconds = 0)

protected virtual bool OnTryWriteSpan(ReadOnlySpan<byte> buffer, int leasePeriodMilliseconds)

public bool TryDelete()

Attempts to delete the blob.

public bool TryLease(int leasePeriodMilliseconds)

Attempts to acquire lease on the blob.

public bool TryRead(out byte buffer)

Attempts to read the content from the blob.

public bool TryWrite(byte[] buffer, int leasePeriodMilliseconds = 0)

Attempts to write the given content to the blob.

public bool TryWrite(ReadOnlySpan<byte> buffer, int leasePeriodMilliseconds = 0)

Attempts to write the given content to the blob.