Request flow:
RequestBuilder
builds a set of 1 or more filters and has a human readable id, this is used to track the query result sets (NoteCollection
)- ID is important for grouping requests, grouping happens when multiple
RequestBuilder
objects are requested with the same ID. In this case filters are emitted aftergroupingDelay
- The
NoteCollection
is a container to store events, it stores only the latest version of replaceable events and contains no duplicates, it also track which relays events are seen on.
- ID is important for grouping requests, grouping happens when multiple
RequestBuilder
is sent to theQueryManager
, if theQuery
already exists (query.id === builder.id
) then the newRequestBuilder
filters are appended to the query, otherwise a newQuery
object is created and stored in theQueryManager
.Query
object (sometime later) emits an event to send filters to relays (handled inQueryManager
).QueryManager
asks `Cach