Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-7590

Finish and improve MDC logging support.

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.3, 6.0
    • Component/s: None
    • Labels:
      None
    1. SOLR-7950.patch
      34 kB
      Mark Miller
    2. SOLR-7950.patch
      111 kB
      Mark Miller
    3. SOLR-7950.patch
      123 kB
      Mark Miller
    4. SOLR-7950.patch
      124 kB
      Mark Miller
    5. SOLR-7950.patch
      129 kB
      Mark Miller
    6. SOLR-7950.patch
      151 kB
      Mark Miller
    7. SOLR-7950.patch
      157 kB
      Mark Miller
    8. SOLR-7950.patch
      158 kB
      Mark Miller
    9. SOLR-7950.patch
      160 kB
      Mark Miller
    10. SOLR-7950.patch
      161 kB
      Mark Miller
    11. SOLR-7950.patch
      161 kB
      Mark Miller

      Issue Links

        Activity

        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        I tried to debug some jenkins logs today and realized a bunch of this logging is incomplete and buggy.

        Show
        markrmiller@gmail.com Mark Miller added a comment - I tried to debug some jenkins logs today and realized a bunch of this logging is incomplete and buggy.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        The Overseer uses MDC logging all wrong IMO. The logging should identify the active core, not the core being operated on by overseer actions.

        Show
        markrmiller@gmail.com Mark Miller added a comment - The Overseer uses MDC logging all wrong IMO. The logging should identify the active core, not the core being operated on by overseer actions.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        Getting closer to something reasonable.

        Show
        markrmiller@gmail.com Mark Miller added a comment - Getting closer to something reasonable.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        I've also unified our context logging solution - we can't maintain one approach for tests and another for production.

        Show
        markrmiller@gmail.com Mark Miller added a comment - I've also unified our context logging solution - we can't maintain one approach for tests and another for production.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        Okay, now it's fairly solid.

        Show
        markrmiller@gmail.com Mark Miller added a comment - Okay, now it's fairly solid.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        I've tweaked the heck out of this to make the logging as nice and complete and universal as I could.

        Show
        markrmiller@gmail.com Mark Miller added a comment - I've tweaked the heck out of this to make the logging as nice and complete and universal as I could.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        The logging should identify the active core, not the core being operated on by overseer actions.

        I think if the Overseer needs better logging around what it's doing, that should be logged specifically. Lot's not overload how we use this context.

        Show
        markrmiller@gmail.com Mark Miller added a comment - The logging should identify the active core, not the core being operated on by overseer actions. I think if the Overseer needs better logging around what it's doing, that should be logged specifically. Lot's not overload how we use this context.
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1682020 from Mark Miller in branch 'dev/trunk'
        [ https://svn.apache.org/r1682020 ]

        SOLR-7590: Finish and improve MDC context logging support.

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1682020 from Mark Miller in branch 'dev/trunk' [ https://svn.apache.org/r1682020 ] SOLR-7590 : Finish and improve MDC context logging support.
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1682031 from Mark Miller in branch 'dev/branches/branch_5x'
        [ https://svn.apache.org/r1682031 ]

        SOLR-7590: Finish and improve MDC context logging support.

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1682031 from Mark Miller in branch 'dev/branches/branch_5x' [ https://svn.apache.org/r1682031 ] SOLR-7590 : Finish and improve MDC context logging support.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        Looks like 5x is failing because the Supplier code is Java 8. Still trying to figure out how this appears to work on my dev machine even when running with a java 7 jvm...

        Show
        markrmiller@gmail.com Mark Miller added a comment - Looks like 5x is failing because the Supplier code is Java 8. Still trying to figure out how this appears to work on my dev machine even when running with a java 7 jvm...
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1682057 from Mark Miller in branch 'dev/branches/branch_5x'
        [ https://svn.apache.org/r1682057 ]

        SOLR-7590: Java8 code -> Java7 for branch_5x.

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1682057 from Mark Miller in branch 'dev/branches/branch_5x' [ https://svn.apache.org/r1682057 ] SOLR-7590 : Java8 code -> Java7 for branch_5x.
        Hide
        markrmiller@gmail.com Mark Miller added a comment -

        Might be some tweaking we still want to do, but we can open up further issues.

        Show
        markrmiller@gmail.com Mark Miller added a comment - Might be some tweaking we still want to do, but we can open up further issues.
        Hide
        thetaphi Uwe Schindler added a comment - - edited

        Hi Mark,

        I am wondering why you be so verbose in Java 8's code. The main reason for ThreadLocal.withInitial() is to use it like that:

        private static final ThreadLocal<Integer> CALL_DEPTH = ThreadLocal.withInitial(() -> 0);
        

        Using a Supplier without a lambda is not the intention behind this method /API
        In Java 7, you can use the code like this fix comitted. If you want it verbose in Java 8, I would also use the Java 7 code...

        Uwe

        Show
        thetaphi Uwe Schindler added a comment - - edited Hi Mark, I am wondering why you be so verbose in Java 8's code. The main reason for ThreadLocal.withInitial() is to use it like that: private static final ThreadLocal< Integer > CALL_DEPTH = ThreadLocal.withInitial(() -> 0); Using a Supplier without a lambda is not the intention behind this method /API In Java 7, you can use the code like this fix comitted. If you want it verbose in Java 8, I would also use the Java 7 code... Uwe
        Hide
        markrmiller@gmail.com Mark Miller added a comment - - edited

        I filed SOLR-7699 so I won't lose this.

        Show
        markrmiller@gmail.com Mark Miller added a comment - - edited I filed SOLR-7699 so I won't lose this.
        Hide
        shalinmangar Shalin Shekhar Mangar added a comment -

        Bulk close for 5.3.0 release

        Show
        shalinmangar Shalin Shekhar Mangar added a comment - Bulk close for 5.3.0 release

          People

          • Assignee:
            markrmiller@gmail.com Mark Miller
            Reporter:
            markrmiller@gmail.com Mark Miller
          • Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development