You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ro...@apache.org on 2021/09/08 05:01:33 UTC

[cloudstack] branch main updated: packaging: Issue #3974 Deploying mysql-ha jar file into its own path to allow for easy inclusion of just this jar file into multiple packages, such as cloudstack-management and cloudstack-usage. (#3975)

This is an automated email from the ASF dual-hosted git repository.

rohit pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/cloudstack.git


The following commit(s) were added to refs/heads/main by this push:
     new 2bbc781  packaging: Issue #3974 Deploying mysql-ha jar file into its own path to allow for easy inclusion of just this jar file into multiple packages, such as cloudstack-management and cloudstack-usage. (#3975)
2bbc781 is described below

commit 2bbc78170b7d0677bde90f223f5c7601a8be585c
Author: Greg Goodrich <54...@users.noreply.github.com>
AuthorDate: Wed Sep 8 00:01:11 2021 -0500

    packaging: Issue #3974 Deploying mysql-ha jar file into its own path to allow for easy inclusion of just this jar file into multiple packages, such as cloudstack-management and cloudstack-usage. (#3975)
    
    Support for centos7 and centos8
    
    Prior PR #2915 causes the cloudstack-usage daemon to not be able to find the mysql-ha jar file.
    
    This happens because the /etc/default/cloudstack-usage file points to the old location for the mysql-ha jar file, and thus is unable to load it. This prior PR installs this jar into a more common area with other jar files, and thus is not really a desired location for the cloudstack-usage daemon to get it from, as it will cause cloudstack-usage to load other plugins that it doesn't need.
    
    Fixes: #3974
---
 packaging/centos7/cloud.spec                    | 4 ++--
 packaging/centos8/cloud.spec                    | 4 ++--
 packaging/systemd/cloudstack-management.default | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/packaging/centos7/cloud.spec b/packaging/centos7/cloud.spec
index b1b69b7..d8e6de1 100644
--- a/packaging/centos7/cloud.spec
+++ b/packaging/centos7/cloud.spec
@@ -369,7 +369,7 @@ cp -r test/integration/* ${RPM_BUILD_ROOT}%{_datadir}/%{name}-integration-tests/
 # MYSQL HA
 if [ "x%{_ossnoss}" == "xnoredist" ] ; then
   mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/%{name}-mysql-ha/lib
-  cp -r plugins/database/mysql-ha/target/cloud-plugin-database-mysqlha-%{_maventag}.jar ${RPM_BUILD_ROOT}%{_datadir}/%{name}-management/lib
+  cp -r plugins/database/mysql-ha/target/cloud-plugin-database-mysqlha-%{_maventag}.jar ${RPM_BUILD_ROOT}%{_datadir}/%{name}-mysql-ha/lib
 fi
 
 #License files from whisker
@@ -639,7 +639,7 @@ pip3 install --upgrade urllib3
 %if "%{_ossnoss}" == "noredist"
 %files mysql-ha
 %defattr(0644,cloud,cloud,0755)
-%attr(0644,root,root) %{_datadir}/%{name}-management/lib/*mysqlha*jar
+%attr(0644,root,root) %{_datadir}/%{name}-mysql-ha/lib/*
 %endif
 
 %files baremetal-agent
diff --git a/packaging/centos8/cloud.spec b/packaging/centos8/cloud.spec
index 9e62691..eee2fa3 100644
--- a/packaging/centos8/cloud.spec
+++ b/packaging/centos8/cloud.spec
@@ -362,7 +362,7 @@ cp -r test/integration/* ${RPM_BUILD_ROOT}%{_datadir}/%{name}-integration-tests/
 # MYSQL HA
 if [ "x%{_ossnoss}" == "xnoredist" ] ; then
   mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/%{name}-mysql-ha/lib
-  cp -r plugins/database/mysql-ha/target/cloud-plugin-database-mysqlha-%{_maventag}.jar ${RPM_BUILD_ROOT}%{_datadir}/%{name}-management/lib
+  cp -r plugins/database/mysql-ha/target/cloud-plugin-database-mysqlha-%{_maventag}.jar ${RPM_BUILD_ROOT}%{_datadir}/%{name}-mysql-ha/lib
 fi
 
 #License files from whisker
@@ -627,7 +627,7 @@ pip install --upgrade /usr/share/cloudstack-marvin/Marvin-*.tar.gz
 %if "%{_ossnoss}" == "noredist"
 %files mysql-ha
 %defattr(0644,cloud,cloud,0755)
-%attr(0644,root,root) %{_datadir}/%{name}-management/lib/*mysqlha*jar
+%attr(0644,root,root) %{_datadir}/%{name}-mysql-ha/lib/*
 %endif
 
 %files baremetal-agent
diff --git a/packaging/systemd/cloudstack-management.default b/packaging/systemd/cloudstack-management.default
index 6444c61..252fb4b 100644
--- a/packaging/systemd/cloudstack-management.default
+++ b/packaging/systemd/cloudstack-management.default
@@ -17,7 +17,7 @@
 
 JAVA_OPTS="-Djava.security.properties=/etc/cloudstack/management/java.security.ciphers -Djava.awt.headless=true -Dcom.sun.management.jmxremote=false -Xmx2G -XX:+UseParallelGC -XX:MaxGCPauseMillis=500 -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/var/log/cloudstack/management/ -XX:ErrorFile=/var/log/cloudstack/management/cloudstack-management.err "
 
-CLASSPATH="/usr/share/cloudstack-management/lib/*:/etc/cloudstack/management:/usr/share/cloudstack-common:/usr/share/cloudstack-management/setup:/usr/share/cloudstack-management:/usr/share/java/mysql-connector-java.jar"
+CLASSPATH="/usr/share/cloudstack-management/lib/*:/etc/cloudstack/management:/usr/share/cloudstack-common:/usr/share/cloudstack-management/setup:/usr/share/cloudstack-management:/usr/share/java/mysql-connector-java.jar:/usr/share/cloudstack-mysql-ha/lib/*"
 
 BOOTSTRAP_CLASS=org.apache.cloudstack.ServerDaemon