Skip to content

TimeoutException: TimeoutException after 0:01:00.000000: Future not completed #146

@hashimsayed0

Description

@hashimsayed0

Describe the bug

I'm using typesense client to do multi search. When I noticed that TimeoutException was thrown for some users, I kept increasing connectionTimeout and it fixed the issue for some people. At the moment, it's 1 minute and I'm not sure I'm doing the right thing. Some people still face the issue. Would it be best to increase it further? Is there an optimal value for connectionTimeout? Thank yoou.

Steps to reproduce the behavior:

  1. Initialise client
final host = "***.typesense.net";
final config = Configuration(
  // Replace with your configuration
  'apiKey',
  nodes: {
    Node.withUri(
      Uri(
        scheme: 'https',
        host: host,
        port: 443,
      ),
    ),
  },
  numRetries: 3, // A total of 4 tries (1 original try + 3 retries)
  connectionTimeout: const Duration(minutes: 1),
);
final client = Client(config);
  1. Perform multi search
Map<String, dynamic> searchResults =
      await client.multiSearch.perform(searchRequests);

Expected behavior

Return searchResults

Screenshots

N/A

Additional context

N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions