Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-15693

Reconsider the ImportOrder rule of checkstyle

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.3.0, 1.2.1, 1.0.3, 1.1.4, 0.98.19, 1.4.0, 2.0.0
    • Fix Version/s: 1.3.0, 1.0.4, 1.2.2, 0.98.20, 2.0.0
    • Component/s: build
    • Labels:
    • Hadoop Flags:
      Reviewed

      Description

      I have been confused many times with the wrong import order checkstyle warnings in the pre commit result. And I haven't found any developer guide which tells me what is the right order so this time I decided to read the rule by myself.

      In the ImportOrder section, we declare sortStaticImportsAlphabetically which can only work with option 'top' or 'bottom'(which means place static imports on top or bottom) and use the default option which is 'under'.

      I prefer placing static import on top, so I suggest here we set option to 'top'.

        Attachments

        1. HBASE-15693.patch
          0.9 kB
          Duo Zhang
        2. HBASE-15693-branch-1.3.patch
          4 kB
          Duo Zhang
        3. HBASE-15693-branch-1.2.patch
          4 kB
          Duo Zhang
        4. HBASE-15693-branch-1.1.patch
          4 kB
          Duo Zhang
        5. HBASE-15693-branch-1.0.patch
          4 kB
          Duo Zhang
        6. HBASE-15693-0.98.patch
          4 kB
          Duo Zhang
        7. HBASE-15693-branch-1.patch
          4 kB
          Duo Zhang

          Activity

            People

            • Assignee:
              zhangduo Duo Zhang
              Reporter:
              zhangduo Duo Zhang
            • Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: