Skip to content

Commit 2c8ad4c

Browse files
authored
Merge pull request #90 from bonitoo-io/fix/query-bool
fix: proper flux boolean data name
2 parents 8ae8afb + 31859bb commit 2c8ad4c

File tree

4 files changed

+10
-7
lines changed

4 files changed

+10
-7
lines changed

CHANGELOG.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
11
# Changelog
22
## Version 3.4.0 (in progres)
33
### Features
4-
- [#88](https://github.com/tobiasschuerg/InfluxDB-Client-for-Arduino/pull/88) - ESP8266 only - Added Max Fragment Length Negotiation for TLS communicaton to reduce memory allocation. If server supports MFLN, it saves ~15kB. Standalone InfluxDB OSS server doesn't support MFLN, Cloud yes. To leverage MFLN for standalone OSS, a reverse proxy needs to be used.
4+
- [#89](https://github.com/tobiasschuerg/InfluxDB-Client-for-Arduino/pull/89) - ESP8266 only - Added Max Fragment Length Negotiation for TLS communicaton to reduce memory allocation. If server supports MFLN, it saves ~15kB. Standalone InfluxDB OSS server doesn't support MFLN, Cloud yes. To leverage MFLN for standalone OSS, a reverse proxy needs to be used.
55

6-
### Documentation
6+
### Documentation
77
- [#87](https://github.com/tobiasschuerg/InfluxDB-Client-for-Arduino/pull/87) - Fixed include file name in the Readme
88

9+
### Fixes
10+
- [#90](https://github.com/tobiasschuerg/InfluxDB-Client-for-Arduino/pull/90) - Fixed boolean type recognition of InfluxDB Flux
11+
912
## Version 3.3.0 (2020-07-07)
1013
- [NEW] Added possibility skip server certification validation (`setInsecure()` method)
1114
- [NEW] Added possibility to query flux on secured InfuxDB 1.8 using V1 approach

src/query/FluxTypes.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030
const char *FluxDatatypeString = "string";
3131
const char *FluxDatatypeDouble = "double";
32-
const char *FluxDatatypeBool = "bool";
32+
const char *FluxDatatypeBool = "boolean";
3333
const char *FluxDatatypeLong = "long";
3434
const char *FluxDatatypeUnsignedLong = "unsignedLong";
3535
const char *FluxDatatypeDuration = "duration";

test/server/server.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ var queryRes = {
174174
,_result1,1,2020-02-16T22:19:49.747562847Z,2020-02-17T22:19:49.747562847Z,2020-02-17T10:34:08.135814545Z,-4,i,test,1,adsfasdf
175175
,_result1,1,2020-02-16T22:19:49.747562847Z,2020-02-17T22:19:49.747562847Z,2020-02-16T22:08:44.850214724Z,-1,i,test,1,adsfasdf
176176
\r
177-
#datatype,string,long,dateTime:RFC3339,dateTime:RFC3339,dateTime:RFC3339,bool,string,string,string,string
177+
#datatype,string,long,dateTime:RFC3339,dateTime:RFC3339,dateTime:RFC3339,boolean,string,string,string,string
178178
,result,table,_start,_stop,_time,_value,_field,_measurement,a,b
179179
,_result2,2,2020-02-17T22:19:49.747562847Z,2020-02-18T22:19:49.747562847Z,2020-02-18T10:34:08.135814545Z,false,b,test,0,brtfgh
180180
,_result2,2,2020-02-17T22:19:49.747562847Z,2020-02-18T22:19:49.747562847Z,2020-02-18T22:08:44.969100374Z,true,b,test,0,brtfgh

test/test.ino

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1316,12 +1316,12 @@ void testFluxParserMultiTables(bool chunked) {
13161316
TEST_ASSERT(testStringValue(flux, 9, "b", "adsfasdf"));
13171317

13181318

1319-
TEST_ASSERTM(flux.next(),"flux.next()");
1320-
TEST_ASSERTM(flux.hasTableChanged(),"flux.hasTableChanged()");
1319+
TEST_ASSERTM(flux.next(),flux.getError());
1320+
TEST_ASSERTM(flux.hasTableChanged(),flux.getError());
13211321
TEST_ASSERTM(flux.getError() == "",flux.getError());
13221322

13231323
// ===== table 3 =================
1324-
const char *types3[] = {"string","long", "dateTime:RFC3339", "dateTime:RFC3339", "dateTime:RFC3339", "bool", "string","string","string","string"};
1324+
const char *types3[] = {"string","long", "dateTime:RFC3339", "dateTime:RFC3339", "dateTime:RFC3339", "boolean", "string","string","string","string"};
13251325
TEST_ASSERT(testStringVector(flux.getColumnsDatatype(), types3, 10));
13261326
TEST_ASSERT(testTableColumns(flux, columns, 10));
13271327
// ========== row 1 ================

0 commit comments

Comments
 (0)