historical-deadletter-processor
Advanced tools
Comparing version 2.1.1 to 2.2.0
@@ -44,4 +44,3 @@ "use strict"; | ||
index = _ref$index === undefined ? "errors" : _ref$index, | ||
_ref$extraFilters = _ref.extraFilters, | ||
extraFilters = _ref$extraFilters === undefined ? [] : _ref$extraFilters, | ||
conditions = _ref.conditions, | ||
_ref$logger = _ref.logger, | ||
@@ -62,3 +61,3 @@ logger = _ref$logger === undefined ? console : _ref$logger; | ||
this.index = index; | ||
this.extraFilters = extraFilters; | ||
this.conditions = conditions; | ||
this.logger = logger; | ||
@@ -96,7 +95,5 @@ this.client = this._buildClient(connection); | ||
var nDaysAgo, query, queryOptions; | ||
nDaysAgo = moment().subtract(this.daysRetrying, 'days').utc().format("YYYY-MM-DDTHH:mm:ss") + "z"; | ||
query = _.concat(["app eq '" + this.app + "'", "job eq '" + this.job + "'", "timestamp gt " + nDaysAgo], this.extraFilters).join(" and "); | ||
var queryOptions; | ||
queryOptions = { | ||
filter: query, | ||
filter: this._filter(), | ||
skip: page * SIZE_PAGE, | ||
@@ -114,2 +111,12 @@ top: SIZE_PAGE | ||
}, { | ||
key: "_filter", | ||
value: function _filter() { | ||
var nDaysAgo; | ||
if (this.conditions != null) { | ||
return this.conditions; | ||
} | ||
nDaysAgo = moment().subtract(this.daysRetrying, 'days').utc().format("YYYY-MM-DDTHH:mm:ss") + "z"; | ||
return ["app eq '" + this.app + "'", "job eq '" + this.job + "'", "timestamp gt " + nDaysAgo].join(" and "); | ||
} | ||
}, { | ||
key: "_doProcess", | ||
@@ -116,0 +123,0 @@ value: function _doProcess(row) { |
{ | ||
"name": "historical-deadletter-processor", | ||
"version": "2.1.1", | ||
"version": "2.2.0", | ||
"description": "historical-deadletter-processor", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
13214
221
0