I wonder why it's possible to pass an AbortSignal ...
# community-help
d
I wonder why it's possible to pass an AbortSignal into the search call for the JS SDK, but not for the multi search call of the same SDK. Is there a reason for the difference or was that an oversight?
Copy code
searchClient.collections('blub').documents().search(
    {},
    {
        cacheSearchResultsForSeconds: 5, // available in both
        abortSignal: signal, // only available here
    },
)

searchClient.multiSearch.perform(
    { searches: [] },
    {},
    {
        cacheSearchResultsForSeconds: 5, // available in both
        //abortSignal: signal, // not available here
    },
)
j
CC: @Fanis Tharropoulos
f
The reason for this is that abort signal behavior isn't implemented for multisearch requests currently. I'll work on a PR adding the behavior & type definition
d
Thanks 🙂