close method

JSPromise<JSAny?> close()

Commits all enqueued writes and marks the BulkWriter instance as closed.

After calling close(), calling any method will throw an error. Any retries scheduled as part of an onWriteError() handler will be run before the close() promise resolves.

Returns a Promise that resolves when all writes have been committed. The Promise will never be rejected. Calling this method will send all requests. The promise resolves immediately if there are no pending writes.

@return A promise that resolves when all enqueued writes up to this point have been committed.

Implementation

external JSPromise close();