You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "Magnus Pierre (JIRA)" <ji...@apache.org> on 2015/05/26 10:11:17 UTC
[jira] [Comment Edited] (DRILL-3180) Apache Drill JDBC storage
plugin to query rdbms systems such as MySQL and Netezza from Apache Drill
[ https://issues.apache.org/jira/browse/DRILL-3180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14558754#comment-14558754 ]
Magnus Pierre edited comment on DRILL-3180 at 5/26/15 8:10 AM:
---------------------------------------------------------------
Storage mpjdbc should be unpacked in the contrib directory of Apache Drill. pom.xml is a replacement for pom.xml in contrib.
To just build the package use notations similar to following:
/Applications/apache-maven-3.2.5/bin/mvn clean install -pl contrib/storage-mpjdbc -DskipTests
Take the jar in contrib/storage-mpjdbc/target and move it to jar folder of a drill dist.
Add your jdbc driver to same folder.
Restart drillbits and conf a new plug-in and put in { type : "jdbc"}
and update, and you will get all configuration options.
Fill them in and update. Make sure not to use a dbname as name for the plug-in.
Example:
{
"type": "jdbc",
"driver": "com.mysql.jdbc.Driver",
"uri": "jdbc:mysql://192.168.1.xx/employees",
"username": "maprdemo",
"password": "maprdemo",
"enabled": true
}
Now you should be able to query the db using plug-in.table notation.
Dep on db you might need to have more or less detail in the URL.
was (Author: magnusp):
Storage mpjdbc should be unpacked in the contrib directory of Apache Drill. pom.xml is a replacement for pom.xml in contrib.
To just build the package use notations similar to following:
/Applications/apache-maven-3.2.5/bin/mvn clean install -pl contrib/storage-mpjdbc -DskipTests
Take the jar in contrib/storage-mpjdbc/target and move it to jar folder of a drill dist.
Add your jdbc driver to same folder.
Restart drillbits and conf a new plug-in and put in { type : "jdbc"}
and update, and you will get all configuration options.
Fill them in and update. Make sure not to use a dbname as name for the plug-in.
Example:
{
"type": "jdbc",
"driver": "com.mysql.jdbc.Driver",
"uri": "jdbc:mysql://192.168.1.xx/employees",
"username": "maprdemo",
"password": "maprdemo",
"enabled": true
}
Now you should be able to query the db using plug-in.table notation.
Dep on db you might need to have more or less detail in the URL. I have tried with Mysql and Netezza and Netezza demands dbname to be part of URL whilst Mysql doesn't.
> Apache Drill JDBC storage plugin to query rdbms systems such as MySQL and Netezza from Apache Drill
> ---------------------------------------------------------------------------------------------------
>
> Key: DRILL-3180
> URL: https://issues.apache.org/jira/browse/DRILL-3180
> Project: Apache Drill
> Issue Type: New Feature
> Components: Storage - Other
> Affects Versions: 1.0.0
> Reporter: Magnus Pierre
> Assignee: Jacques Nadeau
> Labels: Drill, JDBC, plugin
> Attachments: pom.xml, storage-mpjdbc.zip
>
> Original Estimate: 1m
> Remaining Estimate: 1m
>
> I have developed the base code for a JDBC storage-plugin for Apache Drill. The code is primitive but consitutes a good starting point for further coding. Today it provides primitive support for SELECT against RDBMS with JDBC.
> The goal is to provide complete SELECT support against RDBMS with push down capabilities.
> Currently the code is using standard JDBC classes.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)