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

[v1.13] Remote federated search requests (experimental) #1872

Open
2 tasks
Strift opened this issue Feb 20, 2025 · 6 comments · May be fixed by #1891
Open
2 tasks

[v1.13] Remote federated search requests (experimental) #1872

Strift opened this issue Feb 20, 2025 · 6 comments · May be fixed by #1891
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@Strift
Copy link
Collaborator

Strift commented Feb 20, 2025

Following the changes related to Meilisearch v1.13.0 mega issue:

Description

Implement the experimental feature for remote federated search requests.

For further reference, see the related Meilisearch engine issue.

Specifications

@Strift Strift added enhancement New feature or request good first issue Good for newcomers labels Feb 20, 2025
@consoleLogIt
Copy link
Contributor

@Strift hi
i would like to on this.

@Strift
Copy link
Collaborator Author

Strift commented Feb 27, 2025

Hello, thanks for your interest!

I'd love to review your PR for this!

We prefer not assigning issues because we've met users who asked to be assigned but never came back.
This sometimes discourages other volunteer contributors from opening a PR to fix this issue.

Make sure to check our contributing guidelines. I'm looking forward to reviewing your PR.

@consoleLogIt
Copy link
Contributor

Hi @Strift @flevi29
i was going to start working on this, but I need some guidance.
after reading the doc and going through the code.

This is what i have understood, please correct me if i am missing something.

  1. add a function to toggleNetworkFeature.
    ( although i was thinking maybe we can add function let's say updateExperimentalFeatures and then call this function from an individual feature function like toggleNetworkFunction?, also i saw that there is another experimental feature that is being used called editDocumentsByFunction so maybe i can add this function as well. )
  2. add function for the network api.
  3. Update the multi-search functionality to accept the [remote parameter]

also, i can write a test for a multi-search query with a remote federation search and test it locally but i am not sure how you will you run this test in ci/cd since this requries multiple instances

thanks

@Strift
Copy link
Collaborator Author

Strift commented Mar 9, 2025

Hello @consoleLogIt

In this SDK, we don't create methods to enable experimental features. We could in the future, but it's not required. You can document that the feature needs to enabled in the tests, and in the README.

I would recommend creating the following methods for managing the remote instances:

  • setRemoteInstances(instances: Record<string, {url: string, searchApiKey: string}>)
  • setInstanceName(name: string)

Then, update the search methods to accept the new remote parameter in federationOptions object. Incude a link to the docs page in the JSdoc :)

also, i can write a test for a multi-search query with a remote federation search and test it locally but i am not sure how you will you run this test in ci/cd since this requries multiple instances

I think we should be able to come up with something by creating multiple instances of Meilisearch via Docker Compose (local) and Github actions (CI). I haven't thought much about it yet though.

@consoleLogIt
Copy link
Contributor

consoleLogIt commented Mar 9, 2025

@Strift
hi

alright I understand.
i will work on it and create a draft pr for the review.
thanks

@consoleLogIt
Copy link
Contributor

@Strift
hi
I've created a PR. Could you please take a look whenever you get a chance?
thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants