001
014
015 package com.liferay.portal.deploy.auto;
016
017 import com.liferay.portal.deploy.DeployUtil;
018 import com.liferay.portal.kernel.deploy.auto.AutoDeployer;
019 import com.liferay.portal.kernel.log.Log;
020 import com.liferay.portal.kernel.log.LogFactoryUtil;
021 import com.liferay.portal.kernel.util.PropsKeys;
022 import com.liferay.portal.kernel.util.ServerDetector;
023 import com.liferay.portal.kernel.util.StringPool;
024 import com.liferay.portal.tools.deploy.ExtDeployer;
025 import com.liferay.portal.util.PrefsPropsUtil;
026 import com.liferay.portal.util.PropsValues;
027
028 import java.util.ArrayList;
029 import java.util.List;
030
031
034 public class ExtAutoDeployer extends ExtDeployer implements AutoDeployer {
035
036 public ExtAutoDeployer() {
037 try {
038 baseDir = PrefsPropsUtil.getString(
039 PropsKeys.AUTO_DEPLOY_DEPLOY_DIR,
040 PropsValues.AUTO_DEPLOY_DEPLOY_DIR);
041 destDir = DeployUtil.getAutoDeployDestDir();
042 appServerType = ServerDetector.getServerId();
043 unpackWar = PrefsPropsUtil.getBoolean(
044 PropsKeys.AUTO_DEPLOY_UNPACK_WAR,
045 PropsValues.AUTO_DEPLOY_UNPACK_WAR);
046 filePattern = StringPool.BLANK;
047 jbossPrefix = PrefsPropsUtil.getString(
048 PropsKeys.AUTO_DEPLOY_JBOSS_PREFIX,
049 PropsValues.AUTO_DEPLOY_JBOSS_PREFIX);
050 tomcatLibDir = PrefsPropsUtil.getString(
051 PropsKeys.AUTO_DEPLOY_TOMCAT_LIB_DIR,
052 PropsValues.AUTO_DEPLOY_TOMCAT_LIB_DIR);
053
054 List<String> jars = new ArrayList<String>();
055
056 addRequiredJar(jars, "util-bridges.jar");
057 addRequiredJar(jars, "util-java.jar");
058 addRequiredJar(jars, "util-taglib.jar");
059
060 this.jars = jars;
061
062 checkArguments();
063 }
064 catch (Exception e) {
065 _log.error(e, e);
066 }
067 }
068
069 private static Log _log = LogFactoryUtil.getLog(ExtAutoDeployer.class);
070
071 }