ping

// Using callbacks (NodeJS or Web Browser)
kuzzle.memoryStorage.ping(function (err, response) {
  // callback called once the action has completed
});

// Using promises (NodeJS only)
kuzzle.memoryStorage.pingPromise()
  .then(response => {
    // resolved once the action has completed
  });
kuzzle.memoryStorage.ping(new ResponseListener<String>() {
  @Override
  public void onSuccess(String response) {
    // callback called once the action has completed
  }

  @Override
  public void onError(JSONObject error) {
  }
});
<?php

use \Kuzzle\Kuzzle;


$kuzzle = new Kuzzle('localhost');

try {
  $ping = $kuzzle->memoryStorage()->ping();
}
catch (ErrorException $e) {

}

Callback response:

"PONG"

Pings the memory storage database.

[Redis documentation]


ping([options], callback)

ArgumentsTypeDescription
optionsJSON ObjectOptional parameters
callbackfunctionCallback

Options

OptionTypeDescriptionDefault
queuablebooleanMark this request as (not) queuabletrue

Callback response

Resolves to a simple "PONG" string.