i got this elasticsearch instance, and im trying to implement something like a "dynamic" searchtemplate.
Case: I got a userinterface where we can adjust the boosting of certain types. ex. "Boost hits in Articles by 10", "Boost hits on the product page by 20"
Today: I can write up the query itself using fluent DSL, which would be generated everytime someone searches.
Future: I would love to have this in a searchtemplate that would just get updated everytime a change is made, thereby just passing in the template name and a query string - instead of having to look up the current boosting values on every request.
My research: So the nest client supports adding searchtemplates to the ES instance, but it seems like it only supports "inline" scripts and i cant seem to find a way to parse my existing query written in "Fluent DSL" to the JSON equivalent.
Fallback idea: Writing the script manually using json \ query DSL.
Any ideas \ solutions out there? :)