Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Increase the regularity of the code #767

Merged
merged 4 commits into from
Jun 3, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,7 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/10
* time: 15:16
* Description:
*/

package com.webank.wedatasphere.linkis.common.exception;

import java.util.HashMap;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,7 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/11
* time: 20:40
* Description:
*/

package com.webank.wedatasphere.linkis.common.exception;

public class ErrorException extends DWCException{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,7 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/11
* time: 20:41
* Description:
*/

package com.webank.wedatasphere.linkis.common.exception;

public enum ExceptionLevel {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,7 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/13
* time: 17:32
* Description:
*/

package com.webank.wedatasphere.linkis.common.exception;

import java.util.HashMap;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,6 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/11
* time: 20:40
* Description:
*/
package com.webank.wedatasphere.linkis.common.exception;

public class FatalException extends DWCException{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,7 @@
* limitations under the License.
*/

/**
* author: enjoyyin
* date: 2018/9/11
* time: 20:39
* Description:
*/

package com.webank.wedatasphere.linkis.common.exception;

public class WarnException extends DWCRuntimeException{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/8/4
*/

@Target({ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface Chain {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/7/28
*/

@Target({ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface Implicit {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/7/14
*/

@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
public @interface Method {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/8/4
*/

@Target({ElementType.PARAMETER})
@Retention(RetentionPolicy.RUNTIME)
public @interface NotImplicit {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/7/14
*/

@Target({ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface Order {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,7 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* @date 2020/7/14
*/

@Target({ElementType.METHOD})
@Retention(RetentionPolicy.RUNTIME)
public @interface Receiver {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@
import java.util.concurrent.TimeoutException;
import java.util.concurrent.locks.LockSupport;

/**
* @date 2020/7/17
*/

public class DefaultMessageJob extends Job implements MessageJob {

private RequestProtocol requestProtocol;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
import java.util.List;
import java.util.Map;

/**
* @date 2020/7/17
*/

public class DefaultMessageJobBuilder implements MessageJobBuilder {

private RequestProtocol requestProtocol;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@

import static com.webank.wedatasphere.linkis.message.conf.MessageSchedulerConf.*;

/**
* @date 2020/7/14
*/

public class DefaultServiceMethodContext implements ServiceMethodContext {

private final Map<String, Object> attributes = new ConcurrentHashMap<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
import java.util.concurrent.TimeUnit;
import java.util.concurrent.TimeoutException;

/**
* @date 2020/8/4
*/

public interface Future<V> {

boolean cancel(boolean mayInterruptIfRunning);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@
import java.util.Map;


/**
* @date 2020/7/14
*/
public interface MessageJob extends Runnable, Future<Object> {

RequestProtocol getRequestProtocol();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
import java.util.List;
import java.util.Map;

/**
* @date 2020/7/17
*/

public interface MessageJobBuilder {

MessageJobBuilder of();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@

import java.util.concurrent.locks.LockSupport;

/**
* @date 2020/7/17
*/

public class MessageJobListener extends JavaLog implements JobListener {

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@

package com.webank.wedatasphere.linkis.message.builder;

/**
* @date 2020/7/27
*/

public enum MessageJobTimeoutPolicy {
/**
* 取消,但是不打断
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@

import javax.servlet.http.HttpServletRequest;

/**
* @date 2020/7/14
*/

public interface ServiceMethodContext {

void putAttribute(String key, Object value);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
import org.reflections.scanners.SubTypesScanner;
import org.reflections.scanners.TypeAnnotationsScanner;

/**
* @date 2020/7/14
*/

public class MessageSchedulerConf {

public final static String SERVICE_SCAN_PACKAGE = CommonVars.apply("wds.linkis.ms.service.scan.package", "com.webank.wedatasphere").getValue();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
import com.webank.wedatasphere.linkis.message.scheduler.MessageScheduler;
import com.webank.wedatasphere.linkis.message.tx.TransactionManager;

/**
* @date 2020/7/15
*/

public abstract class AbstractMessageSchedulerContext implements MessageSchedulerContext {

private AbstractServiceRegistry serviceRegistry;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
import com.webank.wedatasphere.linkis.message.scheduler.DefaultMessageScheduler;
import com.webank.wedatasphere.linkis.message.tx.TransactionManager;

/**
* @date 2020/7/15
*/

public class DefaultMessageSchedulerContext extends AbstractMessageSchedulerContext {

{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
* @date 2020/9/17
*/

public class MSContextInstance {

private static final Logger LOGGER = LoggerFactory.getLogger(MSContextInstance.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,7 @@
import com.webank.wedatasphere.linkis.message.registry.ImplicitRegistry;
import com.webank.wedatasphere.linkis.message.registry.ServiceRegistry;

/**
* @date 2020/7/14
*/

public interface MessageSchedulerContext {

MessagePublisher getPublisher();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
import com.webank.wedatasphere.linkis.message.scheduler.DefaultMessageScheduler;
import com.webank.wedatasphere.linkis.message.tx.SpringTransactionManager;

/**
* @date 2020/9/11
*/

public class SpringMessageSchedulerContext extends AbstractMessageSchedulerContext {

{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@

import com.webank.wedatasphere.linkis.common.exception.ErrorException;

/**
* @date 2020/7/15
*/

public class MessageErrorException extends ErrorException {

public MessageErrorException(int errCode, String desc) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@

import com.webank.wedatasphere.linkis.common.exception.WarnException;

/**
* @date 2020/6/10 17:43
*/

public class MessageWarnException extends WarnException {

public MessageWarnException(int errCode, String desc) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@
import java.util.Map;
import java.util.stream.Collectors;

/**
* @date 2020/7/28
*/

public class DefaultImplicitParser implements ImplicitParser {
@Override
public Map<String, List<ImplicitMethod>> parse(Object implicitObject) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@
import java.util.Map;
import java.util.stream.Collectors;

/**
* @date 2020/7/15
*/

public class DefaultServiceParser implements ServiceParser {

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@

import java.lang.reflect.Method;

/**
* @date 2020/7/28
*/

public class ImplicitMethod {

private Object implicitObject;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@
import java.util.List;
import java.util.Map;

/**
* @date 2020/7/28
*/

public interface ImplicitParser {

Map<String, List<ImplicitMethod>> parse(Object implicitObject);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,7 @@

import java.lang.reflect.Method;

/**
* @date 2020/7/15
*/

public class ServiceMethod {

private Object service;
Expand Down
Loading