Skip to content

Allow more settings (analyzers) when creating the index #2475

Open
@anton-johansson

Description

@anton-johansson

I'd love to be able to specify more settings on the index. I use custom analyzers, and I can't utilize @Document(createIndex = true), because it tries to create my index without my analyzers, but my mappings reference them.

It would be awesome to see something like this:

@Settings(replicas = 2, shards = 1, analyzers = {
    @Analyzer(name = "html-content", tokenizer = "standard", charFilters = "html_strip"),
    @Analyzer(name = "my-other-analyzer", tokenizer = "standard", charFilters = "some_other_filter"),
})
@Document(indexName = "my-type")
public class MyType
{
    @Field(type = Text, analyzer = "html-content")
    private String body;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions