Batching and why shutdown is last
The SDK sends generation data to the Agent Observability API in batches from a queue of generations waiting to be exported.
The batching defaults
batchSize, default 100: maximum generations per export batch.flushInterval, default 1s: how often the SDK exports queued generations.queueSize, default 2000: maximum number of queued generations before the SDK drops new ones.
Why shutdown is last
client.shutdown() in each sample shuts down the client after the capture. If your application also sets up OpenTelemetry tracing and metrics, shut those down after the client.