mirror of
https://github.com/simon987/sist2.git
synced 2025-04-19 18:26:43 +00:00
(breaking) Set item depth in ingest pipeline
This commit is contained in:
parent
d78994d427
commit
e5bb4856d2
@ -7,9 +7,9 @@
|
|||||||
"path": {
|
"path": {
|
||||||
"type": "text",
|
"type": "text",
|
||||||
"analyzer": "path_analyzer",
|
"analyzer": "path_analyzer",
|
||||||
"copy_to": "suggest-path"
|
"copy_to": "suggest_path"
|
||||||
},
|
},
|
||||||
"suggest-path": {
|
"suggest_path": {
|
||||||
"type": "completion",
|
"type": "completion",
|
||||||
"analyzer": "case_insensitive_kw_analyzer"
|
"analyzer": "case_insensitive_kw_analyzer"
|
||||||
},
|
},
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
{
|
{
|
||||||
"description": "Copy _id to _tie",
|
"description": "Copy _id to _tie, save path depth",
|
||||||
"processors": [
|
"processors": [
|
||||||
{
|
{
|
||||||
"script": {
|
"script": {
|
||||||
"source": "ctx._tie = ctx._id;"
|
"source": "ctx._tie = ctx._id; ctx._depth = ctx.path.length() - ctx.path.replace(\"/\", \"\").length();"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -520,7 +520,7 @@ function getPathChoices() {
|
|||||||
path: {
|
path: {
|
||||||
prefix: pathBar.value,
|
prefix: pathBar.value,
|
||||||
completion: {
|
completion: {
|
||||||
field: "suggest-path",
|
field: "suggest_path",
|
||||||
skip_duplicates: true,
|
skip_duplicates: true,
|
||||||
size: 10000
|
size: 10000
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user