Redis.destroyCachedValues()

Destroy the values stored under the specified keys.

Usage

Hover over inputs/exits for more info.

var Redis = require('machinepack-redis');


// Destroy the values stored under the specified keys.

Redis.destroyCachedValues({

connection: '===',

keys: [ 'myNamespace.foo.bar_baz' ],

meta: '===',

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// The specified array of keys contains one or more keys which are not valid for this cache.

invalidKeys: function (result) {

 

},

// The cache encountered an error while attempting to destroy one or more of the specified keys.

failed: function (result) {

 

},

: function () {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

connection required

An active Redis connection.

'==='
keys required

An array of unique keys to delete.

[ 'myNamespace.foo.bar_baz' ]
meta

Additional metadata to pass to the driver.

'==='

Exits

error

An unexpected error occurred.

invalidKeys

The specified array of keys contains one or more keys which are not valid for this cache.

{ meta: '===' }
failed

The cache encountered an error while attempting to destroy one or more of the specified keys.

{ error: '===', meta: '===' }
undefined
success

OK.

{ meta: '===' }