Add InfluxDB Connector#24220
Conversation
c26a3f8 to
caed040
Compare
|
I'm not sure if the CI fails because of the PR's code or if the tests are flaky ? |
|
|
caed040 to
480d66d
Compare
|
This pull request has gone a while without any activity. Tagging for triage help: @mosabua |
|
Closing this pull request, as it has been stale for six weeks. Feel free to re-open at any time. |
|
Hey @k3rnL Do you know what happened at the end? I will be happy to collaborate with you. I see your connector really interesting. 👍 |
|
A lack of time mostly ! The connector is working well, the problem is to be compliant with the autonomous tests.. |
480d66d to
42a0cb4
Compare
|
@k3rnL Could you please update the pom.xml in (plugin/trino-influxdb) with this version of trino-root snapshot? and try again? 471 471-SNAPSHOT instead of 466-SNAPSHOT and then we will see what happen |
42a0cb4 to
b19ea18
Compare
|
Hi @k3rnL
Really excited to try your InfluxDB connector! I'm eager to collaborate once I have access. Let me know if you need help with these fixes 😊 |
b19ea18 to
e30e1f4
Compare
|
Seems @ebyhr just outperformed us 😁 Thank ! But I see that the merging is blocked because of a merge commit, but it seems this commit comes from the main branch itself. I may be mistaken, but I carefully rebased the code.. |
|
@k3rnL congrats you already passed all the tests. Do you know what is the next step? if not I will ask in the slack channel |
|
Perfect ! That was faster than I thought :) |
ef05025 to
8f110cf
Compare
8f110cf to
8e6dfdc
Compare
k3rnL
left a comment
There was a problem hiding this comment.
I've made the corrections following your comments
|
This pull request has gone a while without any activity. Ask for help on #core-dev on Trino slack. |
|
@ebyhr Is there something more I can do ? |
|
This pull request has gone a while without any activity. Ask for help on #core-dev on Trino slack. |
|
Closing this pull request, as it has been stale for six weeks. Feel free to re-open at any time. |
|
This pull request has gone a while without any activity. Ask for help on #core-dev on Trino slack. |
| } | ||
| } | ||
| catch (Exception e) { | ||
| if (this.dockerContainer != null) { |
There was a problem hiding this comment.
nit: move this.dockerContainer = before try and remove the condition
| } | ||
| catch (Exception e) { | ||
| if (this.dockerContainer != null) { | ||
| this.dockerContainer.close(); |
|
|
||
| public String getEndpoint() | ||
| { | ||
| return this.dockerContainer.getUrl(); |
There was a problem hiding this comment.
this. is redundant, please remove (& elsewhere)
| @AssertFalse(message = "'influx.username' and 'influx.password' must be both empty or both non-empty.") | ||
| public boolean isValidPasswordConfig() | ||
| { | ||
| return (username == null) ^ (password == null); | ||
| } |
There was a problem hiding this comment.
The check seems wrong
| boolean hasCreds = (username != null) || (password != null); | ||
| if (!hasCreds || endpoint == null) { | ||
| return true; | ||
| } | ||
| String scheme = URI.create(endpoint).getScheme(); | ||
| return insecureAllowed || "https".equalsIgnoreCase(scheme); |
There was a problem hiding this comment.
Could you reorder the check like:
if (endpoint == null) {
....
}
// otherwise
...
| { | ||
| InfluxTableHandle tableHandle = (InfluxTableHandle) handle; | ||
| if (client.findTableHandle(tableHandle.schemaName(), tableHandle.tableName()).isEmpty()) { | ||
| throw new TableNotFoundException(tableHandle.toSchemaTableName()); |
There was a problem hiding this comment.
Not sure it is needed, engine should potentially check the case
| public record InfluxRecord(List<String> columns, List<List<Object>> values) | ||
| { | ||
| } |
There was a problem hiding this comment.
| public record InfluxRecord(List<String> columns, List<List<Object>> values) | |
| { | |
| } | |
| public record InfluxRecord(List<String> columns, List<List<Object>> values) | |
| {} |
| if (value instanceof Number number) { | ||
| return number.intValue() != 0; | ||
| } | ||
| return false; |
There was a problem hiding this comment.
is the influxDB says other types value except boolea/number is treated as "false" ?
| if (value instanceof Number number) { | ||
| return number.longValue(); | ||
| } | ||
| return 0; |
There was a problem hiding this comment.
same here, why not throw exception
| } | ||
| else { | ||
| ImmutableList.Builder<String> columns = ImmutableList.builder(); | ||
| List<List<Object>> values = new ArrayList<>(); |
|
This pull request has gone a while without any activity. Ask for help on #core-dev on Trino slack. |
|
Since @colebow is now at InfluxData I am assigning this PR to him. @k3rnL please work with him on addressing the PR feedback and any further discussions here or on Trino slack. I am assuming you will want to drive this PR towards merge and have therefore given it the stale-ignore label to avoid further noise. |
|
Alright, I have not planned to work on it until beginning of the next year, I have no time for it unfortunately. But it will be a pleasure to work with you @colebow in the beginning of 2026. I'm definitely motivated to have this PR closed, time is the only issue :) |
Description
This PR introduces a new connector for InfluxDB, enabling Trino to query time-series data stored in InfluxDB. InfluxDB is a widely used time-series database but diverges from many traditional database standards, requiring a tailored approach to integration.
Additional context and related issues
I must note that most of the work was made in the past, but the PR was never finalized #15549
I have mostly only rebased the code, fixed tests and adapt the code to the new requirements.
My addition is the support for schema creation and schema/table destruction.
Release notes
( ) Release notes are required, with the following suggested text: