title: ch.qos.logback.core.util.DynamicClassLoadingException: Failed to instantiate type ch.qos.logback.classic.net.SMTPAppender
body: <p>I have the following <code>logback.xml</code> in my spring-boot application:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8" ?&gt;
  &lt;configuration&gt;
  
      &lt;appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender"&gt;
         ...
      &lt;/appender&gt;
  
      &lt;timestamp key="datetime" datePattern="yy-MM-dd-HH-mm-ss" /&gt;
      &lt;appender name="FILE" class="ch.qos.logback.core.FileAppender"&gt;
          ...
      &lt;/appender&gt;
  
      &lt;appender name="EMAIL" class="ch.qos.logback.classic.net.SMTPAppender"&gt;
          &lt;smtpHost&gt;smtp.gmail.com&lt;/smtpHost&gt;
          &lt;smtpPort&gt;587&lt;/smtpPort&gt;
          &lt;STARTTLS&gt;true&lt;/STARTTLS&gt;
          &lt;username&gt;&lt;/username&gt;
          &lt;password&gt;&lt;/password&gt;
          &lt;to&gt;admin@gmail.com&lt;/to&gt;
          &lt;from&gt;dev@gmail.com&lt;/from&gt;
          &lt;subject&gt;Error&lt;/subject&gt;
          &lt;layout class="ch.qos.logback.classic.html.HTMLLayout"/&gt;
          &lt;asynchronousSending&gt;true&lt;/asynchronousSending&gt;
          &lt;encoder&gt;
              &lt;pattern&gt;
                  %d{dd.MM.yy HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n
              &lt;/pattern&gt;
          &lt;/encoder&gt;
      &lt;/appender&gt;
  
      &lt;root level="INFO"&gt;
          &lt;appender-ref ref="STDOUT" /&gt;
          &lt;appender-ref ref="FILE" /&gt;
          &lt;appender-ref ref="EMAIL" /&gt;
      &lt;/root&gt;
  
  &lt;/configuration&gt;
  </code></pre>
  
  <p>Context is not up with error:</p>
  
  <pre><code>java.lang.IllegalStateException: Logback configuration error detected: 
  ERROR in ch.qos.logback.core.joran.action.AppenderAction - Could not create an Appender of type [ch.qos.logback.classic.net.SMTPAppender]. ch.qos.logback.core.util.DynamicClassLoadingException: Failed to instantiate type ch.qos.logback.classic.net.SMTPAppender
  ERROR in ch.qos.logback.core.joran.spi.Interpreter@22:73 - ActionException in Action for tag [appender] ch.qos.logback.core.joran.spi.ActionException: ch.qos.logback.core.util.DynamicClassLoadingException: Failed to instantiate type ch.qos.logback.classic.net.SMTPAppender
  ERROR in ch.qos.logback.core.joran.action.AppenderRefAction - Could not find an appender named [EMAIL]. Did you define it below instead of above in the configuration file?
  ERROR in ch.qos.logback.core.joran.action.AppenderRefAction - See http://logback.qos.ch/codes.html#appender_order for more details.
  ...
  </code></pre>
  
  <p>What do I wrong?</p>