public async Task <long> ReadHeadPosition(CancellationToken cancellationToken = new CancellationToken()) { var span = _spanSource.Begin("stream-store." + nameof(ReadHeadPosition), ServiceName, "head", TypeName); try { return(await _streamStore.ReadHeadPosition(cancellationToken)); } catch (Exception ex) { span?.SetError(ex); throw; } finally { span?.Dispose(); } }
public async Task <long> ReadHeadPosition(CancellationToken cancellationToken = new CancellationToken()) => await Trace( nameof(ReadHeadPosition), "head", () => _streamStore.ReadHeadPosition(cancellationToken));