# Java DSL

**URL:** <https://discuss.elastic.co/t/java-dsl/5317>\
**Category:** Elasticsearch\
**Created:** [September 6, 2011, 5:20pm UTC](https://discuss.elastic.co/t/java-dsl/5317 "2011-09-06T17:20:12Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![nchandra](https://avatars.discourse-cdn.com/v4/letter/n/bb73d2/32.png) [@nchandra](https://discuss.elastic.co/u/nchandra)\
**Post date:** [September 6, 2011, 5:20pm UTC](https://discuss.elastic.co/t/java-dsl/5317/1 "2011-09-06T17:20:12Z")

</div>

Some questions related to different topics in ES:

How can I define mappings for a type using Java API e.g. twitter?

Is there a way to see how a user supplied phrase is analyzed which  
will be useful for debugging? e.g. if the analyzer is custom, keyword  
tokenizer and edgeNGram filter, can I supply a query and inspect the  
generated terms?

Lucene has EnglishMinimalStemFilterFactory filter. Is this available  
in ES?

Thanks,  
Nishant

---

<div class="post-metadata">

**Author:** ![Lukas\_Vlcek1](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lukas_vlcek1/32/819_2.png) [@Lukas\_Vlcek1](https://discuss.elastic.co/u/Lukas_Vlcek1)\
**Post date:** [September 6, 2011, 7:50pm UTC](https://discuss.elastic.co/t/java-dsl/5317/2 "2011-09-06T19:50:32Z")

</div>

Hi,

answers inlined

On Tue, Sep 6, 2011 at 7:20 PM, nchandra [nishant.chandra@gmail.com](mailto:nishant.chandra@gmail.com) wrote:

> Some questions related to different topics in ES:
> 
> How can I define mappings for a type using Java API e.g. twitter?

It is available via client.admin.indices  
Check AnalyzeActionTests.java or ScriptFieldSearchTests.java for some  
examples. Generally, you can check usages of  
IndicesAdminClient.java#putMapping  
or IndicesAdminClient.java#preparePutMapping in elasticsearch source code.

> Is there a way to see how a user supplied phrase is analyzed which  
> will be useful for debugging? e.g. if the analyzer is custom, keyword  
> tokenizer and edgeNGram filter, can I supply a query and inspect the  
> generated terms?

Yes, Analyze API:

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> Lucene has EnglishMinimalStemFilterFactory filter. Is this available  
> in ES?

Yes, EnglishMinimalStemFilter is exposed. Check minimal\_english here:

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> Thanks,  
> Nishant

Regards,  
Lukas

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 3:55am UTC](https://discuss.elastic.co/t/java-dsl/5317/3 "2017-07-06T03:55:06Z")

</div>


