1
を動作しないようです。ウムラウトのない名前の場合はうまく動作しますが、ウムラウトを含む名前の場合は結果が得られません。検索は、私が埋め込まれたESインスタンスに格納されたオブジェクトを持って春JPA ESで
バグか誤設定ですか?
を動作しないようです。ウムラウトのない名前の場合はうまく動作しますが、ウムラウトを含む名前の場合は結果が得られません。検索は、私が埋め込まれたESインスタンスに格納されたオブジェクトを持って春JPA ESで
バグか誤設定ですか?
はアナライザパラメータと@Field注釈を試してみてください。
@Document(indexName = "lang")
public class Test {
@Id
@Field(type = FieldType.String, index = FieldIndex.no, store = false)
private String id;
@Field(type = FieldType.Nested)
private LanguageValue namecustom;
}
class LanguageValue {
@Field(type = FieldType.String, index = FieldIndex.analyzed, analyzer = "standard", searchAnalyzer = "standard")
private String en;
@Field(type = FieldType.String, index = FieldIndex.analyzed, analyzer = "de_std", searchAnalyzer = "de_std")
private String de;
}
これは、次のマッピングを提供します:
{
"lang": {
"mappings": {
"test": {
"properties": {
"id": {
"type": "string",
"index": "not_analyzed"
},
"namecustom": {
"type": "nested",
"properties": {
"de": {
"type": "string",
"analyzer": "de_std"
},
"en": {
"type": "string",
"analyzer": "standard"
}
}
}
}
}
}
}
}