CData Python Connector for HDFS

Build 21.0.7930

Establishing a Connection

The objects available within our connector are accessible from the "cdata.hdfs" module. In order to use the module's objects directly, the module must first be imported as below:

import cdata.hdfs as mod

From there, the connect() method can be called from the connector object to establish a connection using an appropriate connection string, such as the below:


Connecting to HDFS

In order to connect, set the following connection properties:

  • Host: Set this value to the host of your HDFS installation.
  • Port: Set this value to the port of your HDFS installation. Default port: 50070

Authenticating to HDFS

There are two authentication methods available for connecting to the HDFS data source, the Anonymous Authentication and the and Negotiate (Kerberos) Authentication.

Anonymous Authentication

In some situations, HDFS may be connected to without any authentication connection properties. To do so, simply set the AuthScheme to None (default).

Authenticate using Kerberos

When authentication credentials are required, authentication over Kerberos may be used. Please see Using Kerberos for details on how to authenticate with Kerberos.

Copyright (c) 2021 CData Software, Inc. - All rights reserved.
Build 21.0.7930