code: function assertValidQueryOptions (options) {
    var scanOptions = new Set(['UDF', 'concurrent', 'percentage', 'priority'])
    var invalid = Object.keys(options).filter(function (key) {
      return scanOptions.has(key)
    })
    assert(invalid.length === 0, util.format('Invalid query arguments: %s. Use Client#scan instead.', invalid.toString()))
    assert(!options.aggregationUDF, 'Invalid query arguments: Pass UDF params to Query#apply instead.')
  }
docs: In the v1 client the query() method was used for both Query and Scan operations. Since v2, Scan operations should use the scan() method instead.