Python - collection.query.stream()

Process query results as a stream.

from nitric.resources import collection
query = collection("profiles").allow('reading').query()
async for doc in query.stream():
# Process doc stream...
print(doc.content)

Examples

Streaming results from a query

from nitric.resources import collection
query = collection("profiles").allow('reading').query()
async for doc in query.stream():
# Process doc stream...
print(doc.content)

See also

Last updated on Dec 5, 2024