Do not bundle aggregations for APIs which shouldn't include them. (#11592)

And make bundling aggregations opt-in, instead of opt-out to avoid
having APIs to include extraneous data (and being much heavier than
necessary).
This commit is contained in:
Patrick Cloke 2021-12-20 14:14:38 -05:00 committed by GitHub
parent c3e38b88f2
commit dd47788752
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 31 additions and 27 deletions

View file

@ -542,7 +542,10 @@ class PaginationHandler:
chunk = {
"chunk": (
await self._event_serializer.serialize_events(
events, time_now, as_client_event=as_client_event
events,
time_now,
bundle_aggregations=True,
as_client_event=as_client_event,
)
),
"start": await from_token.to_string(self.store),