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

Add multi search #430

Merged
merged 2 commits into from Mar 30, 2023
Merged

Add multi search #430

merged 2 commits into from Mar 30, 2023

Conversation

brunoocasali
Copy link
Member

Add a module containing the multi_search method.

@brunoocasali brunoocasali added the enhancement New feature or request label Mar 30, 2023
Comment on lines +10 to +13
response = client.multi_search([
{ index_uid: 'books', q: 'prince' },
{ index_uid: 'movies', q: 'prince' }
])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we not add { queries: [...] } since we might have other parameters in the future?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, but in this case, we can assume this is the most important argument, and the others can be named. Like we did to q in the search.

@brunoocasali brunoocasali merged commit b143172 into bump-meilisearch-v1.1.0 Mar 30, 2023
2 of 5 checks passed
@brunoocasali brunoocasali deleted the add-multi-search branch March 30, 2023 15:55
meili-bors bot added a commit that referenced this pull request Apr 3, 2023
432: Update version for the next release (v0.23.0) r=bidoubiwa a=meili-bot

This version introduces features released on Meilisearch v1.1.0 🎉
Check out the changelog of [Meilisearch v1.1.0](https://github.com/meilisearch/meilisearch/releases/tag/v1.1.0) for more information on the changes.

### 🚀 Enhancements

- Add a new optional argument to `add_documents_csv`. This argument allows you to customize the separator character in your `csv` file. (#429) `@brunoocasali.`
- Add `client.multi_search()` method to execute multiple search requests simultaneously with different configurations. (#430) `@brunoocasali`
    Usage example:

    ```ruby
    client.multi_search([
      { index_uid: 'books', q: 'prince' },
      { index_uid: 'movies', q: 'prince' },
    ])
    ```
  ⚠️ The `SearchQuery` was not meant to be used if the regular `$index->search()` requests (yet).

Co-authored-by: meili-bot <74670311+meili-bot@users.noreply.github.com>
meili-bors bot added a commit that referenced this pull request Apr 3, 2023
425: Changes related to the next Meilisearch release (v1.1.0) r=curquiza a=meili-bot

Related to this issue: meilisearch/integration-guides#251

This PR:
- gathers the changes related to the next Meilisearch release (v1.1.0) so that this package is ready when the official release is out.
- should pass the tests against the [latest pre-release of Meilisearch](https://github.com/meilisearch/meilisearch/releases).
- might eventually contain test failures until the Meilisearch v1.1.0 is out.

⚠️ This PR should NOT be merged until the next release of Meilisearch (v1.1.0) is out.

_This PR is auto-generated for the [pre-release week](https://github.com/meilisearch/integration-guides/blob/main/resources/pre-release-week.md) purpose._


432: Update version for the next release (v0.23.0) r=curquiza a=meili-bot

This version introduces features released on Meilisearch v1.1.0 🎉
Check out the changelog of [Meilisearch v1.1.0](https://github.com/meilisearch/meilisearch/releases/tag/v1.1.0) for more information on the changes.

### 🚀 Enhancements

- Add a new optional argument to `add_documents_csv`. This argument allows you to customize the separator character in your `csv` file. (#429) `@brunoocasali.`
- Add `client.multi_search()` method to execute multiple search requests simultaneously with different configurations. (#430) `@brunoocasali`
    Usage example:

    ```ruby
    client.multi_search([
      { index_uid: 'books', q: 'prince' },
      { index_uid: 'movies', q: 'prince' },
    ])
    ```
  ⚠️ The `SearchQuery` was not meant to be used if the regular `$index->search()` requests (yet).

Co-authored-by: meili-bot <74670311+meili-bot@users.noreply.github.com>
Co-authored-by: Bruno Casali <brunoocasali@gmail.com>
meili-bors bot added a commit that referenced this pull request Apr 3, 2023
432: Update version for the next release (v0.23.0) r=curquiza a=meili-bot

This version introduces features released on Meilisearch v1.1.0 🎉
Check out the changelog of [Meilisearch v1.1.0](https://github.com/meilisearch/meilisearch/releases/tag/v1.1.0) for more information on the changes.

### 🚀 Enhancements

- Add a new optional argument to `add_documents_csv`. This argument allows you to customize the separator character in your `csv` file. (#429) `@brunoocasali.`
- Add `client.multi_search()` method to execute multiple search requests simultaneously with different configurations. (#430) `@brunoocasali`
    Usage example:

    ```ruby
    client.multi_search([
      { index_uid: 'books', q: 'prince' },
      { index_uid: 'movies', q: 'prince' },
    ])
    ```
  ⚠️ The `SearchQuery` was not meant to be used if the regular `$index->search()` requests (yet).

Co-authored-by: meili-bot <74670311+meili-bot@users.noreply.github.com>
meili-bors bot added a commit that referenced this pull request Apr 3, 2023
432: Update version for the next release (v0.23.0) r=bidoubiwa a=meili-bot

This version introduces features released on Meilisearch v1.1.0 🎉
Check out the changelog of [Meilisearch v1.1.0](https://github.com/meilisearch/meilisearch/releases/tag/v1.1.0) for more information on the changes.

### 🚀 Enhancements

- Add a new optional argument to `add_documents_csv`. This argument allows you to customize the separator character in your `csv` file. (#429) `@brunoocasali.`
- Add `client.multi_search()` method to execute multiple search requests simultaneously with different configurations. (#430) `@brunoocasali`
    Usage example:

    ```ruby
    client.multi_search([
      { index_uid: 'books', q: 'prince' },
      { index_uid: 'movies', q: 'prince' },
    ])
    ```
  ⚠️ The `SearchQuery` was not meant to be used if the regular `$index->search()` requests (yet).

Co-authored-by: meili-bot <74670311+meili-bot@users.noreply.github.com>
Co-authored-by: cvermand <33010418+bidoubiwa@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants