Skip to content

tranch/php-thrift-impala

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

69 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PHP ThriftSQL

This project based Automattic/php-thrift-sql.

Currently the following engines are supported:

  • Hive -- Over the HiveServer2 Thrift interface, SASL is enabled by default so username and password must be provided however this can be turned off with the setSasl() method before calling connect().
  • Impala -- Over the Impala Service Thrift interface which extends the Beeswax protocol.

Usage Example

// Load this lib
require_once __DIR__ . '/vendor/autoload.php';

// Try out an Impala query
$impala = new \ThriftSQL\Impala( 'hd-node1' );
$impalaTables = $impala
  ->connect()
  ->queryAndFetchAll( 'SHOW TABLES' );
print_r( $impalaTables );

// Don't forget to clear the client and close socket.
$impala->disconnect();

About

PHP Thrift Client for Impala queries.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages