From d7bbfc377fdf22b65a9555b768bcb284b9408b23 Mon Sep 17 00:00:00 2001 From: Amalka Subasinghe Date: Sat, 18 Mar 2023 00:17:59 +0530 Subject: [PATCH 1/3] deploying emqx jars to iot-community --- p2-profile/iot/pom.xml | 43 ++++++++++++++++++++++++++++++++++++++++++ pom.xml | 2 +- 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/p2-profile/iot/pom.xml b/p2-profile/iot/pom.xml index 3a74a5b..214de54 100644 --- a/p2-profile/iot/pom.xml +++ b/p2-profile/iot/pom.xml @@ -57,6 +57,49 @@ + + copy-emqx-exhook + test + + copy + + + + + org.wso2.carbon.devicemgt-plugins + io.entgra.device.mgt.plugins.emqx.exhook + ${carbon.device.mgt.plugin.version} + jar + true + jar-with-dependencies + ${project.basedir}/target/${entgra-iot-core}/repository/components/lib/ + + + false + true + + + + copy-emqx-initializer + test + + copy + + + + + org.wso2.carbon.devicemgt-plugins + io.entgra.device.mgt.plugins.emqx.initializer + ${carbon.device.mgt.plugin.version} + jar + true + ${project.basedir}/target/${entgra-iot-core}/repository/components/dropins/ + + + false + true + + diff --git a/pom.xml b/pom.xml index 6f4851f..81f9518 100644 --- a/pom.xml +++ b/pom.xml @@ -121,7 +121,7 @@ 1.4.199.wso2v1 - 6.0.12-SNAPSHOT + 6.0.13-SNAPSHOT From 24a6e59803ea229faed796ac5dab633f01d9230c Mon Sep 17 00:00:00 2001 From: Amalka Subasinghe Date: Sat, 18 Mar 2023 08:53:17 +0530 Subject: [PATCH 2/3] added input-event-adaptor config and mqtt env vars to iot-server.sh --- iot-core/src/core/bin/iot-server.bat | 1 + iot-core/src/core/bin/iot-server.sh | 2 + .../src/core/conf/input-event-adapters.xml | 56 +++++++++++++++++++ 3 files changed, 59 insertions(+) create mode 100644 iot-core/src/core/conf/input-event-adapters.xml diff --git a/iot-core/src/core/bin/iot-server.bat b/iot-core/src/core/bin/iot-server.bat index bdcde7d..2bee15e 100755 --- a/iot-core/src/core/bin/iot-server.bat +++ b/iot-core/src/core/bin/iot-server.bat @@ -218,6 +218,7 @@ set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dorg.apache.jasper.runtime.BodyContentImpl.LI set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dorg.terracotta.quartz.skipUpdateCheck=true -Dcarbon.classpath=%CARBON_CLASSPATH% -Dfile.encoding=UTF8 -DworkerNode=false -Dcarbon.new.config.dir.path="%CARBON_HOME%\repository\resources\conf" set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Djava.endorsed.dirs=%JAVA_ENDORSED% -Dorg.wso2.ignoreHostnameVerification=true -Dorg.opensaml.httpclient.https.disableHostnameVerification=true -Dhttpclient.hostnameVerifier="DefaultAndLocalhost" set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Diot.core.host="localhost" -Diot.core.https.port="9443" -Diot.core.http.port="9763" -Diot.gateway.host="localhost" -Diot.gateway.https.port="8243" -Diot.gateway.http.port="8280" -Diot.gateway.carbon.https.port="9443" -Diot.gateway.carbon.http.port="9763" -Diot.gateway.websocket.ws.port="9099" -Diot.gateway.websocket.wss.port="8099" -Diot.remotesession.server.host="localhost" -Diot.remotesession.server.https.port="9443" +set CMD_LINE_ARGS=%CMD_LINE_ARGS% -Dmqtt.broker.host="localhost" -Dmqtt.broker.port="1883" :runJava echo JAVA_HOME environment variable is set to %JAVA_HOME% diff --git a/iot-core/src/core/bin/iot-server.sh b/iot-core/src/core/bin/iot-server.sh index 681ea7c..238ba73 100755 --- a/iot-core/src/core/bin/iot-server.sh +++ b/iot-core/src/core/bin/iot-server.sh @@ -370,6 +370,8 @@ do -Diot.remotesession.server.host="localhost" \ -Diot.apim.host="localhost" \ -Diot.apim.https.port="9443" \ + -Dmqtt.broker.host="localhost" \ + -Dmqtt.broker.port="1883" \ -Denable-api-scopes-sharing="true" \ -Dagent-bundle="org.wso2.carbon.emm.mdmagent" \ -Diot.reporting.event.host="" \ diff --git a/iot-core/src/core/conf/input-event-adapters.xml b/iot-core/src/core/conf/input-event-adapters.xml new file mode 100644 index 0000000..25052b2 --- /dev/null +++ b/iot-core/src/core/conf/input-event-adapters.xml @@ -0,0 +1,56 @@ + + + + + + + 8 + 100 + 20000 + 10000 + 60 + https://${iot.keymanager.host}:${iot.keymanager.https.port}/client-registration/v0.17/register + tcp://${mqtt.broker.host}:${mqtt.broker.port} + admin + admin + deviceid-topic-content-validator + true + + + + 8 + 100 + 20000 + 10000 + + + + false + + + + readMails + + + + 20000 + 10000 + + + \ No newline at end of file From bf7fb6098a0182e6e6d120925f9cc987224ca00a Mon Sep 17 00:00:00 2001 From: Amalka Subasinghe Date: Sat, 18 Mar 2023 12:23:19 +0530 Subject: [PATCH 3/3] fixing - inputEventAdaptersConfig copying --- iot-core/src/assembly/bin.xml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/iot-core/src/assembly/bin.xml b/iot-core/src/assembly/bin.xml index 2ac6847..e2f6ca8 100644 --- a/iot-core/src/assembly/bin.xml +++ b/iot-core/src/assembly/bin.xml @@ -88,6 +88,10 @@ src/core/conf/deployment.toml ${entgra-iot-core}/repository/conf/ + + src/core/conf/input-event-adapters.xml + ${entgra-iot-core}/repository/conf/ + src/core/keystores/wso2carbon.jks ${entgra-iot-core}/repository/resources/security/