title: How to use span name in logs instead of spanId in spring cloud sleuth?
body: <p>I am using <code>spring-cloud-starter-sleuth 2.0.0 M6</code> and due to breaking changes I cannot use my previous configuration which allows me to see the (human readable) span names in console logs instead of <code>spanId</code>s.</p>
  
  <p>I want to see <code>[app,98ec5c2ab34ea626,span-name,false]</code> instead of <code>[app,98ec5c2ab34ea626,f56b4623ee2e9a3f,false]</code></p>
  
  <p>I used to configure it in <code>2.0.0M1</code> as follows:</p>
  
  <pre><code>class CustomSlf4jSpanLogger implements SpanLogger {
  
  
      @Override
      public void logStartedSpan(Span parent, Span span) {
          MDC.put(Span.SPAN_ID_NAME, span.getName());
          MDC.put(Span.SPAN_NAME_NAME, span.getName());
          MDC.put(Span.SPAN_EXPORT_NAME, String.valueOf(span.isExportable()));
          MDC.put(Span.TRACE_ID_NAME, span.traceIdString());
          log("Starting span: {}", span);
          if (parent != null) {
              log("With parent: {}", parent);
              MDC.put(Span.PARENT_ID_NAME, Span.idToHex(parent.getSpanId()));
          }
      }
  
     // the rest is omitted for brevity
  
  }
  </code></pre>
  
  <p>Now <code>SpanLogger</code> is gone. Closest thing I could find is <a href="https://github.com/spring-cloud/spring-cloud-sleuth/blob/6b3593660f92f80b46d5067dc5a725a2a227142d/spring-cloud-sleuth-core/src/main/java/org/springframework/cloud/sleuth/log/Slf4jCurrentTraceContext.java" rel="nofollow noreferrer">Slf4jCurrentTraceContext</a> however <code>currentSpan</code> which is of type <code>TraceContext</code> has no span name in it.</p>
  
  <p>How can I configure this in <code>2.0.0 M6</code>?</p>