Table of contents

Manually setting the search popularity of content

To look up the popularity of an item you can query rummager by sshing into rummager-elasticsearch-1.production.

To looking up popularity of a particular item you will need its base_path URL encoded and then look it up with a curl command:

$ curl localhost:9200/government/edition/%2Fgovernment%2Fpublications%2Fdraft-capital-requirements-amendment-eu-exit-regulations-2018?fields=popularity

Once popularity is determined we can then update with the new popularity using the following command:

$ curl -XPOST
localhost:9200/government/edition/%2Fgovernment%2Fpublications%2Fdraft-capital-requirements-amendment-eu-exit-regulations-2018/_update
-d '{"doc": {"popularity": 10}}'
This page was last reviewed . It needs to be reviewed again by the page owner #govuk-developers.