Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-10092

Remove unnecessary enum modifier in NioEchoServer

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Trivial
    • Resolution: Fixed
    • None
    • 2.8.0
    • None

    Description

      n.b. This is a newbie ticket designed to be an introduction to contributing for the assignee.

      In NioEchoServer the enum has its constructor declared as private, which is redundant. We can remove this.

      public class NioEchoServer extends Thread {
          public enum MetricType {
              TOTAL, RATE, AVG, MAX;
      
              private final String metricNameSuffix;
      
              private MetricType() {
                  metricNameSuffix = "-" + name().toLowerCase(Locale.ROOT);
              }}} 

      Attachments

        Activity

          People

            Ma3oxuct Andrey Falko
            jghoman Jakob Homan
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: