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

Influx Connector #2397

Closed
wants to merge 20 commits into from
Closed
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ temp-testng-customsuite.xml
test-output
.externalToolBuilders
*~
\#*
williame marked this conversation as resolved.
Show resolved Hide resolved
benchmark_outputs
*.pyc
*.class
Expand Down
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@
<module>presto-elasticsearch</module>
<module>presto-iceberg</module>
<module>presto-google-sheets</module>
<module>presto-influx</module>
</modules>

<dependencyManagement>
Expand Down
43 changes: 43 additions & 0 deletions presto-docs/src/main/sphinx/connector/influx.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
================
Influx Connector
================

.. contents::
:local:
:backlinks: none
:depth: 1

Overview
--------

The Influx connector allows querying data-points stored in an
`InfluxDB <https://www.influxdata.com/products/influxdb-overview/>`_
Time Series Database.

Configuration
-------------

The following configuration properties are available:

================================================== ======================================================================
Property Name Description
================================================== ======================================================================
``connector.name=influx``
``influx.host=`` Default localhost
``influx.port=`` Default 8086
``influx.use-https=`` Default false
``influx.database=`` The database name must be specified. Each instance of the connector
can only connect to a single database on a server
``influx.username=``
``influx.password=``
``influx.cache-meta-data-millis=`` How long to cache schema info e.g. measurement names before refreshing
================================================== ======================================================================

Limitations
-----------

* Only SELECT queries are supported
* InfluxDB has case-sensitive identifiers, whereas prestosql is case-insenstive. The influx connector will report an error
if two identifiers differ only in case, and therefore are ambiguous
* authentication and https support is untested
* LDAP on InfluxDB Enterprise editions is not supported
124 changes: 124 additions & 0 deletions presto-influx/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<parent>
<artifactId>presto-root</artifactId>
<groupId>io.prestosql</groupId>
<version>327-SNAPSHOT</version>
williame marked this conversation as resolved.
Show resolved Hide resolved
</parent>

<artifactId>presto-influx</artifactId>
<description>Presto - Influx Connector</description>
<packaging>presto-plugin</packaging>

<properties>
<air.main.basedir>${project.parent.basedir}</air.main.basedir>
</properties>

<dependencies>
<dependency>
<groupId>io.airlift</groupId>
<artifactId>bootstrap</artifactId>
</dependency>

<dependency>
<groupId>io.airlift</groupId>
<artifactId>configuration</artifactId>
</dependency>

<dependency>
<groupId>io.airlift</groupId>
<artifactId>json</artifactId>
</dependency>

<dependency>
<groupId>io.airlift</groupId>
<artifactId>log</artifactId>
</dependency>

<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</dependency>

<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
</dependency>

<dependency>
<groupId>javax.inject</groupId>
<artifactId>javax.inject</artifactId>
</dependency>

<dependency>
<groupId>javax.validation</groupId>
<artifactId>validation-api</artifactId>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>

<!-- Presto SPI -->
<dependency>
<groupId>io.prestosql</groupId>
<artifactId>presto-spi</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>io.airlift</groupId>
<artifactId>slice</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
<groupId>org.openjdk.jol</groupId>
<artifactId>jol-core</artifactId>
<scope>provided</scope>
</dependency>

<!-- for testing -->
<dependency>
<groupId>io.prestosql</groupId>
<artifactId>presto-main</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.testng</groupId>
<artifactId>testng</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>io.prestosql</groupId>
<artifactId>presto-testing</artifactId>
<scope>test</scope>
</dependency>

<dependency>
<groupId>io.airlift</groupId>
<artifactId>testing</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

</project>
Loading