public long LookupId(string streamName)
        {
            long streamId;

            if (SystemStreams.IsMetastream(streamName))
            {
                streamName = SystemStreams.OriginalStreamOf(streamName);
                streamId   = LookupId(streamName);
                return(_metastreams.MetaStreamOf(streamId));
            }

            if (LogV3SystemStreams.TryGetVirtualStreamId(streamName, out streamId))
            {
                return(streamId);
            }

            return(_wrapped.LookupId(streamName));
        }
Exemple #2
0
        public long LookupId(string streamName)
        {
            long streamId;

            if (SystemStreams.IsMetastream(streamName))
            {
                streamName = SystemStreams.OriginalStreamOf(streamName);
                streamId   = LookupId(streamName);
                return(_metastreams.MetaStreamOf(streamId));
            }

            if (LogV3SystemStreams.TryGetVirtualStreamId(streamName, out streamId))
            {
                return(streamId);
            }

            var result = _wrapped.LookupId(streamName);

            return(result == default
                                ? SystemStreams.IsSystemStream(streamName)
                                        ? LogV3SystemStreams.NoSystemStream
                                        : LogV3SystemStreams.NoUserStream
                                : result);
        }
Exemple #3
0
 TStreamId IReadIndex <TStreamId> .GetStreamId(string streamName)
 {
     return(_streamIds.LookupId(streamName));
 }