Skip to content

Add wait() method to Task class #739

Open
@Strift

Description

@Strift

Description

Add wait(int $timeoutInMs, int $intervalInMs) method to Task class.

Basic example

So instead of:

$task = $this->client->createIndex('new-index', ['primaryKey' => 'objectID']);
$task = $this->index->waitForTask($task->getTaskUid());

We could write:

$task = $this->client->createIndex('new-index', ['primaryKey' => 'objectID'])->wait();

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions