What is the bug?
We allow creation of a search pipeline that uses the personalized intelligent ranking search processor with a weight attribute outside the 0 to 1 bounds. While the pipeline creation succeeds, the search pipeline will eventually throw an IllegalArgumentException since the bounds check occurs when responses are processed by the pipeline.
How can one reproduce the bug?
Request:
PUT /_search/pipeline/intelligent_ranking HTTP/1.1
Host: localhost:9200
Authorization: Basic YWRtaW46YWRtaW4=
User-Agent: curl/7.81.0
Accept: */*
Content-Type: application/json
Content-Length: 464
Connection: close
{
"description": "A pipeline to apply custom reranking",
"response_processors" : [
{
"personalize_ranking" : {
"campaign_arn" : "[redacted]",
"item_id_field" : "",
"recipe" : "aws-personalized-ranking",
"weight" : "20.25",
"iam_role_arn": "[redacted]",
"aws_region": "us-west-2"
}
}
]
}
Response:
HTTP/1.1 200 OK
content-type: application/json; charset=UTF-8
content-length: 21
{"acknowledged":true}
What is the expected behavior?
Validation failure / HTTP 4xx error
Do you have any screenshots?
N/A
Do you have any additional context?
N/A
What is the bug?
We allow creation of a search pipeline that uses the personalized intelligent ranking search processor with a weight attribute outside the 0 to 1 bounds. While the pipeline creation succeeds, the search pipeline will eventually throw an IllegalArgumentException since the bounds check occurs when responses are processed by the pipeline.
How can one reproduce the bug?
Request:
Response:
What is the expected behavior?
Validation failure / HTTP 4xx error
Do you have any screenshots?
N/A
Do you have any additional context?
N/A