This is an automated email from the ASF dual-hosted git repository.
dimuthuupe pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/airavata-mft.git
The following commit(s) were added to refs/heads/master by this push:
new cae3db4 Ability start the agent through standalone service
cae3db4 is described below
commit cae3db4e82e34ea0bdc1efddf92f9b691d33cb06
Author: DImuthuUpe <[email protected]>
AuthorDate: Wed Jul 19 15:51:32 2023 -0400
Ability start the agent through standalone service
---
.../standalone/server/AgentServiceApplication.java | 28 ++++++++++++++++++++++
.../src/main/resources/application.properties | 4 ++++
.../distribution/bin/standalone-service-daemon.sh | 12 ++++++++++
.../distribution/conf/application.properties | 4 ++++
4 files changed, 48 insertions(+)
diff --git
a/standalone-service/src/main/java/org/apache/airavata/mft/standalone/server/AgentServiceApplication.java
b/standalone-service/src/main/java/org/apache/airavata/mft/standalone/server/AgentServiceApplication.java
new file mode 100644
index 0000000..fbb2754
--- /dev/null
+++
b/standalone-service/src/main/java/org/apache/airavata/mft/standalone/server/AgentServiceApplication.java
@@ -0,0 +1,28 @@
+/*
+ * 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
+ *
+ * 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.airavata.mft.standalone.server;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.context.annotation.ComponentScan;
+
+@ComponentScan(basePackages = {"org.apache.airavata.mft.agent"})
+public class AgentServiceApplication {
+ public static void main(String[] args) {
+ SpringApplication.run(AgentServiceApplication.class, args);
+ }
+}
diff --git a/standalone-service/src/main/resources/application.properties
b/standalone-service/src/main/resources/application.properties
index 91e8595..fea9489 100644
--- a/standalone-service/src/main/resources/application.properties
+++ b/standalone-service/src/main/resources/application.properties
@@ -26,4 +26,8 @@ resource.service.port=7003
secret.service.host=localhost
secret.service.port=7003
agent.id=local-agent
+agent.concurrent.transfers=8
+agent.concurrent.chunked.threads=20
+agent.chunk.size=10
+agent.chunk.streaming.enabled=true
agent.transport.directory=plugins
\ No newline at end of file
diff --git
a/standalone-service/src/main/resources/distribution/bin/standalone-service-daemon.sh
b/standalone-service/src/main/resources/distribution/bin/standalone-service-daemon.sh
index 5bd7322..425f0f0 100644
---
a/standalone-service/src/main/resources/distribution/bin/standalone-service-daemon.sh
+++
b/standalone-service/src/main/resources/distribution/bin/standalone-service-daemon.sh
@@ -48,6 +48,17 @@ case $1 in
echo "$SERVICE_NAME is already running ..."
fi
;;
+ start-agent)
+ echo "Starting MFT Agent ..."
+ if [ ! -f $PID_PATH_NAME ]; then
+ nohup java ${JAVA_OPTS} -classpath "${AIRAVATA_CLASSPATH}" \
+ org.apache.airavata.mft.standalone.server.AgentServiceApplication
${AIRAVATA_COMMAND} $* > $LOG_FILE 2>&1 &
+ echo $! > $PID_PATH_NAME
+ echo "MFT Agent started ..."
+ else
+ echo "MFT Agent is already running ..."
+ fi
+ ;;
stop)
if [ -f $PID_PATH_NAME ]; then
PID=$(cat $PID_PATH_NAME);
@@ -102,6 +113,7 @@ case $1 in
echo "command options:"
echo " start Start server in daemon mode"
+ echo " start-agent Start MFT Agent in daemon mode"
echo " stop Stop server running in daemon mode"
echo " restart Restart server in daemon mode"
echo " -log <LOG_FILE> Where to redirect stdout/stderr
(defaults to $DEFAULT_LOG_FILE)"
diff --git
a/standalone-service/src/main/resources/distribution/conf/application.properties
b/standalone-service/src/main/resources/distribution/conf/application.properties
index 91a37e7..5eaaf45 100644
---
a/standalone-service/src/main/resources/distribution/conf/application.properties
+++
b/standalone-service/src/main/resources/distribution/conf/application.properties
@@ -26,4 +26,8 @@ resource.service.port=7003
secret.service.host=localhost
secret.service.port=7003
agent.id=local-agent
+agent.concurrent.transfers=8
+agent.concurrent.chunked.threads=20
+agent.chunk.size=10
+agent.chunk.streaming.enabled=true
agent.transport.directory=${AIRAVATA_HOME}/plugins
\ No newline at end of file