Errors are returned within the stream rather than as
exceptions that would halt the entire stream. This is because
some implementations may pull data from multiple sources
including some that may be unreliable. In many cases,
these errors can be safely ignored.
See GraffitiStreamError.
The stream is an AsyncGenerator
that can be iterated over using for await loops or calling next on the generator.
The stream can be terminated by breaking out of a loop calling return on the generator.
The stream ends by returning a continue
function and a cursor string,
each of which can be used to resume the stream from where it left off.
A stream of data that are returned by Graffiti's query-like operations Graffiti.discover and Graffiti.recoverOrphans.
Errors are returned within the stream rather than as exceptions that would halt the entire stream. This is because some implementations may pull data from multiple sources including some that may be unreliable. In many cases, these errors can be safely ignored. See GraffitiStreamError.
The stream is an
AsyncGenerator
that can be iterated over usingfor await
loops or callingnext
on the generator. The stream can be terminated by breaking out of a loop callingreturn
on the generator.The stream ends by returning a
continue
function and acursor
string, each of which can be used to resume the stream from where it left off.