Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-15971

full query log needs improvement

    XMLWordPrintableJSON

Details

    Description

      When trying out full query logging as a possible integration for nosqlbench usage, I ran across many issues which would make it painful for users. Since there were several, they will be added to a single issue for now. This issue can be broken up if needed.


      FQL doesn't work on my system, even though it says it is logging queries. 

      With the following configuration in cassandra.yaml:

       

      full_query_logging_options:
          log_dir: /REDACTED/fullquerylogs
          roll_cycle: HOURLY
          block: true
          max_queue_weight: 268435456 # 256 MiB
          max_log_size: 17179869184 # 16 GiB
          ## archive command is "/path/to/script.sh %path" where %path is replaced with the file being rolled:
          # archive_command:
          # max_archive_retries: 10
      

      which appears to be the minimal configuration needed to enable fql, only a single file `directory-listing.cq4t` is created, which is a 64K sized file of zeroes.

       


      Calling bin/nodetool enablefullquerylog throws an error initially.

      [jshook@cass4 bin]$ ./nodetool enablefullquerylog

       

      error: sun.nio.ch.FileChannelImpl.map0(int,long,long) 
      -- StackTrace -- 
      java.lang.NoSuchMethodException: sun.nio.ch.FileChannelImpl.map0(int,long,long) 
              at java.base/java.lang.Class.getDeclaredMethod(Class.java:2553) 
              at net.openhft.chronicle.core.OS.lambda$static$0(OS.java:51) 
              at net.openhft.chronicle.core.ClassLocal.computeValue(ClassLocal.java:53)

      (full stack trace attached to this ticket)

       

      Subsequent calls produce normal output:

       

      [jshook@cass4 c4b1]$ bin/nodetool enablefullquerylog 
      nodetool: Already logging to /home/jshook/c4b1/data/fullquerylogs 
      See 'nodetool help' or 'nodetool help <command>'.

       


      nodetool missing getfullquerylog makes it difficult to verify current fullquerylog state without changing it. The conventions for nodetool commands should be followed to avoid confusing users.


      (maybe)

      tools/bin/fqltool help

      should print out help for all fqltool commands rather than simply repeating the default The most commonly used fqltool commands are..


      https://cassandra.apache.org/doc/latest/new/fqllogging.html is malformatted, mixing the appearance of configuration with comments, which is confusing at best.

       

      Attachments

        1. st1.txt
          6 kB
          Jonathan Shook

        Issue Links

          Activity

            People

              polandll Lorina Poland
              jshook Jonathan Shook
              Lorina Poland
              David Capwell, Ekaterina Dimitrova
              Votes:
              1 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: