Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to connect secure drill version 1.15 using pydrill #39

Open
goodjoefong opened this issue May 27, 2019 · 0 comments
Open

Unable to connect secure drill version 1.15 using pydrill #39

goodjoefong opened this issue May 27, 2019 · 0 comments

Comments

@goodjoefong
Copy link

goodjoefong commented May 27, 2019

Trying to connect drill 1.15 using pydrill but failed. Used sqlline and I am able to connect by using MAPRSAL or PLAIN authorization. Also I can use drill explorer or tableau to connect to drill.

OS : CentOS 7

<< test.py >>
from pydrill.client import PyDrill
import sys
import os
header = {"Accept": "application/json"}
drill = PyDrill(host='127.0.0.1', port=8047, auth='mapr:XXXXXXXX$!')

< Error >>
select CONCAT(Address1 ,Address2) as Address from dfs.uat_kfe.Address_LMS where Address1 is not null
Traceback (most recent call last):
File "/home/mapr/dataload_scripts/megaloan_scripts/address/test.py", line 12, in
drill = PyDrill(host='127.0.0.1', port=8047, auth='mapr:XXXXXXXX$!')
File "/usr/lib/python2.7/site-packages/pydrill/client/init.py", line 21, in init
self.transport = trasport_class(host, port, connection_class=connection_class, auth=auth, **kwargs)
File "/usr/lib/python2.7/site-packages/pydrill/transport.py", line 21, in init
self.connection = connection_class(host, port, **kwargs)
File "/usr/lib/python2.7/site-packages/pydrill/connection/requests_conn.py", line 65, in init
headers={}
File "/usr/lib/python2.7/site-packages/pydrill/connection/requests_conn.py", line 100, in perform_request
raise ConnectionError('N/A', str(e), e)
pydrill.exceptions.ConnectionError: ConnectionError(('Connection aborted.', BadStatusLine("''",))) caused by: ConnectionError(('Connection aborted.', BadStatusLine("''",)))

<< SQLline screen >>
/opt/mapr/drill/drill-1.15.0/bin/sqlline
Apache Drill 1.15.0.0-mapr
"Your Drill is the Drill that will pierce the heavens."
sqlline> !connect jdbc:drill:drillbit=localhost:31010;auth=MAPRSASL mapr XXXXXXXX$!
0: jdbc:drill:drillbit=localhost:31010> !close
Closing: org.apache.drill.jdbc.impl.DrillConnectionImpl
sqlline> !connect jdbc:drill:drillbit=localhost:31010;auth=PLAIN mapr XXXXXXXX$!
0: jdbc:drill:drillbit=localhost:31010> !quit
Closing: org.apache.drill.jdbc.impl.DrillConnectionImpl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant