From a92970a9047c72a1181a8f3b7f2bac15344825f2 Mon Sep 17 00:00:00 2001
From: k32 <10274441+k32@users.noreply.github.com>
Date: Tue, 30 Nov 2021 11:44:15 +0100
Subject: [PATCH 1/2] feat(mria): Add RPC-related configuration to the schema
---
apps/emqx_conf/src/emqx_conf_schema.erl | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/apps/emqx_conf/src/emqx_conf_schema.erl b/apps/emqx_conf/src/emqx_conf_schema.erl
index d8bb2423b..bd897d730 100644
--- a/apps/emqx_conf/src/emqx_conf_schema.erl
+++ b/apps/emqx_conf/src/emqx_conf_schema.erl
@@ -347,6 +347,27 @@ to rlog
.
List of core nodes that the replicant will connect to.
Note: this parameter only takes effect when the backend
is set
to rlog
and the role
is set to replicant
.
+"""
+ })}
+ , {"rpc_module",
+ sc(hoconsc:enum([gen_rpc, rpc]),
+ #{ mapping => "mria.rlog_rpc_module"
+ , default => gen_rpc
+ , desc => """
+Protocol used for pushing transaction logs to the replicant nodes.
+Important! This setting should be the same on all nodes in the cluster.
+Important! Changing this setting in the runtime is not allowed.
+"""
+ })}
+ , {"tlog_push_mode",
+ sc(hoconsc:enum([sync, async]),
+ #{ mapping => "mria.tlog_push_mode"
+ , default => sync
+ , desc => """
+In sync mode the core node waits for an ack from the replicant nodes before sending the next
+transaction log entry.
+Important! This setting should be the same on all nodes in the cluster.
+Important! Changing this setting in the runtime is not allowed.
"""
})}
];
From 2ceb660344215df48f20300918ae5cbbfbabb3f4 Mon Sep 17 00:00:00 2001
From: k32 <10274441+k32@users.noreply.github.com>
Date: Tue, 30 Nov 2021 22:06:33 +0100
Subject: [PATCH 2/2] chore(mria): Bump version to 0.1.4
---
apps/emqx_conf/src/emqx_conf_schema.erl | 6 +-----
rebar.config | 2 +-
2 files changed, 2 insertions(+), 6 deletions(-)
diff --git a/apps/emqx_conf/src/emqx_conf_schema.erl b/apps/emqx_conf/src/emqx_conf_schema.erl
index bd897d730..91ef5d812 100644
--- a/apps/emqx_conf/src/emqx_conf_schema.erl
+++ b/apps/emqx_conf/src/emqx_conf_schema.erl
@@ -355,19 +355,15 @@ to rlog
and the role
is set to replicant
.
, default => gen_rpc
, desc => """
Protocol used for pushing transaction logs to the replicant nodes.
-Important! This setting should be the same on all nodes in the cluster.
-Important! Changing this setting in the runtime is not allowed.
"""
})}
, {"tlog_push_mode",
sc(hoconsc:enum([sync, async]),
#{ mapping => "mria.tlog_push_mode"
- , default => sync
+ , default => async
, desc => """
In sync mode the core node waits for an ack from the replicant nodes before sending the next
transaction log entry.
-Important! This setting should be the same on all nodes in the cluster.
-Important! Changing this setting in the runtime is not allowed.
"""
})}
];
diff --git a/rebar.config b/rebar.config
index 9e7aba87c..4fbf1b136 100644
--- a/rebar.config
+++ b/rebar.config
@@ -52,7 +52,7 @@
, {jiffy, {git, "https://github.com/emqx/jiffy", {tag, "1.0.5"}}}
, {cowboy, {git, "https://github.com/emqx/cowboy", {tag, "2.8.3"}}}
, {esockd, {git, "https://github.com/emqx/esockd", {tag, "5.9.0"}}}
- , {mria, {git, "https://github.com/emqx/mria", {tag, "0.1.3"}}}
+ , {mria, {git, "https://github.com/emqx/mria", {tag, "0.1.4"}}}
, {ekka, {git, "https://github.com/emqx/ekka", {tag, "0.11.1"}}}
, {gen_rpc, {git, "https://github.com/emqx/gen_rpc", {tag, "2.5.1"}}}
, {minirest, {git, "https://github.com/emqx/minirest", {tag, "1.2.7"}}}