title: Elasticsearch ShieldPlugin ClassNotFoundException
body: <p>I'm trying to use shield plugin with elasticsearch while creating a es client in spring. I have added the following dependency to my pom.xml</p>
  
  <pre><code>&lt;dependency&gt;
  &lt;groupId&gt;org.elasticsearch.plugin&lt;/groupId&gt;
  &lt;artifactId&gt;shield&lt;/artifactId&gt;
  &lt;version&gt;2.4.0&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>I'm creating the bean in the below fashion:</p>
  
  <pre><code>@Override
  protected TransportClient createInstance() throws Exception
  {
      TransportClient client = null;
      String userpass = this.username+":"+this.password;
      client = TransportClient.builder()
      .addPlugin(ShieldPlugin.class)
      .settings(Settings.builder()
          .put("shield.user", userpass)
          .build()).build()
      .addTransportAddress(toAddress());
      return client;
  }
  </code></pre>
  
  <p>But when the bean is created it gets the following error.</p>
  
  <pre><code>java.lang.ClassNotFoundException: org.elasticsearch.shield.ShieldPlugin
      at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1333)
      at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1167)
      ... 116 more
  </code></pre>
  
  <p>Any help on this is appreciated.</p>
  
  <p>Thanks in advance.</p>