@trivago/samsa
Advanced tools
Comparing version 0.3.0-beta.1 to 0.3.0-beta.2
@@ -15,2 +15,3 @@ /// <reference types="node" /> | ||
constructor(primaryKTable: KTable, foreignKTable: KTable, projection: JoinProjection<any, any, any>); | ||
private startProcessInterval; | ||
finishUp(): Promise<unknown>; | ||
@@ -17,0 +18,0 @@ finalizeBuffer(): EventEmitter; |
@@ -91,7 +91,12 @@ "use strict"; | ||
_this.subProcesses = new Set(); | ||
_this.keyBufferProcessInterval = setInterval(function () { | ||
_this.keyBufferProcessInterval = _this.startProcessInterval(); | ||
return _this; | ||
} | ||
Joiner.prototype.startProcessInterval = function () { | ||
var _this = this; | ||
this.keyBufferProcessInterval = setInterval(function () { | ||
_this.finalizeBuffer(); | ||
}, 1000); | ||
return _this; | ||
} | ||
return this.keyBufferProcessInterval; | ||
}; | ||
Joiner.prototype.finishUp = function () { | ||
@@ -146,2 +151,7 @@ var _this = this; | ||
this.keyBuffer.add(key); | ||
if (this.keyBuffer.size >= 1000) { | ||
clearInterval(this.keyBufferProcessInterval); | ||
this.finalizeBuffer(); | ||
this.startProcessInterval(); | ||
} | ||
next(); | ||
@@ -148,0 +158,0 @@ return [2 /*return*/]; |
{ | ||
"name": "@trivago/samsa", | ||
"version": "0.3.0-beta.1", | ||
"version": "0.3.0-beta.2", | ||
"types": "lib/index.d.ts", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -31,5 +31,10 @@ import { Readable, TransformCallback } from "stream"; | ||
this.keyBufferProcessInterval = this.startProcessInterval(); | ||
} | ||
private startProcessInterval() { | ||
this.keyBufferProcessInterval = setInterval(() => { | ||
this.finalizeBuffer(); | ||
}, 1000); | ||
return this.keyBufferProcessInterval; | ||
} | ||
@@ -97,2 +102,9 @@ | ||
this.keyBuffer.add(key); | ||
if (this.keyBuffer.size >= 1000) { | ||
clearInterval(this.keyBufferProcessInterval); | ||
this.finalizeBuffer(); | ||
this.startProcessInterval(); | ||
} | ||
next(); | ||
@@ -99,0 +111,0 @@ } |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
200743
155
4821