Uploaded image for project: 'Log Tool'
  1. Log Tool
  2. LOGTOOL-12

Generated classes should be using a different logger method

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 1.0.0.Beta6
    • Labels:
      None

      Description

      Right now the generated classes are using the errorf/warnf/etc. methods. However using these methods causes an incorrectly-reported source file name/line number/class name/method name in logs which use these formats.

      Instead, the logf and logv methods should be used. Specifically, this form:

         logger.logf(FQCN, Level.INFO, cause, format, param1, param2, ...);
      

      The FCQN should be a "private static final String" field defined in each logger class and initialized to "LoggerClassName.class.getName()". Be sure to import the org.jboss.logging.Logger.Level class either directly or use it via Logger.

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                jamezp James Perkins
                Reporter:
                dmlloyd David Lloyd
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: