aerospike
Advanced tools
Comparing version 4.0.0 to 4.0.1
@@ -5,15 +5,21 @@ # Changelog | ||
## [4.0.1] | ||
* **Updates** | ||
* Update deprecated Aerospike PredExp usage | ||
* Update Aerospike Expressions usage | ||
## [4.0.0] | ||
* **New Features** | ||
* Support boolean particle type. This feature requires server version 5.6+. [#428](https://github.com/aerospike/aerospike-client-nodejs/pull/428) | ||
* Add support for Aerospike Expressions | ||
* Added TypeScript typings. [#446](https://github.com/aerospike/aerospike-client-nodejs/pull/446) Thanks to [@bit0r1n](https://github.com/bit0r1n)! | ||
* [CLIENT-1678] - Support boolean particle type. This feature requires Aerospike server version 5.6+. [#428](https://github.com/aerospike/aerospike-client-nodejs/pull/428) | ||
* [CLIENT-1679] - Add support for Aerospike Expressions. | ||
* [CLIENT-1680] - Added TypeScript typings. [#446](https://github.com/aerospike/aerospike-client-nodejs/pull/446) Thanks to [@bit0r1n](https://github.com/bit0r1n)! | ||
* **Updates** | ||
* *BREAKING*: This client requires server version 4.9 or later. | ||
* *BREAKING*: Drop support for Node.js 8. | ||
* *BREAKING*: Remove support for CentOS 6 as well as Ubuntu 16.0.4. | ||
* *BREAKING*: Remove Scan#priority, Scan#percent, and ScanPolicy#failOnClusterChange, as the server no longer supports these fields. | ||
* Add support for building c-client as sub-module | ||
* BREAKING: This client requires server version 4.9 or later. | ||
* BREAKING: Drop support for Node.js 8. | ||
* BREAKING: Remove support for CentOS 6 as well as Ubuntu 16.04. | ||
* BREAKING: Remove Scan#priority, Scan#percent, and ScanPolicy#failOnClusterChange, as the server no longer supports these fields. | ||
* Add support for building c-client as a sub-module. | ||
@@ -20,0 +26,0 @@ ## [3.16.7] - 2022-01-10 |
@@ -27,8 +27,12 @@ // ***************************************************************************** | ||
* | ||
* @description This module defines predicate expression that provide a | ||
* mechanism for additional filtering on the resultset of a secondary index | ||
* query or scan operation. | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* PredicateExpression filtering requires Aerospike Server version 3.12 or later. | ||
* @description This module defines predicate expression that provide a mechanism | ||
* for additional filtering on the resultset of a secondary index query or | ||
* primary index query (scan) operation. | ||
* | ||
* PredicateExpression filtering was deprecated in Aerospike Server version 5.2 and | ||
* removed in Aerospike Server version 6.0. | ||
* Use Filter Expressions, implemented by the aerospike/exp module. | ||
* | ||
* For more information, please refer to the | ||
@@ -44,2 +48,4 @@ * <a href="https://www.aerospike.com/docs/guide/predicate.html">⇑PredicateExpression Filtering</a> | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* Sequences of predicate expressions are used limit the results of query | ||
@@ -60,2 +66,4 @@ * operations. They are created using the methods in the {@link | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The AND predicate expression returns true if all of its | ||
@@ -96,2 +104,4 @@ * children are true. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The OR predicate expression returns true if any of its children | ||
@@ -132,2 +142,4 @@ * are true. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The NOT predicate expression returns true if its child is | ||
@@ -163,2 +175,4 @@ * false. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The integer value predicate expression pushes a single constant | ||
@@ -195,2 +209,4 @@ * integer value onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The string value predicate expression pushes a single constant | ||
@@ -227,2 +243,4 @@ * string value onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The GeoJSON value predicate expression pushes a single constant | ||
@@ -262,2 +280,4 @@ * string value onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The integer bin predicate expression pushes a single integer | ||
@@ -294,2 +314,4 @@ * bin value extractor onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The string bin predicate expression pushes a single string bin | ||
@@ -326,2 +348,4 @@ * value onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The GeoJSON bin predicate expression pushes a single GeoJSON | ||
@@ -360,2 +384,4 @@ * bin value onto the expression stack. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The list bin predicate expression pushes a single list bin | ||
@@ -392,2 +418,4 @@ * value extractor onto the expression stack. List bin values may be used with | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The map bin predicate expression pushes a single map bin value | ||
@@ -424,2 +452,4 @@ * extractor onto the expression stack. Map bin values may be used with map | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The integer iteration variable is used in the subexpression | ||
@@ -455,2 +485,4 @@ * child of a list or map iterator and takes the value of each element in the | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The string iteration variable is used in the subexpression | ||
@@ -486,2 +518,4 @@ * child of a list or map iterator and takes the value of each element in the | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The GeoJSON iteration variable is used in the subexpression | ||
@@ -503,2 +537,4 @@ * child of a list or map iterator and takes the value of each element in the | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The record device size expression assumes the value of the size | ||
@@ -530,2 +566,4 @@ * in bytes that the record occupies on device storage. For non-persisted | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The record last update expression assumes the value of the | ||
@@ -558,2 +596,4 @@ * number of nanoseconds since the unix epoch that the record was last updated. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The record void time expression assumes the value of the number | ||
@@ -585,2 +625,4 @@ * of nanoseconds since the unix epoch when the record will expire. The special | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The digest modulo expression assumes the value of 4 bytes of | ||
@@ -613,2 +655,4 @@ * the record's key digest modulo it's modulus argument. | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The integer comparison expressions pop a pair of value | ||
@@ -706,2 +750,4 @@ * expressions off the expression stack and compare them. The deeper of the two | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The string comparison expressions pop a pair of value | ||
@@ -751,2 +797,4 @@ * expressions off the expression stack and compare them. The deeper of the two | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The string regex expression pops two children off the | ||
@@ -795,2 +843,4 @@ * expression stack and compares a child value expression to a regular | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The Points-in-Region (within) expression pops two children off | ||
@@ -834,2 +884,4 @@ * the expression stack and checks to see if a child GeoJSON point is inside a | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The Regions-Containing-Point (contains) expression pops two | ||
@@ -870,2 +922,4 @@ * children off the expression stack and checks to see if a child GeoJSON | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The list iteration expression pops two children off the | ||
@@ -907,2 +961,4 @@ * expression stack. The left child (pushed earlier) must contain a logical | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The list iteration expression pops two children off the | ||
@@ -945,2 +1001,4 @@ * expression stack. The left child (pushed earlier) must contain a logical | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The map key iteration expression pops two children off the | ||
@@ -982,2 +1040,4 @@ * expression stack. The left child (pushed earlier) must contain a logical | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The map key iteration expression pops two children off the | ||
@@ -1020,2 +1080,4 @@ * expression stack. The left child (pushed earlier) must contain a logical | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The map value iteration expression pops two children off the | ||
@@ -1057,2 +1119,4 @@ * expression stack. The left child (pushed earlier) must contain a logical | ||
* | ||
* @deprecated since Aerospike Server version 5.2 | ||
* | ||
* @description The map value iteration expression pops two children off the | ||
@@ -1059,0 +1123,0 @@ * expression stack. The left child (pushed earlier) must contain a logical |
@@ -71,4 +71,4 @@ // ***************************************************************************** | ||
* | ||
* Using Aerospike Predicate Filtering (Aerospike server version 3.12 and | ||
* later), you can: | ||
* Using Aerospike Predicate Filtering (deprecated in Aerospike server version 5.2; | ||
* removed in Aerospike server version 6.0), you can: | ||
* | ||
@@ -82,3 +82,3 @@ * - Filter out records based on record meta data, such as last-update-time or | ||
* | ||
* See {@link module:aerospike/predexp} for a list of supported predicate | ||
* See {@link module:aerospike/predexp} for a list of deprecated predicate | ||
* expressions. | ||
@@ -85,0 +85,0 @@ * |
{ | ||
"name": "aerospike", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"description": "Aerospike Client Library", | ||
@@ -55,3 +55,3 @@ "keywords": [ | ||
"dependencies": { | ||
"@mapbox/node-pre-gyp": "^1.0.8", | ||
"@mapbox/node-pre-gyp": "^1.0.9", | ||
"bindings": "^1.3.0", | ||
@@ -58,0 +58,0 @@ "ink-docstrap": "^1.3.2", |
@@ -26,2 +26,3 @@ // ***************************************************************************** | ||
const helper = require('./test_helper') | ||
const exp = Aerospike.exp | ||
@@ -227,2 +228,26 @@ const AerospikeError = Aerospike.AerospikeError | ||
it('returns the key matching the expression', function (done) { | ||
const uniqueExpKey = 'test/query/record_with_stored_key' | ||
const key = new Aerospike.Key(helper.namespace, testSet, uniqueExpKey) | ||
const record = { name: uniqueExpKey } | ||
const meta = { ttl: 300 } | ||
const policy = new Aerospike.WritePolicy({ | ||
key: Aerospike.policy.key.SEND | ||
}) | ||
client.put(key, record, meta, policy, function (err) { | ||
if (err) throw err | ||
const query = client.query(helper.namespace, testSet) | ||
const queryPolicy = { filterExpression: exp.keyExist(uniqueExpKey) } | ||
const stream = query.foreach(queryPolicy) | ||
let count = 0 | ||
stream.on('data', record => { | ||
expect(++count).to.equal(1) | ||
expect(record.key).to.be.instanceof(Key) | ||
expect(record.key.key).to.equal(uniqueExpKey) | ||
}) | ||
stream.on('end', done) | ||
}) | ||
}) | ||
context('with nobins set to true', function () { | ||
@@ -233,2 +258,21 @@ helper.skipUnlessVersion('>= 3.15.0', this) | ||
const query = client.query(helper.namespace, testSet) | ||
const queryPolicy = { filterExpression: exp.eq(exp.binInt('i'), exp.int(5)) } | ||
query.nobins = true | ||
let received = null | ||
const stream = query.foreach(queryPolicy) | ||
stream.on('error', error => { throw error }) | ||
stream.on('data', record => { | ||
received = record | ||
stream.abort() | ||
}) | ||
stream.on('end', () => { | ||
expect(received.bins).to.be.empty() | ||
expect(received.gen).to.be.ok() | ||
expect(received.ttl).to.be.ok() | ||
done() | ||
}) | ||
}) | ||
it('should return only meta data', function (done) { | ||
const query = client.query(helper.namespace, testSet) | ||
query.where(Aerospike.filter.equal('i', 5)) | ||
@@ -235,0 +279,0 @@ query.nobins = true |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
32932
79178042
269
Updated@mapbox/node-pre-gyp@^1.0.9