This is an automated email from the ASF dual-hosted git repository.
lta pushed a commit to branch cluster_akka
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git
The following commit(s) were added to refs/heads/cluster_akka by this push:
new dd06b9a modify ASF header and main class
dd06b9a is described below
commit dd06b9ae088f8159215a0db67ac8e01845b58dd0
Author: lta <[email protected]>
AuthorDate: Mon Mar 4 15:35:40 2019 +0800
modify ASF header and main class
---
iotdb/iotdb/bin/start-server.bat | 2 +-
iotdb/iotdb/bin/start-server.sh | 2 +-
iotdb/iotdb/conf/iotdb_cluster.properties | 6 ++++++
iotdb/pom.xml | 10 ----------
.../org/apache/iotdb/db/cluster/IoTDBCluster.java | 22 +++++++++++++---------
.../org/apache/iotdb/db/cluster/IoTDBNode.java | 22 +++++++++++++---------
.../org/apache/iotdb/db/conf/IoTDBDescriptor.java | 2 +-
7 files changed, 35 insertions(+), 31 deletions(-)
diff --git a/iotdb/iotdb/bin/start-server.bat b/iotdb/iotdb/bin/start-server.bat
index 2077797..1b308ac 100755
--- a/iotdb/iotdb/bin/start-server.bat
+++ b/iotdb/iotdb/bin/start-server.bat
@@ -63,7 +63,7 @@ IF EXIST "%IOTDB_CONF%\iotdb-env.bat" (
echo "can't find %IOTDB_CONF%\iotdb-env.bat"
)
-if NOT DEFINED MAIN_CLASS set MAIN_CLASS=org.apache.iotdb.db.service.IoTDB
+if NOT DEFINED MAIN_CLASS set
MAIN_CLASS=org.apache.iotdb.db.cluster.IoTDBCluster
if NOT DEFINED JAVA_HOME goto :err
@REM
-----------------------------------------------------------------------------
diff --git a/iotdb/iotdb/bin/start-server.sh b/iotdb/iotdb/bin/start-server.sh
index e9e46ad..ba16235 100755
--- a/iotdb/iotdb/bin/start-server.sh
+++ b/iotdb/iotdb/bin/start-server.sh
@@ -56,7 +56,7 @@ CLASSPATH=""
for f in ${IOTDB_HOME}/lib/*.jar; do
CLASSPATH=${CLASSPATH}":"$f
done
-classname=org.apache.iotdb.db.service.IoTDB
+classname=org.apache.iotdb.db.cluster.IoTDBCluster
launch_service()
{
diff --git a/iotdb/iotdb/conf/iotdb_cluster.properties
b/iotdb/iotdb/conf/iotdb_cluster.properties
index 23317cf..4f57d3b 100644
--- a/iotdb/iotdb/conf/iotdb_cluster.properties
+++ b/iotdb/iotdb/conf/iotdb_cluster.properties
@@ -27,6 +27,8 @@ akka {
}
artery {
+ # change this to enabled=on to use Artery instead of netty
+ # see https://doc.akka.io/docs/akka/current/remoting-artery.html
enabled = off
transport = tcp
canonical.hostname = "127.0.0.1"
@@ -35,9 +37,13 @@ akka {
}
cluster {
+ # Note - Artery uses akka:// addresses
seed-nodes = [
"akka.tcp://[email protected]:2552",
"akka.tcp://[email protected]:2551"]
+
+ # auto downing is NOT safe for production deployments.
+ # you may want to use it during development, read more about it in the
docs.
auto-down-unreachable-after = 10s
}
}
diff --git a/iotdb/pom.xml b/iotdb/pom.xml
index 0c206d1..7244404 100644
--- a/iotdb/pom.xml
+++ b/iotdb/pom.xml
@@ -81,16 +81,6 @@
<artifactId>akka-cluster-metrics_2.12</artifactId>
<version>${akka.version}</version>
</dependency>
- <dependency>
- <groupId>com.typesafe.akka</groupId>
- <artifactId>akka-protobuf_2.11</artifactId>
- <version>${akka.version}</version>
- </dependency>
- <dependency>
- <groupId>com.typesafe.akka</groupId>
- <artifactId>akka-stream_2.11</artifactId>
- <version>${akka.version}</version>
- </dependency>
</dependencies>
<build>
<plugins>
diff --git a/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBCluster.java
b/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBCluster.java
index ade9c87..b169990 100644
--- a/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBCluster.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBCluster.java
@@ -1,15 +1,19 @@
/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
contributor license
- * agreements. See the NOTICE file distributed with this work for additional
information regarding
- * copyright ownership. The ASF licenses this file to you under the Apache
License, Version 2.0
- * (the "License"); you may not use this file except in compliance with the
License. You may obtain
- * a copy of the License at
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * Unless required by applicable law or agreed to in writing, software
distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express
- * or implied. See the License for the specific language governing
permissions and limitations
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
* under the License.
*/
package org.apache.iotdb.db.cluster;
diff --git a/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBNode.java
b/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBNode.java
index 4526ab0..4186daa 100644
--- a/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBNode.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/cluster/IoTDBNode.java
@@ -1,15 +1,19 @@
/**
- * Licensed to the Apache Software Foundation (ASF) under one or more
contributor license
- * agreements. See the NOTICE file distributed with this work for additional
information regarding
- * copyright ownership. The ASF licenses this file to you under the Apache
License, Version 2.0
- * (the "License"); you may not use this file except in compliance with the
License. You may obtain
- * a copy of the License at
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
*
- * http://www.apache.org/licenses/LICENSE-2.0
+ * http://www.apache.org/licenses/LICENSE-2.0
*
- * Unless required by applicable law or agreed to in writing, software
distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express
- * or implied. See the License for the specific language governing
permissions and limitations
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
* under the License.
*/
package org.apache.iotdb.db.cluster;
diff --git a/iotdb/src/main/java/org/apache/iotdb/db/conf/IoTDBDescriptor.java
b/iotdb/src/main/java/org/apache/iotdb/db/conf/IoTDBDescriptor.java
index f23a122..933475f 100644
--- a/iotdb/src/main/java/org/apache/iotdb/db/conf/IoTDBDescriptor.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/conf/IoTDBDescriptor.java
@@ -79,7 +79,7 @@ public class IoTDBDescriptor {
return;
}
- conf.clusterConfig = ConfigFactory.parseFile(new File(url,
IoTDBConstant.CLUSTER_CONFIG));
+ conf.clusterConfig = ConfigFactory.parseFile(new File(new
File(url).getParent(), IoTDBConstant.CLUSTER_CONFIG));
LOGGER.info("Start to read config file {}", url);
Properties properties = new Properties();