title: Elasticsearch 5.1 Java API Highlighting
body: <p>Could you please provide an example of how to highlight queries in all fields using Elasticsearch 5.1 Java API?</p>
  <pre><code>    HighlightBuilder highlightBuilder = new HighlightBuilder()
              .postTags(&quot;&lt;highlight&gt;&quot;)
              .preTags(&quot;&lt;/highlight&gt;&quot;)
              .highlightQuery(QueryBuilders.queryStringQuery( &quot;ferrari&quot;));
  
  
      SearchRequestBuilder request = client.prepareSearch(&quot;notemates&quot;)
              .setTypes(&quot;cars&quot;)
              .setQuery(QueryBuilders.queryStringQuery( &quot;ferrari&quot;))
              .setSearchType(SearchType.DEFAULT)
              .highlighter(highlightBuilder);
      SearchResponse response = request.get();
  </code></pre>
  <p>Is something wrong?</p>
  <p>Many thanks.</p>