【问题标题】:How disable base64 storing for ingest-attachment elasticsearch plugin?如何为摄取附件弹性搜索插件禁用 base64 存储?
【发布时间】:2018-03-09 23:36:15
【问题描述】:
documentation 展示了如何通过摄取附件插件将 base64 文档存储到弹性搜索中的示例。但在此之后,我得到了弹性搜索索引包含解析的文本和 base64 字段源。为什么需要它?有没有办法删除 base64 文本字段并在文档被索引后只保留文本而不是内容?
【问题讨论】:
标签:
elasticsearch
indexing
full-text-search
full-text-indexing
data-ingestion
【解决方案1】:
没有选择,但您可以将“删除”处理器添加到您的摄取管道:
PUT _ingest/pipeline/attachment
{
"description": "Extract attachment information and remove the source encoded data",
"processors": [
{
"attachment": {
"field": "data",
"properties": [
"content",
"content_type",
"content_length"
]
}
},
{
"remove": {
"field": "data"
}
}
]
}