Skip to content

Commit 8908a67

Browse files
committed
Merge branch 'refs/heads/UserDefinedTime' into cyb/time_column
# Conflicts: # iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/schema/table/TsFileTableSchemaUtil.java
2 parents 4fe302e + dedf5b0 commit 8908a67

File tree

182 files changed

+24651
-907
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

182 files changed

+24651
-907
lines changed

.github/workflows/multi-language-client.yml

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
fail-fast: false
4646
max-parallel: 15
4747
matrix:
48-
os: [ubuntu-22.04, ubuntu-24.04, windows-2022, macos-latest]
48+
os: [ubuntu-22.04, ubuntu-24.04, windows-2022, windows-latest, macos-latest]
4949
runs-on: ${{ matrix.os}}
5050

5151
steps:
@@ -56,12 +56,14 @@ jobs:
5656
run: |
5757
sudo apt-get update
5858
sudo apt-get install libboost-all-dev
59+
sudo apt-get install openssl libssl-dev
5960
- name: Install CPP Dependencies (Mac)
6061
# remove some xcode to release disk space
6162
if: runner.os == 'macOS'
6263
shell: bash
6364
run: |
6465
brew install boost
66+
brew install openssl
6567
sudo rm -rf /Applications/Xcode_14.3.1.app
6668
sudo rm -rf /Applications/Xcode_15.0.1.app
6769
sudo rm -rf /Applications/Xcode_15.1.app
@@ -74,6 +76,11 @@ jobs:
7476
choco install boost-msvc-14.3
7577
$boost_path = (Get-ChildItem -Path 'C:\local\' -Filter 'boost_*').FullName
7678
echo $boost_path >> $env:GITHUB_PATH
79+
80+
choco install openssl
81+
$sslPath = (Get-ChildItem 'C:\Program Files\OpenSSL*' -Directory | Select-Object -First 1).FullName
82+
echo "$sslPath\bin" >> $env:GITHUB_PATH
83+
echo "OPENSSL_ROOT_DIR=$sslPath" >> $env:GITHUB_ENV
7784
- name: Cache Maven packages
7885
uses: actions/cache@v4
7986
with:
@@ -89,11 +96,7 @@ jobs:
8996
# Explicitly using "install" instead of package in order to be sure we're using libs built on this machine
9097
# (was causing problems on windows, but could cause problem on linux, when updating the thrift module)
9198
run: |
92-
if [[ "$RUNNER_OS" == "Linux" ]]; then
93-
./mvnw clean verify -P with-cpp -pl iotdb-client/client-cpp,example/client-cpp-example -am -Diotdb-tools-thrift.version=0.14.1.1-glibc223-SNAPSHOT
94-
else
95-
./mvnw clean verify -P with-cpp -pl iotdb-client/client-cpp,example/client-cpp-example -am
96-
fi
99+
./mvnw clean verify -P with-cpp -pl iotdb-client/client-cpp,example/client-cpp-example -am
97100
- name: Upload Artifact
98101
if: failure()
99102
uses: actions/upload-artifact@v4

distribution/pom.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@
5353
<artifactId>library-udf</artifactId>
5454
<version>2.0.7-SNAPSHOT</version>
5555
</dependency>
56+
<dependency>
57+
<groupId>org.apache.iotdb</groupId>
58+
<artifactId>mqtt</artifactId>
59+
<version>2.0.7-SNAPSHOT</version>
60+
<scope>provided</scope>
61+
</dependency>
5662
</dependencies>
5763
<build>
5864
<plugins>
@@ -74,6 +80,7 @@
7480
<descriptor>src/assembly/confignode.xml</descriptor>
7581
<descriptor>src/assembly/cli.xml</descriptor>
7682
<descriptor>src/assembly/library-udf.xml</descriptor>
83+
<descriptor>src/assembly/external-service-impl.xml</descriptor>
7784
</descriptors>
7885
<finalName>apache-iotdb-${project.version}</finalName>
7986
</configuration>
@@ -107,6 +114,7 @@
107114
<include>apache-iotdb-${project.version}-cli-bin.zip</include>
108115
<include>apache-iotdb-${project.version}-confignode-bin.zip</include>
109116
<include>apache-iotdb-${project.version}-library-udf-bin.zip</include>
117+
<include>apache-iotdb-${project.version}-external-service-impl-bin.zip</include>
110118
</includes>
111119
</fileSet>
112120
</fileSets>

distribution/src/assembly/all.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,10 @@
9292
<outputDirectory>conf</outputDirectory>
9393
<fileMode>0755</fileMode>
9494
</file>
95+
<file>
96+
<source>${maven.multiModuleProjectDirectory}/external-service-impl/mqtt/target/mqtt-${project.version}-jar-with-dependencies.jar</source>
97+
<outputDirectory>lib</outputDirectory>
98+
</file>
9599
</files>
96100
<componentDescriptors>
97101
<componentDescriptor>common-files.xml</componentDescriptor>

distribution/src/assembly/datanode.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,12 @@
7474
<fileMode>0755</fileMode>
7575
</fileSet>
7676
</fileSets>
77+
<files>
78+
<file>
79+
<source>${maven.multiModuleProjectDirectory}/external-service-impl/mqtt/target/mqtt-${project.version}-jar-with-dependencies.jar</source>
80+
<outputDirectory>lib</outputDirectory>
81+
</file>
82+
</files>
7783
<componentDescriptors>
7884
<componentDescriptor>common-files.xml</componentDescriptor>
7985
</componentDescriptors>
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
4+
Licensed to the Apache Software Foundation (ASF) under one
5+
or more contributor license agreements. See the NOTICE file
6+
distributed with this work for additional information
7+
regarding copyright ownership. The ASF licenses this file
8+
to you under the Apache License, Version 2.0 (the
9+
"License"); you may not use this file except in compliance
10+
with the License. You may obtain a copy of the License at
11+
12+
http://www.apache.org/licenses/LICENSE-2.0
13+
14+
Unless required by applicable law or agreed to in writing,
15+
software distributed under the License is distributed on an
16+
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17+
KIND, either express or implied. See the License for the
18+
specific language governing permissions and limitations
19+
under the License.
20+
21+
-->
22+
<assembly>
23+
<id>external-service-impl-bin</id>
24+
<formats>
25+
<format>dir</format>
26+
<format>zip</format>
27+
</formats>
28+
<baseDirectory>apache-iotdb-${project.version}-external-service-impl-bin</baseDirectory>
29+
<fileSets>
30+
<fileSet>
31+
<directory>${project.basedir}/../licenses</directory>
32+
<outputDirectory>licenses</outputDirectory>
33+
</fileSet>
34+
</fileSets>
35+
<files>
36+
<file>
37+
<source>${project.basedir}/../LICENSE-binary</source>
38+
<outputDirectory>licenses</outputDirectory>
39+
<destName>LICENSE</destName>
40+
</file>
41+
<file>
42+
<source>${project.basedir}/../NOTICE-binary</source>
43+
<outputDirectory>licenses</outputDirectory>
44+
<destName>NOTICE</destName>
45+
</file>
46+
<file>
47+
<source>${maven.multiModuleProjectDirectory}/external-service-impl/mqtt/target/mqtt-${project.version}-jar-with-dependencies.jar</source>
48+
<outputDirectory>/</outputDirectory>
49+
</file>
50+
</files>
51+
</assembly>

docker/src/main/Dockerfile-1c1d

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,7 @@ RUN apt update \
3434
&& sed -i 's/cn_internal_address=127.0.0.1/cn_internal_address=0.0.0.0/g' /iotdb/conf/iotdb-system.properties \
3535
&& sed -i 's/cn_seed_config_node=127.0.0.1:10710/cn_seed_config_node=0.0.0.0:10710/g' /iotdb/conf/iotdb-system.properties \
3636
&& sed -i 's/dn_seed_config_node=127.0.0.1:10710/dn_seed_config_node=0.0.0.0:10710/g' /iotdb/conf/iotdb-system.properties \
37-
&& sed -i 's/# config_node_consensus_protocol_class=org.apache.iotdb.consensus.ratis.RatisConsensus/config_node_consensus_protocol_class=org.apache.iotdb.consensus.simple.SimpleConsensus/g' /iotdb/conf/iotdb-system.properties \
38-
&& sed -i 's/# schema_region_consensus_protocol_class=org.apache.iotdb.consensus.ratis.RatisConsensus/schema_region_consensus_protocol_class=org.apache.iotdb.consensus.simple.SimpleConsensus/g' /iotdb/conf/iotdb-system.properties \
39-
&& sed -i 's/# data_region_consensus_protocol_class=org.apache.iotdb.consensus.iot.IoTConsensus/data_region_consensus_protocol_class=org.apache.iotdb.consensus.simple.SimpleConsensus/g' /iotdb/conf/iotdb-system.properties \
37+
&& sed -i 's/dn_rpc_address=127.0.0.1/dn_rpc_address=0.0.0.0/g' /iotdb/conf/iotdb-system.properties \
4038
&& apt remove unzip -y \
4139
&& apt autoremove -y \
4240
&& apt purge --auto-remove -y \

example/client-cpp-example/src/CMakeLists.txt

Lines changed: 56 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,14 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/thrift/include)
2828
# Add cpp-client include directory
2929
INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/client/include)
3030

31+
FIND_PACKAGE(OpenSSL REQUIRED)
32+
IF(OpenSSL_FOUND)
33+
MESSAGE(STATUS "OpenSSL found: ${OPENSSL_VERSION}")
34+
INCLUDE_DIRECTORIES(${OPENSSL_INCLUDE_DIR})
35+
ELSE()
36+
MESSAGE(FATAL_ERROR "OpenSSL not found")
37+
ENDIF()
38+
3139
FIND_PACKAGE(Boost REQUIRED)
3240
IF (DEFINED BOOST_INCLUDEDIR)
3341
INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIR})
@@ -42,13 +50,53 @@ ADD_EXECUTABLE(TableModelSessionExample TableModelSessionExample.cpp)
4250
ADD_EXECUTABLE(MultiSvrNodeClient MultiSvrNodeClient.cpp)
4351

4452
IF(MSVC)
45-
TARGET_LINK_LIBRARIES(SessionExample iotdb_session "${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib")
46-
TARGET_LINK_LIBRARIES(AlignedTimeseriesSessionExample iotdb_session "${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib")
47-
TARGET_LINK_LIBRARIES(TableModelSessionExample iotdb_session "${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib")
48-
TARGET_LINK_LIBRARIES(MultiSvrNodeClient iotdb_session "${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib")
53+
TARGET_LINK_LIBRARIES(SessionExample
54+
iotdb_session
55+
"${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib"
56+
OpenSSL::SSL
57+
OpenSSL::Crypto
58+
)
59+
TARGET_LINK_LIBRARIES(AlignedTimeseriesSessionExample
60+
iotdb_session
61+
"${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib"
62+
OpenSSL::SSL
63+
OpenSSL::Crypto
64+
)
65+
TARGET_LINK_LIBRARIES(TableModelSessionExample
66+
iotdb_session
67+
"${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib"
68+
OpenSSL::SSL
69+
OpenSSL::Crypto
70+
)
71+
TARGET_LINK_LIBRARIES(MultiSvrNodeClient
72+
iotdb_session
73+
"${CMAKE_SOURCE_DIR}/thrift/lib/Release/thriftmd.lib"
74+
OpenSSL::SSL
75+
OpenSSL::Crypto
76+
)
4977
ELSE()
50-
TARGET_LINK_LIBRARIES(SessionExample iotdb_session pthread)
51-
TARGET_LINK_LIBRARIES(AlignedTimeseriesSessionExample iotdb_session pthread)
52-
TARGET_LINK_LIBRARIES(TableModelSessionExample iotdb_session pthread)
53-
TARGET_LINK_LIBRARIES(MultiSvrNodeClient iotdb_session pthread)
78+
TARGET_LINK_LIBRARIES(SessionExample
79+
iotdb_session
80+
pthread
81+
OpenSSL::SSL
82+
OpenSSL::Crypto
83+
)
84+
TARGET_LINK_LIBRARIES(AlignedTimeseriesSessionExample
85+
iotdb_session
86+
pthread
87+
OpenSSL::SSL
88+
OpenSSL::Crypto
89+
)
90+
TARGET_LINK_LIBRARIES(TableModelSessionExample
91+
iotdb_session
92+
pthread
93+
OpenSSL::SSL
94+
OpenSSL::Crypto
95+
)
96+
TARGET_LINK_LIBRARIES(MultiSvrNodeClient
97+
iotdb_session
98+
pthread
99+
OpenSSL::SSL
100+
OpenSSL::Crypto
101+
)
54102
ENDIF()

example/mqtt-customize/pom.xml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,11 @@
2929
<artifactId>customize-mqtt-example</artifactId>
3030
<name>IoTDB: Example: Customized MQTT</name>
3131
<dependencies>
32-
<!-- used by the server-->
32+
<dependency>
33+
<groupId>org.apache.iotdb</groupId>
34+
<artifactId>mqtt</artifactId>
35+
<version>${project.version}</version>
36+
</dependency>
3337
<dependency>
3438
<groupId>org.apache.iotdb</groupId>
3539
<artifactId>iotdb-server</artifactId>

example/mqtt-customize/src/main/java/org/apache/iotdb/mqtt/server/CustomizedJsonPayloadFormatter.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@
1919

2020
package org.apache.iotdb.mqtt.server;
2121

22-
import org.apache.iotdb.db.protocol.mqtt.Message;
23-
import org.apache.iotdb.db.protocol.mqtt.PayloadFormatter;
24-
import org.apache.iotdb.db.protocol.mqtt.TreeMessage;
22+
import org.apache.iotdb.mqtt.Message;
23+
import org.apache.iotdb.mqtt.PayloadFormatter;
24+
import org.apache.iotdb.mqtt.TreeMessage;
2525

2626
import io.netty.buffer.ByteBuf;
2727
import org.apache.tsfile.external.commons.lang3.NotImplementedException;

example/mqtt-customize/src/main/resources/META-INF/services/org.apache.iotdb.db.protocol.mqtt.PayloadFormatter renamed to example/mqtt-customize/src/main/resources/META-INF/services/org.apache.iotdb.PayloadFormatter

File renamed without changes.

0 commit comments

Comments
 (0)