algolia / algoliasearch-client-android

Algolia Search API Client for Android

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Getting exception - Error while reading stream: thread interrupted

passiondroid opened this issue Β· comments

Describe the bug πŸ›
Getting below exception very frequently
com.algolia.search.saas.AlgoliaException: Error while reading stream: thread interrupted
at com.algolia.search.saas.AbstractClient._toByteArray(AbstractClient.java:472)
at com.algolia.search.saas.AbstractClient._requestRaw(AbstractClient.java:632)
at com.algolia.search.saas.AbstractClient.postRequestRaw(AbstractClient.java:425)
at com.algolia.search.saas.Index.searchRaw(Index.java:1383)
at com.algolia.search.saas.Index.search(Index.java:1355)
at com.algolia.search.saas.Index.searchSync(Index.java:139)
at com.algolia.search.saas.Index.searchSync(Index.java:148)

To Reproduce πŸ”
Steps to reproduce the behavior:
Start sending multiple requests for keywords very fast

Expected behavior πŸ’­
thread interrupted should be handled.

Hi @passiondroid, thanks for reporting this bug and sorry for the inconvenience it caused!

I have a hard time replicating it by typing fast in a SearchBox. Can you give more details on when it happens:

  • Is it only on an actual device or emulator as well?
    • If only on actual devices, does it happen on any device?
  • Can you replicate it in our example apps like ecommerce, or does it only happen within your application?
    • If it is the latter, can you share a minimal sample code replicating the activity in your app where you see the bug?

Thanks for your help, looking forward to finding the root cause of this!