@authbroker/mongo-benchmark

0.0.9 • Public • Published

Benchmark for authBroker

Open Source Love Build Status

Test plan and demo maker for authBroker and Paraffin IoT Platform. If you can run by Parse method, be sure apiserver is running.

var benchmark = require('@authbroker/mongo-benchmark')

var opts = {
    type: 'parse',
    parse: {
        serverURL: 'http://localhost:5000/api',
        appId: 'APP_ID',
        javascriptKey: 'JAVASCRIPT_KEY',
        masterKey: 'MASTER_KEY',
        methodology: 'horizontal',
    },
    salt: {
        iterations: 10,
        hashBytes: 64,
        digest: 'sha512',
        salt: 'salt'
    }

}
var demo = new benchmark(opts)

// print valid demo data list
console.log('print valid demo data list:')
var validData = demo.validData()
console.log(validData)

// save valid demo data to db
demo.insertValidData(function () {
    demo.readData({ clientId: validData[1].clientId, realm: validData[1].realm }, function (callback) {
        console.log('clientID -> ' + validData[1].clientId + ' is searching in db:')
        console.log(callback)
    })
})

Authors / Contributors

Copyright

MIT - Copyright (c) 2019 ioKloud

Package Sidebar

Install

npm i @authbroker/mongo-benchmark

Weekly Downloads

0

Version

0.0.9

License

MIT

Unpacked Size

28.2 kB

Total Files

14

Last publish

Collaborators

  • iokloud.com
  • kamerdack