Reputation: 1185
In elastic search 2 , I configured string property like below
@Field(type = FieldType.String, analyzer = "synonym_analyzer")
private String transformedTitle ;
After upgrading to elastic search 5 and spring data elastic search 3.0.0.RC2 , I observe that FieldType.String is no longer available .
Should I use FiledType.Auto ?
Upvotes: 0
Views: 741
Reputation: 26
The string
field datatype has been replaced by the text
field for full text analyzed content, and the keyword
field for not-analyzed exact string values, during the 5.x series.
You should be useing FieldType.text
or FieldType.keyword
Upvotes: 1
Reputation: 217254
As of ES 5, you should be using FieldType.text
:
@Field(type = FieldType.text, analyzer = "synonym_analyzer")
private String transformedTitle ;
Upvotes: 1