<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">On 1/18/2016 8:25 AM, Stan Silvert
      wrote:<br>
    </div>
    <blockquote cite="mid:569CE7AD.2040509@redhat.com" type="cite">
      <meta content="text/html; charset=ISO-8859-1"
        http-equiv="Content-Type">
      <div class="moz-cite-prefix">On 1/18/2016 3:02 AM, Stian
        Thorgersen wrote:<br>
      </div>
      <blockquote
cite="mid:CAJgngAdnaBozJhdtVDFBoq7=QzNdy=fSazT7HNb8GcG1+_9QrA@mail.gmail.com"
        type="cite">
        <div dir="ltr">Looks good how you've done it.
          <div><br>
          </div>
          <div>Bill is currently working on re-organizing code, but he's
            not going to move anything from services. So can you finish
            up services and send a PR for it? Then you can do the other
            logging once Bill is completed.</div>
        </div>
      </blockquote>
      Assuming nobody has an objection to the proposed format, I'll go
      ahead and finish services.<br>
    </blockquote>
    <br>
    Another thing to consider is DEBUG logging.&nbsp; Do we want to localize
    debug messages?&nbsp; <br>
    <br>
    <br>
    <blockquote cite="mid:569CE7AD.2040509@redhat.com" type="cite"> <br>
      <blockquote
cite="mid:CAJgngAdnaBozJhdtVDFBoq7=QzNdy=fSazT7HNb8GcG1+_9QrA@mail.gmail.com"
        type="cite">
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On 15 January 2016 at 22:12, Stan
            Silvert <span dir="ltr">&lt;<a moz-do-not-send="true"
                href="mailto:ssilvert@redhat.com" target="_blank">ssilvert@redhat.com</a>&gt;</span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF"> I've completed a
                first stab at this using the JBoss logging tools.&nbsp; Once
                merged we will have the ability to do i18n/l10n on our
                log messages and also use message numbers.<br>
                <br>
                Here is the commit to show you how it turns out
                converting the log messages in KeycloakApplication:<br>
                <a moz-do-not-send="true"
href="https://github.com/ssilvert/keycloak/commit/54faba37cb4797fc337569899d8ac8eaa7f0ad1a#diff-72ce0a0a72ebd57f8627c059f7f1ea03R1"
                  target="_blank">https://github.com/ssilvert/keycloak/commit/54faba37cb4797fc337569899d8ac8eaa7f0ad1a#diff-72ce0a0a72ebd57f8627c059f7f1ea03R1</a><br>
                <br>
                So, now a message coming from the KeycloakApplication
                class in the services module looks like this:<br>
                <br>
                15:29:31,515 INFO&nbsp; [<b>org.keycloak.services</b>]
                (ServerService Thread Pool -- 50)<b> KC-SERVICES0001</b>:
                Loading config from
c:\GitHub\keycloak\distribution\server-dist\target\keycloak-1.9.0.CR1-SNAPSHOT\standalone\configuration\keycloak-server.json<br>
                <br>
                We need to decide how we want to structure this.&nbsp; In
                WildFly, we typically have one logger per maven module.&nbsp;
                If you want to have one logger per package then you
                would need to create a new interface in each package,
                which gets hairy.<br>
                <br>
                I do suggest that we prefix all of our messages with
                "KC-" or something else that is unique across products.&nbsp;
                Also, we should standardize the "padding" for the
                message numbers.<br>
                <br>
                Another possibility is to have all keycloak messages
                start with "KEYCLOAK".&nbsp; This would mean that we would
                need for each module to reserve a number range.&nbsp; There
                are annotations to enforce this if we want to go that
                route.&nbsp; The downside is that somewhere we need to
                maintain a registry.&nbsp; I think WildFly did this but
                eventually abandoned it.&nbsp; Notice that WildFly messages
                are like "WFLYUT" for Undertow or "WFLYJSF" for JSF.<br>
                <br>
                BTW, localization works nicely.&nbsp; Just add a bundle for a
                new language.&nbsp; The tool even creates a skeleton
                properties file for you.<br>
                <br>
                If you want more details on the i18n framework, see <a
                  moz-do-not-send="true"
                  href="https://developer.jboss.org/wiki/JBossLoggingTooling"
                  target="_blank">https://developer.jboss.org/wiki/JBossLoggingTooling</a>.<span
                  class="HOEnZb"><font color="#888888"><br>
                    <br>
                    Stan<br>
                  </font></span></div>
              <br>
              _______________________________________________<br>
              keycloak-dev mailing list<br>
              <a moz-do-not-send="true"
                href="mailto:keycloak-dev@lists.jboss.org">keycloak-dev@lists.jboss.org</a><br>
              <a moz-do-not-send="true"
                href="https://lists.jboss.org/mailman/listinfo/keycloak-dev"
                rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-dev</a><br>
            </blockquote>
          </div>
          <br>
        </div>
      </blockquote>
      <br>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
keycloak-dev mailing list
<a class="moz-txt-link-abbreviated" href="mailto:keycloak-dev@lists.jboss.org">keycloak-dev@lists.jboss.org</a>
<a class="moz-txt-link-freetext" href="https://lists.jboss.org/mailman/listinfo/keycloak-dev">https://lists.jboss.org/mailman/listinfo/keycloak-dev</a></pre>
    </blockquote>
    <br>
  </body>
</html>