Skip to content
This repository has been archived by the owner on Jan 3, 2023. It is now read-only.

Commit

Permalink
Solve #894, code refactor (#895)
Browse files Browse the repository at this point in the history
  • Loading branch information
littlezhou authored Aug 7, 2017
1 parent 834f153 commit abe8212
Show file tree
Hide file tree
Showing 302 changed files with 283 additions and 281 deletions.
5 changes: 2 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<module>smart-maven-plugins</module>
<module>smart-common</module>
<module>smart-metrics</module>
<module>smart-actions</module>
<module>smart-action</module>
<module>smart-metastore</module>
<module>smart-client</module>
<module>smart-admin</module>
Expand All @@ -36,7 +36,7 @@
<module>smart-agent</module>
<module>smart-dist</module>
<module>smart-integration</module>
<module>smart-hadoop</module>
<module>smart-hadoop-support</module>
</modules>

<properties>
Expand Down Expand Up @@ -71,7 +71,6 @@
</activation>
<modules>
<module>smart-alluxio</module>
<module>smart-erasurecode</module>
</modules>
</profile>

Expand Down
2 changes: 1 addition & 1 deletion smart-actions/pom.xml → smart-action/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<relativePath>../pom.xml</relativePath>
</parent>

<artifactId>smart-actions</artifactId>
<artifactId>smart-action</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.actions.annotation.ActionSignature;
import org.smartdata.action.annotation.ActionSignature;

import java.util.Collections;
import java.util.HashMap;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

public class ActionException extends Exception {
public ActionException(String errorMsg) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import java.util.Map;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.actions.annotation.ActionSignature;
import org.smartdata.action.annotation.ActionSignature;
import org.smartdata.model.ActionDescriptor;

import java.io.IOException;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

/**
* Internal actions supported.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import org.smartdata.actions.annotation.ActionSignature;
import org.smartdata.action.annotation.ActionSignature;

@ActionSignature(
actionId = "hello",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import org.apache.commons.io.output.ByteArrayOutputStream;
import org.apache.commons.lang.exception.ExceptionUtils;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import java.util.Date;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.annotation;
package org.smartdata.action.annotation;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions;
package org.smartdata.action;

import org.junit.Assert;
import org.smartdata.protocol.message.ActionFinished;
Expand Down
4 changes: 2 additions & 2 deletions smart-alluxio/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
</dependency>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-actions</artifactId>
<artifactId>smart-action</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
Expand All @@ -88,7 +88,7 @@
</dependency>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-actions</artifactId>
<artifactId>smart-action</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>test</scope>
<type>test-jar</type>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.Map;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.actions.SmartAction;
import org.smartdata.action.SmartAction;

import alluxio.AlluxioURI;
import alluxio.client.file.FileSystem;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

public enum AlluxioActionType {
None(0), // doing nothing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.io.IOException;
/*
import org.smartdata.hdfs.actions.copy.CopyRunner;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.Map;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.ArrayList;
import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.ArrayList;
import java.util.List;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.Map;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.Map;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import java.util.Map;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* limitations under the License.
*/

package org.smartdata.actions.alluxio;
package org.smartdata.action.alluxio;

import static org.junit.Assert.*;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
* limitations under the License.
*/

package org.smartdata.actions.alluxio.metric.fetcher;
package org.smartdata.action.alluxio.metric.fetcher;

import alluxio.AlluxioURI;
import alluxio.client.WriteType;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public class SmartConfKeys {
public static final String SMART_STATES_UPDATE_SERVICE_KEY = "smart.states.update.service";
public static final String SMART_STATES_UPDATE_SERVICE_DEFAULT = "org.smartdata.hdfs.HdfsStatesUpdateService";
public static final String SMART_ACTION_SCHEDULER_SERVICE_KEY = "smart.action.scheduler.service";
public static final String SMART_ACTION_SCHEDULER_SERVICE_DEFAULT = "org.smartdata.hdfs.metric.fetcher.MoverPreProcessService";
public static final String SMART_ACTION_SCHEDULER_SERVICE_DEFAULT = "org.smartdata.hdfs.scheduler.MoverPreProcessService";

// RuleManager
public final static String SMART_RULE_EXECUTORS_KEY = "smart.rule.executors";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.smartdata.model.actions;
package org.smartdata.model.action;

import org.smartdata.model.LaunchAction;

Expand Down
7 changes: 1 addition & 6 deletions smart-dist/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
</dependency>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-actions</artifactId>
<artifactId>smart-action</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
Expand Down Expand Up @@ -92,11 +92,6 @@
<jdk>[1.8,)</jdk>
</activation>
<dependencies>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-erasurecodec</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
</dependencies>
</profile>
<profile>
Expand Down
4 changes: 2 additions & 2 deletions smart-engine/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
</dependency>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-hadoop-base</artifactId>
<artifactId>smart-hadoop</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
Expand All @@ -60,7 +60,7 @@
</dependency>
<dependency>
<groupId>org.smartdata</groupId>
<artifactId>smart-actions</artifactId>
<artifactId>smart-action</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.SmartContext;
import org.smartdata.actions.ActionException;
import org.smartdata.action.ActionException;
import org.smartdata.model.CmdletState;
import org.smartdata.protocol.message.CmdletStatusUpdate;
import org.smartdata.server.engine.cmdlet.CmdletExecutor;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.AbstractService;
import org.smartdata.actions.ActionException;
import org.smartdata.actions.ActionRegistry;
import org.smartdata.actions.SmartAction;
import org.smartdata.action.ActionException;
import org.smartdata.action.ActionRegistry;
import org.smartdata.action.SmartAction;
import org.smartdata.hdfs.action.AbstractMoveFileAction;
import org.smartdata.metastore.MetaStore;
import org.smartdata.metastore.MetaStoreException;
Expand All @@ -44,7 +44,7 @@
import org.smartdata.server.engine.cmdlet.CmdletDispatcher;
import org.smartdata.server.engine.cmdlet.CmdletExecutorService;
import org.smartdata.metastore.ActionPreProcessService;
import org.smartdata.model.actions.ActionPreProcessor;
import org.smartdata.model.action.ActionPreProcessor;
import org.smartdata.model.LaunchAction;
import org.smartdata.server.engine.cmdlet.message.LaunchCmdlet;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.AbstractService;
import org.smartdata.actions.ActionRegistry;
import org.smartdata.action.ActionRegistry;
import org.smartdata.model.CmdletDescriptor;
import org.smartdata.model.RuleInfo;
import org.smartdata.model.RuleState;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
package org.smartdata.server.engine.cmdlet;

import org.smartdata.model.CmdletState;
import org.smartdata.actions.SmartAction;
import org.smartdata.action.SmartAction;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import com.google.common.util.concurrent.MoreExecutors;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.actions.SmartAction;
import org.smartdata.action.SmartAction;
import org.smartdata.protocol.message.ActionStatus;
import org.smartdata.protocol.message.StatusReporter;
import org.smartdata.protocol.message.ActionStatusReport;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.smartdata.SmartContext;
import org.smartdata.actions.ActionException;
import org.smartdata.actions.ActionRegistry;
import org.smartdata.actions.SmartAction;
import org.smartdata.action.ActionException;
import org.smartdata.action.ActionRegistry;
import org.smartdata.action.SmartAction;
import org.smartdata.hdfs.HadoopUtil;
import org.smartdata.hdfs.action.HdfsAction;
import org.smartdata.hdfs.client.SmartDFSClient;
Expand Down
Loading

0 comments on commit abe8212

Please sign in to comment.