setMaxEventBufferTime:(unsigned int)seconds;NewRelic.setMaxEventBufferTime:(unsigned int)seconds;
Sets the event harvest cycle length. Default is 600 seconds.
To ensure that the new value is always applied, place this API call in the
applicationDidBecomeActive iOS lifecycle method.
Compatible with all agent versions.
This method sets the maximum time in seconds that the New Relic iOS agent will store events in memory before including the buffered event to be sent to New Relic in the next harvest cycle.
In other words, when the oldest event timestamp exceeds this custom configured time, the agent transmits the buffered content at the harvest cycle between each connection from a New Relic agent to the collector. You must set this value after
Agent.start() is called.
- Default is 600 seconds (10 minutes).
- Minimum value cannot be less than 60 seconds.
setMaxEventPoolSize(), which lets you change the maximum size of the event pool.
For context on how to use this API, see the documentation about sending custom attributes and events to Insights for:
true if recorded successfully, and
false if it doesn't.
+ (void) setMaxEventBufferTime:(unsigned int)seconds;
BOOL fiveMinuteLimitSet = [NewRelic setMaxEventBufferTime:600];
let fiveMinuteLimitSet = NewRelic.setMaxEventBufferTime(600)