Magento2: No results on other than first search pages when using elasticsearch

Created on 30 Oct 2019  路  13Comments  路  Source: magento/magento2

Preconditions (*)

  1. Magento 2.3.3 CE & EE, 2.3-develop
  2. Elastic Search 6

Steps to reproduce (*)

  1. Let's assume that our page limit is configured to 10.
  2. Search products using some phrase where you're sure that there are more results than the configured limit on a page which is 10.

Expected result (*)

  1. Expect that will have results on each page rendered in the pagination.
  2. No limit and offset will be applied when using elastic search.

Actual result (*)

  1. On the bottom of the search, results pagination will be rendered, but if you will click on the second, third, etc page no results message will be displayed.
  2. Select query to database contains "LIMIT 10 OFFSET 10" part, elastic search applies condition with particular entity ids, as result there will be always only 10 results, due to limit and offset query has no results. Preview of the mentioned part of the query for:
    (e.entity_id IN (8357, 3524, 18671, 8360, 8390, 3971, 11213, 3527, 8387, 11393)) ORDER BY FIELD(e.entity_id,8357,3524,18671,8360,8390,3971,11213,3527,8387,11393) ASC LIMIT 10 OFFSET 10.
Elasticsearch Clear Description Confirmed Format is valid Ready for Work Reproduced on 2.3.x

Most helpful comment

There is already PR.

All 13 comments

Hi @pierzakp. Thank you for your report.
To help us process this issue please make sure that you provided the following information:

  • [x] Summary of the issue
  • [x] Information on your environment
  • [x] Steps to reproduce
  • [x] Expected and actual results

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento give me 2.3-develop instance - upcoming 2.3.x release

For more details, please, review the Magento Contributor Assistant documentation.

@pierzakp do you confirm that you were able to reproduce the issue on vanilla Magento instance following steps to reproduce?

  • [x] yes
  • [ ] no

Hi @engcom-Charlie. Thank you for working on this issue.
In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

  • [x] 1. Verify that issue has all the required information. (Preconditions, Steps to reproduce, Expected result, Actual result).
    DetailsIf the issue has a valid description, the label Issue: Format is valid will be added to the issue automatically. Please, edit issue description if needed, until label Issue: Format is valid appears.
  • [x] 2. Verify that issue has a meaningful description and provides enough information to reproduce the issue. If the report is valid, add Issue: Clear Description label to the issue by yourself.

  • [x] 3. Add Component: XXXXX label(s) to the ticket, indicating the components it may be related to.

  • [ ] 4. Verify that the issue is reproducible on 2.3-develop branch

    Details- Add the comment @magento give me 2.3-develop instance to deploy test instance on Magento infrastructure.
    - If the issue is reproducible on 2.3-develop branch, please, add the label Reproduced on 2.3.x.
    - If the issue is not reproducible, add your comment that issue is not reproducible and close the issue and _stop verification process here_!

  • [ ] 5. Add label Issue: Confirmed once verification is complete.

  • [ ] 6. Make sure that automatic system confirms that report has been added to the backlog.

:white_check_mark: Confirmed by @engcom-Charlie
Thank you for verifying the issue. Based on the provided information internal tickets MC-22616 were created

Issue Available: @engcom-Charlie, _You will be automatically unassigned. Contributors/Maintainers can claim this issue to continue. To reclaim and continue work, reassign the ticket to yourself._

There is already PR.

Hello @pierzakp

We are not able to reproduce this issue on the latest 2.3-develop branch now(fixed).
Unfortunately i have to close it.

Thank you for contribution and collaboration!

For those of us still experiencing this issue after upgrading to 2.3.3 has anybody got a fix that works. The specific changes in the PR made no difference - or do we need to wait for 2.3.4 ?

I too still have this problem after applying patch to 2.3.3. Any additional fixes?

@kunzi - don't think this will be fixed this decade...

@gaiterjones As a workaround I installed Amasty's Improved Layered Navigation extension and that fixed this issue.

@kunzi - do you mean Search or Layered Navigation? Not sure why the Amasty layered navigation extension would this fix elastic search problem? I expect 2.3.4 will be released soon will wait and see if the problem gets fixed then...

@gaiterjones I have no idea why, but after enabling the Amasty's extension all the pagination problems we had disappeared. If I remember correctly we had this pagination problem on category pages and on search result page.

Turns out another extension was not compatible with Elastic Search 6 in 2.3.3 and created exactly the same pagination issue as described here. Moral of the story is always check your modules for incompatibility first...

I have a customer now on M2.3.5-p1 and they are now having this issue. Can I still use the 2.3.3 patch for M.2.3.5-p1 ??

Was this page helpful?
0 / 5 - 0 ratings