@atolis-hq/wake 0.2.90 → 0.2.91
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -96,11 +96,12 @@ export function createControlPlane(deps) {
|
|
|
96
96
|
}
|
|
97
97
|
}
|
|
98
98
|
else {
|
|
99
|
-
const
|
|
99
|
+
const waitMs = input.idleBackoff ? nextSleepMs(input.getIdleTicks()) : deps.intervalMs;
|
|
100
|
+
const wait = await sleepUntilNextTick(waitMs, {
|
|
100
101
|
getLastRequest: input.getLastRequest,
|
|
101
102
|
setLastRequest: input.setLastRequest,
|
|
102
103
|
});
|
|
103
|
-
if (!wait.forced) {
|
|
104
|
+
if (!wait.forced && input.idleBackoff) {
|
|
104
105
|
input.setIdleTicks(input.getIdleTicks() + 1);
|
|
105
106
|
}
|
|
106
107
|
}
|
|
@@ -141,6 +142,7 @@ export function createControlPlane(deps) {
|
|
|
141
142
|
setLastRequest: (value) => {
|
|
142
143
|
lastIntakeTickRequest = value;
|
|
143
144
|
},
|
|
145
|
+
idleBackoff: true,
|
|
144
146
|
}),
|
|
145
147
|
startLoop({
|
|
146
148
|
run: deps.tickRunner.runRunnerTick,
|
|
@@ -153,6 +155,7 @@ export function createControlPlane(deps) {
|
|
|
153
155
|
setLastRequest: (value) => {
|
|
154
156
|
lastRunnerTickRequest = value;
|
|
155
157
|
},
|
|
158
|
+
idleBackoff: false,
|
|
156
159
|
}),
|
|
157
160
|
]);
|
|
158
161
|
return;
|
package/dist/src/version.js
CHANGED