private string EncodeTraceId(TraceId traceId) { var id = traceId.ToLowerBase16(); if (id.Length > 16 && this.options.UseShortTraceIds) { id = id.Substring(id.Length - 16, 16); } return(id); }
public void ToLowerBase16() { Assert.Equal("00000000000000000000000000000000", TraceId.Invalid.ToLowerBase16()); Assert.Equal("00000000000000000000000000000061", first.ToLowerBase16()); Assert.Equal("ff000000000000000000000000000041", second.ToLowerBase16()); }