Skip to content

Commit 2357472

Browse files
authored
Merge pull request #13 from devtron-labs/logs-throttling-fix
fix: Update app.js
2 parents 8a545e7 + 49c2d2e commit 2357472

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

app.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ app.get('/health', (req, res) => res.send({"status": "OK", "time": new Date()}))
2121
var port = process.env.PORT || 8080;
2222
app.listen(port);
2323

24+
// setInterval(callback, delay, [arg1, arg2, ...])
25+
// callback: The function to execute at each interval.
26+
// delay: Time in milliseconds between each execution of the callback.
27+
// arg1, arg2, ... (optional): Additional arguments passed to the callback function.
28+
2429
setInterval(function(str1, str2) {
2530
var text = makeid(40);
2631
var ran = Math.random()
@@ -34,7 +39,7 @@ setInterval(function(str1, str2) {
3439
//console.log(logs[i])
3540
i++
3641
if (i == logs.length) i = 0
37-
}, 1, "Hello.", "How are you?");
42+
}, 2000, "Hello.", "How are you?");
3843

3944
function makeid(length) {
4045
var text = "";

0 commit comments

Comments
 (0)