File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -81,6 +81,9 @@ extension OptimizelyClient {
81
81
82
82
let interval = periodicDownloadInterval ?? 10 * 60
83
83
if interval > 0 {
84
+ if interval < 30 {
85
+ logger? . w ( . lowPeriodicDownloadInterval)
86
+ }
84
87
self . datafileHandler? . setPeriodicInterval ( sdkKey: sdkKey, interval: interval)
85
88
}
86
89
}
Original file line number Diff line number Diff line change 1
1
//
2
- // Copyright 2019-2021, Optimizely, Inc. and contributors
2
+ // Copyright 2019-2021, 2023 Optimizely, Inc. and contributors
3
3
//
4
4
// Licensed under the Apache License, Version 2.0 (the "License");
5
5
// you may not use this file except in compliance with the License.
@@ -67,6 +67,7 @@ enum LogMessage {
67
67
case failedToConvertMapToString
68
68
case failedToAssignValue
69
69
case valueForKeyNotFound( _ key: String )
70
+ case lowPeriodicDownloadInterval
70
71
}
71
72
72
73
extension LogMessage : CustomStringConvertible {
@@ -128,6 +129,7 @@ extension LogMessage: CustomStringConvertible {
128
129
case . failedToConvertMapToString: message = " Provided map could not be converted to string. "
129
130
case . failedToAssignValue: message = " Value for path could not be assigned to provided type. "
130
131
case . valueForKeyNotFound( let key) : message = " Value for JSON key ( \( key) ) not found. "
132
+ case . lowPeriodicDownloadInterval: message = " Polling intervals below 30 seconds are not recommended. "
131
133
}
132
134
133
135
return message
You can’t perform that action at this time.
0 commit comments