Problem
Currently, the PeriodicExporter is statically configured to wake up every 10 seconds and to check if there is anything to export from the disk:
|
internal class PeriodicExporter( |
|
private val delegate: SignalFromDiskExporter, |
|
private val exportPeriod: Duration = 10.seconds, |
|
) : PeriodicRunnable { |
I have overridden the defaults for the disk buffering to write the files for at least 15 minutes to reduce the number of calls on my backend (I have tens of thousands of devices producing logs around the clock, so the number of requests would incur extreme amount of costs with the default disk buffering config). However, I'm unable to reduce the frequency of the PeriodicExporter to check the buffers less frequently, so it is checking the buffers 90 times more frequently than necessary.
Proposal
Use the DiskBufferingConfig.minFileAgeForReadMillis property for PeriodicExporter.exportPeriod? (I'm open for better suggestions)
Problem
Currently, the
PeriodicExporteris statically configured to wake up every 10 seconds and to check if there is anything to export from the disk:opentelemetry-android/core/src/main/java/io/opentelemetry/android/features/diskbuffering/scheduler/PeriodicExporter.kt
Lines 11 to 14 in e6062e8
I have overridden the defaults for the disk buffering to write the files for at least 15 minutes to reduce the number of calls on my backend (I have tens of thousands of devices producing logs around the clock, so the number of requests would incur extreme amount of costs with the default disk buffering config). However, I'm unable to reduce the frequency of the
PeriodicExporterto check the buffers less frequently, so it is checking the buffers 90 times more frequently than necessary.Proposal
Use the
DiskBufferingConfig.minFileAgeForReadMillisproperty forPeriodicExporter.exportPeriod? (I'm open for better suggestions)