Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-6463

Changing log levels for DS component getState and registration

    XMLWordPrintableJSON

Details

    Description

      As a developer (having the debugger hat), I need to find the most standard problems most easily. Currently, DS services are logging hundreds and thousands of lines on startup into DEBUG but nearly nothing into INFO.

      So, in my opinion, Felix should reconsider the log levels of all its DS bundle startup loglines. The two most important ones (in my opinion) are argued below:

      Beginning with AbstractComponentManager::getState. The "Querying state" log should be in level TRACE, as that very state is written six times for every state change 3xActivateInteral: (2x inside getState and then again in the "Activating" line itself) and analogous 3x for the real state change.

      Here, all four of these "Querying state" lines are superfluous and only necessary, if I search for deep felix implementation bugs.

      Reference: https://github.com/apache/felix-dev/blob/3e5671ae7e5107f4f849ef9d5f0a89b1ba9d7439/scr/src/main/java/org/apache/felix/scr/impl/manager/AbstractComponentManager.java#L1427

      Additionally, the registation changes of a component should be logged into INFO, instead of DEBUG. Then, I do not need to activate DEBUG for my DS based bundles in the first place (at least for most of my debugging efforts).

      https://github.com/apache/felix-dev/blob/3e5671ae7e5107f4f849ef9d5f0a89b1ba9d7439/scr/src/main/java/org/apache/felix/scr/impl/manager/RegistrationManager.java#L119

       

      The two minor changes will improve the debugging experience alot and will reduce its needed time significantly. I will be glad to create a pull request if this issue is approved.

      Attachments

        Issue Links

          Activity

            People

              cziegeler Carsten Ziegeler
              HeikoStudt Heiko Studt
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: