#Dropbox and Drill As of Drill 1.20.0 it is possible to connect Drill to a Dropbox account and query files stored there. Clearly, the performance will be much better if the files are stored locally, however, if your data is located in dropbox Drill makes it easy to explore that data.
The first step to enabling Drill to query Dropbox is creating an API token.
Scoped Access
under Choose an API.Once you‘ve done that, and hit submit, you’ll see a section in your newly created Dropbox App called Generated Access Token
. Copy the value here and that is what you will use in your Drill configuration.
Once you‘ve created a Dropbox access token, you are now ready to configure Drill to query Dropbox. To create a dropbox connection, in Drill’s UI, navigate to the Storage tab, click on Create New Storage Plugin
and add the items below:
"type": "file", "connection": "dropbox:///", "config": { "dropboxAccessToken": "<your access token here>" }, "workspaces": { "root": { "location": "/", "writable": false, "defaultInputFormat": null, "allowAccessOutsideWorkspace": false } } }
Paste your access token in the appropriate field and at that point you should be able to query Dropbox. Drill treats Dropbox as any other file system, so all the instructions here (https://drill.apache.org/docs/file-system-storage-plugin/) and here (https://drill.apache.org/docs/workspaces/) about configuring a workspace, and adding format plugins are exactly the same as any other on Drill.
As with any other storage plugin, you have a few options as to how to store the credentials. See Drill Credentials Provider for more information about how you can store your credentials securely in Drill.
Unfortunately, in order to run the unit tests, it is necessary to have an external API token. Therefore, the unit tests have to be run manually. To run the unit tests:
ACCESS_TOKEN
variable.hdf-test.csvh
into that folderhttp-pcap.json
to the root directory of your dropbox accounttestListFiles
test, you will have to update the modified datesTest files can be found in the java-exec/src/test/resources/dropboxTestFiles
folder. Simply copy these files in the structure there into your dropbox account.