Skip to content

lourenzo/node-prestodb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Presto db Client

A new wrapper around Presto HTTP API wrapper for Node.js.

Usage

'use strict';

const PrestoClient = require('prestodb');

let prestoClient = new PrestoClient({
  url: 'http://server-url:8080',
  user: 'presto',
  catalog: 'catalog',
  schema: 'schema',
  nextUriTimeout: 200 // in miliseconds
});

prestoClient.sendStatement('SELECT * FROM catalog.schema.table')
  .then((result) => {
    console.log(result)
  })
  .catch((error) => {
    console.error({ error })
  });

Todo

  • Offer a EventEmitter version
  • Send progress info
  • More efficient request queueing and throttling

About

New Node.js Presto HTTP REST API Wrapper

Resources

License

Stars

Watchers

Forks

Packages

No packages published