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

You can't have commas in search term #3776

Closed
karoliskascenas opened this issue Dec 20, 2021 · 3 comments
Closed

You can't have commas in search term #3776

karoliskascenas opened this issue Dec 20, 2021 · 3 comments
Labels
bug Bug report

Comments

@karoliskascenas
Copy link
Contributor

Describe the bug
If you have a comma in your search term you get An unknown error occurred. in the UI.

To Reproduce

  1. Quickstart v0.8.19.
  2. Type something, something in the search bar and hit enter.

Expected behavior
I expect the search to work.

Screenshots
image

Desktop (please complete the following information):

  • OS: mac
  • Browser: Chrome
  • Version: Version 96.0.4664.110 (Official Build) (x86_64)

Additional context
GMS container logs:

07:32:24.033 [ForkJoinPool.commonPool-worker-1] ERROR c.l.m.s.e.query.ESSearchDAO:61 - Search query failed
org.elasticsearch.ElasticsearchStatusException: Elasticsearch exception [type=search_phase_execution_exception, reason=all shards failed]
	at org.elasticsearch.rest.BytesRestResponse.errorFromXContent(BytesRestResponse.java:187)
	at org.elasticsearch.client.RestHighLevelClient.parseEntity(RestHighLevelClient.java:1892)
	at org.elasticsearch.client.RestHighLevelClient.parseResponseException(RestHighLevelClient.java:1869)
	at org.elasticsearch.client.RestHighLevelClient.internalPerformRequest(RestHighLevelClient.java:1626)
	at org.elasticsearch.client.RestHighLevelClient.performRequest(RestHighLevelClient.java:1583)
	at org.elasticsearch.client.RestHighLevelClient.performRequestAndParseEntity(RestHighLevelClient.java:1553)
	at org.elasticsearch.client.RestHighLevelClient.search(RestHighLevelClient.java:1069)
	at com.linkedin.metadata.search.elasticsearch.query.ESSearchDAO.executeAndExtract(ESSearchDAO.java:57)
	at com.linkedin.metadata.search.elasticsearch.query.ESSearchDAO.search(ESSearchDAO.java:89)
	at com.linkedin.metadata.search.elasticsearch.ElasticSearchService.search(ElasticSearchService.java:66)
	at com.linkedin.metadata.search.cache.EntitySearchServiceCache.lambda$getSearcher$0(EntitySearchServiceCache.java:24)
	at com.linkedin.metadata.search.cache.CacheableSearcher.getBatch(CacheableSearcher.java:82)
	at com.linkedin.metadata.search.cache.CacheableSearcher.getSearchResults(CacheableSearcher.java:47)
	at com.linkedin.metadata.search.aggregator.AllEntitiesSearchAggregator.lambda$getSearchResultsForEachEntity$2(AllEntitiesSearchAggregator.java:148)
	at com.linkedin.metadata.utils.ConcurrencyUtils.lambda$null$0(ConcurrencyUtils.java:21)
	at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1604)
	at java.util.concurrent.CompletableFuture$AsyncSupply.exec(CompletableFuture.java:1596)
	at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)
	at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1056)
	at java.util.concurrent.ForkJoinPool.runWorker(ForkJoinPool.java:1692)
	at java.util.concurrent.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:175)
	Suppressed: org.elasticsearch.client.ResponseException: method [POST], host [http://elasticsearch:9200], URI [/corpuserindex_v2/_search?typed_keys=true&max_concurrent_shard_requests=5&ignore_unavailable=false&expand_wildcards=open&allow_no_indices=true&ignore_throttled=true&search_type=query_then_fetch&batched_reduce_size=512&ccs_minimize_roundtrips=true], status line [HTTP/1.1 400 Bad Request]
{"error":{"root_cause":[{"type":"query_shard_exception","reason":"Failed to parse query [[something,  something]]","index_uuid":"DB2XSrTFS32-siTGTAbHaQ","index":"corpuserindex_v2"}],"type":"search_phase_execution_exception","reason":"all shards failed","phase":"query","grouped":true,"failed_shards":[{"shard":0,"index":"corpuserindex_v2","node":"ff0VRcDfTY-Nkot3gazphg","reason":{"type":"query_shard_exception","reason":"Failed to parse query [[something,  something]]","index_uuid":"DB2XSrTFS32-siTGTAbHaQ","index":"corpuserindex_v2","caused_by":{"type":"parse_exception","reason":"Cannot parse '[something,  something]': Encountered \" <RANGE_GOOP> \"something \"\" at line 1, column 13.\nWas expecting:\n    \"TO\" ...\n    ","caused_by":{"type":"parse_exception","reason":"Encountered \" <RANGE_GOOP> \"something \"\" at line 1, column 13.\nWas expecting:\n    \"TO\" ...\n    "}}}}]},"status":400}
		at ```
@karoliskascenas karoliskascenas added the bug Bug report label Dec 20, 2021
@maggiehays
Copy link
Collaborator

Thanks for reporting, @karoliskascenas! We have a smaller team on hand during the holidays, but we'll take a look into this ASAP.

@MikeSchlosser16
Copy link
Contributor

MikeSchlosser16 commented Dec 27, 2021

We also see similar behavior with -. It may or may not be related.

@dexter-mh-lee
Copy link
Contributor

Hi. We have fixed the issue with this PR! #4570 Will be included in next release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug report
Projects
None yet
Development

No branches or pull requests

4 participants