Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More Like This Query documentation - remove reference to "ids" and "like_text" parameter #28128

Closed
markharwood opened this issue Jan 8, 2018 · 4 comments
Assignees
Labels
>docs General docs changes :Search/Search Search-related issues that do not fall into other categories v6.0.0

Comments

@markharwood
Copy link
Contributor

A user on the discuss forums reported that MLT had deprecated ids and like_text params but not removed them from the docs following their removal from the codebase.
I tried these params in 6.0 and it does look like docs diverge from code at this point.

The API now only takes a single like parameter which either accepts a string (the equivalent behaviour of the old like_text) or an array of objects with index, type and id settings to identify individual docs (the equivalent of the old ids setting). Valid examples below:

GET kaleida/article/_search
{
  "query": {
	"more_like_this": {
	  "fields": [
		"headline"
	  ],
	  "like": [
		{
		  "_index": "kaleida",
		  "_type": "article",
		  "_id": "szeNvGABw9SxSpuUzKMH"
		}
	  ]
	}
  }
} 

GET kaleida/article/_search
{
  "query": {
	"more_like_this": {
	  "fields": [
		"headline"
	  ],
	  "like": "trump says trump is stable genius"
	}
  }
}

The docs however still talk about explicit ids and like_text params which are no longer supported.

@markharwood markharwood added >bug >docs General docs changes v6.0.0 labels Jan 8, 2018
@colings86 colings86 added :Search/Search Search-related issues that do not fall into other categories and removed >bug labels Apr 24, 2018
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search-aggs

@Sue-Gallagher Sue-Gallagher self-assigned this Jun 6, 2018
@Sue-Gallagher
Copy link
Contributor

Sue-Gallagher commented Jun 12, 2018

The documentation currently is:
ids or docs::
A list of documents following the same syntax as the <<docs-multi-get,Multi GET API>>.

Do I just remove "id" and leave "docs" and the definition, or does the whole thing go away?

@pcsanwald
Copy link
Contributor

pcsanwald commented Jun 15, 2018

@Sue-Gallagher both "id" and "docs", and also "like_text", should go away as parameters, they were removed in 6.x here's the breaking changes for 6.0. here's the relevant piece:

The deprecated like_text, ids and docs parameters (all synonyms for like) of the more_like_this query have been removed. Also the deprecated min_word_len (a synonym for min_word_length) and max_word_len (a synonym for max_word_length) have been removed.

@Sue-Gallagher
Copy link
Contributor

@pcsanwald
Thanks!

Sue-Gallagher added a commit to Sue-Gallagher/elasticsearch that referenced this issue Jun 15, 2018
dnhatn added a commit that referenced this issue Jun 20, 2018
* master:
  [DOCS] Omit shard failures assertion for incompatible responses  (#31430)
  [DOCS] Move licensing APIs to docs (#31445)
  Add Delete Snapshot High Level REST API
  Remove QueryCachingPolicy#ALWAYS_CACHE (#31451)
  [Docs] Extend Homebrew installation instructions (#28902)
  Choose JVM options ergonomically
  [Docs] Mention ip_range datatypes on ip type page (#31416)
  Multiplexing token filter (#31208)
  Fix use of time zone in date_histogram rewrite (#31407)
  Core: Remove index name resolver from base TransportAction (#31002)
  [DOCS] Fixes code snippet testing for machine learning (#31189)
  [DOCS] Removed  and  params from MLT. Closes #28128 (#31370)
  Security: fix joining cluster with production license (#31341)
  Unify http channels and exception handling (#31379)
  [DOCS] Moves the info API to docs (#31121)
  Preserve response headers on cluster update task (#31421)
  [DOCS] Add code snippet testing for more ML APIs (#31404)
  Do not preallocate bytes for channel buffer (#31400)
  Docs: Advice for reindexing many indices (#31279)
  Mute HttpExporterTests#testHttpExporterShutdown test Tracked by #31433
  Docs: Add note about removing prepareExecute from the java client (#31401)
  Make release notes ignore the `>test-failure` label. (#31309)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>docs General docs changes :Search/Search Search-related issues that do not fall into other categories v6.0.0
Projects
None yet
Development

No branches or pull requests

5 participants