magento / community-features

Magento Features Development is an Initiative to Allows Community Memebers Join to Development of Magento Features
46 stars 18 forks source link

Allow setting returned fields in search_request.xml #178

Open aapokiiso opened 5 years ago

aapokiiso commented 5 years ago

Summary (*)

It's not possible to customize fields returned by search engines (for example Elasticsearch) in search_request.xml.

Examples (*)

In the case of Elasticsearch, Magento\Elasticsearch\SearchAdapter\Query\Builder forces the returned fields to be ['_id', '_score']. This is OK in the case of product search, because you can fetch the remaining data through the product repository using the returned product IDs. But in simpler search cases, it would be nice to return the fields directly from the search index.

Proposed solution

I could provide a PR for this, but is there an explicit reason this is not possible at the moment? Maybe some incompatibility issue between search engines, which prevents this being part of the search_request.xml abstraction?

m2-assistant[bot] commented 5 years ago

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

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-engcom-team give me 2.3-develop instance - upcoming 2.3.x release

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

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


sdzhepa commented 4 years ago

Hello @aapokiiso

Thank you for feedback and your proposal!

Based on the description and label feature request the issue has been transferred to Magento Feature Request public repo.