Comments (6)
Hello @renatomotorline I've just tested , and with a few changes we can use influxdb-srelay as Pass through proxy.
I will upload an update in a few days with this new feature.
from influxdb-srelay.
@nycterent I have a few flux queries working from grafana using srelay.
from influxdb-srelay.
Hello @renatomotorline , we have not added Flux as supported query format yet.
But as described in the following doc https://docs.influxdata.com/flux/v0.65/guides/executing-queries/ , flux queries lives on top of http queries, and could be possible you can use it by changing the uri=["/query"]
parameter by uri=["/api/v2/query"]
if you don't need special routing features and you do a Pass through filter/route rule like
key="u"
match=".*"
If this workaround doesn't work , perhaps a little amount of code could add this new feature.
- Could you test please ?
from influxdb-srelay.
@toni-moreno I already did that and got the error:
influxdb01 | [httpd] 172.27.0.9 - - [27/Apr/2020:11:13:29 +0000] "GET /query HTTP/1.1" 400 45 "-" "influxdb-smart-relay" 1f804bb2-8878-11ea-8154-0242ac1b0004 30
api | fluxQuery error: Error: Request failed with status code 400
My config: https://pastebin.com/1pNuHwyJ
nodejs http request:
axios.post('/query', query,
{
baseURL: `http://${this.host}:${this.port}/api/v2`,
timeout: 1000,
headers: {
'Content-Type': 'application/vnd.flux',
'Accept': 'application/csv'
}
}).then(function (response) {
console.log(`fluxQuery response: ${response.data}`);
return resolve(response.data);
}).catch(function (error) {
console.log(`fluxQuery error: ${error}`);
return reject(error);
});
I converted all flux queries to IQL so is not anymore a problem to me, but someone may need Flux to be supportted in the future. If needed I can do more tests.
from influxdb-srelay.
hello,
what is the status of this? how can we use flux with srelay? :)
from influxdb-srelay.
Well @nycterent there is a pending PR to merge #31 with flux support, @sbengo should review it perhaps a few weeks to merge and release the version.
But you can already to build yourself if you would like to do it
from influxdb-srelay.
Related Issues (20)
- Error sometimes with http: multiple response.WriteHeader calls HOT 1
- Bad status shown in log on Single instance Clusters
- [BUG] Traceroute doesn't contains the backend name on Single Clusters Write Mode
- [Feature Request] Add Real Client IP when sourceIP is a proxy
- [Bug] queryRouterEndpointAPI not working, does not seem to be populated HOT 6
- access logs are piling up continuously HOT 2
- Content length 0 for second route.rule backend HOT 1
- Random Agent Panic
- Http access log is hard-coded to debug. Configuration log-level is useless HOT 18
- How to write data points HOT 6
- Panic while trying to read from second influxdb node while first is down. HOT 5
- Influxdb-srelay and influxdb-python library HOT 1
- Add DROP SERIES in admin endpoint HOT 3
- srelay not compatible with influxdb native interfaces
- [Doc] Example of simple setup - srelay with Prometheus remote config
- No support for v2 write api HOT 3
- Recovering from buffer results in missing and double data HOT 6
- it might be useful to announce the v2 api support more explicitly HOT 2
- help on build config to route on measurements
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from influxdb-srelay.