Skip to content

TimeseriesStreamProvider

Streams every URL-backed TimeseriesPanel, TimeseriesGauge and TimeseriesCoreBars below it over one subscription per (baseUrl, range, interval) group — GET {baseUrl}stream?id=…&since=…&interval=… (clicky metrics.RegisterStreamRoutes) — instead of each series polling {baseUrl}{id}. Subscriptions open through useEventSourceFactory(), so place it inside an EventSourceProvider built with createEventHub() to share the tab’s single hub connection. A single-url panel streams from its url’s path prefix (see timeseriesStreamAddress). Series with a load, and widgets with refreshMs <= 0, keep fetching on their own. tsx const hub = createEventHub({ buildId }); <EventSourceProvider value={hub}> <TimeseriesStreamProvider>{app}</TimeseriesStreamProvider> </EventSourceProvider>

Source

import { TimeseriesStreamProvider } from "@flanksource/clicky-ui/data";

No dedicated Storybook demo is available for this component yet.

The props table documents the component-specific surface. Standard DOM attributes inherited from React, such as className, event handlers, and accessibility attributes, may also be accepted when the component’s prop type extends a native element.

Prop Type Default Description
debounceMs number — How long widget (un)registrations coalesce before a group re-subscribes. Defaults to 50ms.