Uploaded image for project: 'Ratis'
  1. Ratis
  2. RATIS-2068

Logs with entire StateMachine data is painful to read

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 3.0.0, 3.0.1
    • 3.1.0
    • StateMachine
    • None

    Description

      Today, Ratis sometimes logs entire LogEntry messages with StateMachine data, for example:

      @Override
      public CompletableFuture<AppendEntriesReplyProto> appendEntriesAsync(
          ReferenceCountedObject<AppendEntriesRequestProto> requestRef) throws IOException {
        .....
        } catch(Exception t) {
          LOG.error("{}: Failed appendEntries* {}", getMemberId(), toAppendEntriesRequestString(r), t);
         ....
         } 
      } 

      This makes the logs painful to read for large StateMachine data scenarios. Specifically, in Ozone, StateMachine data is usually 4mb, and we see 4M-letters log lines which are very hard to navigate around. 

      We should either filter StateMachine data when logging or restrict the log message to a certain limit. 

      Attachments

        1. 1074_review.patch
          11 kB
          Tsz-wo Sze

        Issue Links

          Activity

            People

              duongnguyen Duong
              duongnguyen Duong
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 40m
                  40m