提交 eacc014e 编写于 作者: Z zhangxin

update the comment to improve the comment readable

上级 ec857190
......@@ -10,8 +10,9 @@ import com.a.eye.skywalking.trace.Span;
import com.a.eye.skywalking.trace.tag.Tags;
/**
* {@link JedisMethodInterceptor} create span and set redis host and redis connection information
* from {@link EnhancedClassInstanceContext#context} to span tags.
* {@link JedisMethodInterceptor} intercept all method of {@link redis.clients.jedis.Jedis}
* or {@link redis.clients.jedis.JedisCluster}. {@link JedisMethodInterceptor} record
* the redis host, operation name and the key of the operation.
*
* @author zhangxin
*/
......@@ -36,9 +37,7 @@ public class JedisMethodInterceptor extends NoCocurrencyAceessObject {
* using {@link #KEY_OF_REDIS_HOST} is not null.
*/
protected static final String KEY_OF_REDIS_PORT = "KEY_OF_REDIS_PORT";
/**
* Redis component
*/
private static final String REDIS_COMPONENT = "Redis";
......
......@@ -35,6 +35,7 @@ public class JedisInstrumentation extends ClassInstanceMethodsEnhancePluginDefin
private static final String CONSTRUCTOR_WITH_STRING_ARG_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.jedis.v2.JedisConstructorWithStringArgInterceptor";
private static final String CONSTRUCTOR_WITH_SHARD_INFO_ARG_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.jedis.v2.JedisConstructorWithShardInfoArgInterceptor";
private static final String CONSTRUCTOR_WITH_URI_ARG_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.jedis.v2.JedisConstructorWithUriArgInterceptor";
private static final String JEDIS_METHOD_INTERCET_CLASS = "com.a.eye.skywalking.plugin.jedis.v2.JedisMethodInterceptor";
@Override
public String enhanceClassName() {
......@@ -94,7 +95,7 @@ public class JedisInstrumentation extends ClassInstanceMethodsEnhancePluginDefin
@Override
public String getMethodsInterceptor() {
return "com.a.eye.skywalking.plugin.jedis.v2.JedisMethodInterceptor";
return JEDIS_METHOD_INTERCET_CLASS;
}
}};
}
......
......@@ -6,12 +6,12 @@ import com.a.eye.skywalking.api.plugin.interceptor.enhance.InstanceMethodsAround
import com.a.eye.skywalking.api.plugin.interceptor.enhance.MethodInterceptResult;
/**
* {@link ConsumerFetchRequestURLInterceptor} record {@link com.weibo.api.motan.rpc.URL} to {@link EnhancedClassInstanceContext#context}
* {@link MotanConsumerFetchRequestURLInterceptor} record {@link com.weibo.api.motan.rpc.URL} to {@link EnhancedClassInstanceContext#context}
* for the operation name that create span need.
*
* @author zhangxin
*/
public class ConsumerFetchRequestURLInterceptor implements InstanceMethodsAroundInterceptor {
public class MotanConsumerFetchRequestURLInterceptor implements InstanceMethodsAroundInterceptor {
private static final String CONTEXT_NAME_OF_REQUEST_URL = "REQUEST_URL";
......
......@@ -13,13 +13,13 @@ import com.weibo.api.motan.rpc.Response;
import com.weibo.api.motan.rpc.URL;
/**
* {@link ConsumerInvokeInterceptor} create span by fetch request url from
* {@link MotanConsumerInvokeInterceptor} create span by fetch request url from
* {@link EnhancedClassInstanceContext#context} and transport serialized context
* data to provider side through {@link Request#setAttachment(String, String)}.
*
* @author zhangxin
*/
public class ConsumerInvokeInterceptor implements InstanceMethodsAroundInterceptor {
public class MotanConsumerInvokeInterceptor implements InstanceMethodsAroundInterceptor {
/**
* Context name of request url in {@link EnhancedClassInstanceContext#context}.
......
......@@ -18,12 +18,12 @@ import com.weibo.api.motan.rpc.URL;
* Current trace segment will ref the trace segment from previous level if the serialized context data that fetch
* from {@link Request#getAttachments()} is not null.
*
* {@link ProviderInterceptor} intercept all constructor of {@link com.weibo.api.motan.rpc.AbstractProvider} for record
* {@link MotanProviderInterceptor} intercept all constructor of {@link com.weibo.api.motan.rpc.AbstractProvider} for record
* the request url from consumer side.
*
* @author zhangxin
*/
public class ProviderInterceptor implements InstanceConstructorInterceptor, InstanceMethodsAroundInterceptor {
public class MotanProviderInterceptor implements InstanceConstructorInterceptor, InstanceMethodsAroundInterceptor {
/**
* The
......
......@@ -3,8 +3,8 @@ package com.a.eye.skywalking.plugin.motan.define;
import com.a.eye.skywalking.api.plugin.interceptor.ConstructorInterceptPoint;
import com.a.eye.skywalking.api.plugin.interceptor.InstanceMethodsInterceptPoint;
import com.a.eye.skywalking.api.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine;
import com.a.eye.skywalking.plugin.motan.ConsumerFetchRequestURLInterceptor;
import com.a.eye.skywalking.plugin.motan.ConsumerInvokeInterceptor;
import com.a.eye.skywalking.plugin.motan.MotanConsumerFetchRequestURLInterceptor;
import com.a.eye.skywalking.plugin.motan.MotanConsumerInvokeInterceptor;
import com.weibo.api.motan.rpc.Request;
import com.weibo.api.motan.rpc.URL;
......@@ -15,9 +15,9 @@ import static net.bytebuddy.matcher.ElementMatchers.named;
/**
* {@link MotanConsumerInstrumentation} presents that skywalking intercept
* {@link com.weibo.api.motan.cluster.support.ClusterSpi#call(Request)} by using {@link ConsumerInvokeInterceptor} and
* {@link com.weibo.api.motan.cluster.support.ClusterSpi#call(Request)} by using {@link MotanConsumerInvokeInterceptor} and
* intercept {@link com.weibo.api.motan.cluster.support.ClusterSpi#setUrl(URL)} by using
* {@link ConsumerFetchRequestURLInterceptor} to intercept{@link ConsumerFetchRequestURLInterceptor}.
* {@link MotanConsumerFetchRequestURLInterceptor} to intercept{@link MotanConsumerFetchRequestURLInterceptor}.
*
* @author zhangxin
*/
......@@ -25,9 +25,9 @@ public class MotanConsumerInstrumentation extends ClassInstanceMethodsEnhancePlu
private static final String ENHANCE_CLASS = "com.weibo.api.motan.cluster.support.ClusterSpi";
private static final String FETCH_REQUEST_URL_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.ConsumerFetchRequestURLInterceptor";
private static final String FETCH_REQUEST_URL_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.MotanConsumerFetchRequestURLInterceptor";
private static final String INVOKE_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.ConsumerInvokeInterceptor";
private static final String INVOKE_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.MotanConsumerInvokeInterceptor";
@Override
protected String enhanceClassName() {
......
......@@ -3,6 +3,7 @@ package com.a.eye.skywalking.plugin.motan.define;
import com.a.eye.skywalking.api.plugin.interceptor.ConstructorInterceptPoint;
import com.a.eye.skywalking.api.plugin.interceptor.InstanceMethodsInterceptPoint;
import com.a.eye.skywalking.api.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine;
import com.a.eye.skywalking.plugin.motan.MotanProviderInterceptor;
import com.weibo.api.motan.rpc.Request;
import net.bytebuddy.description.method.MethodDescription;
......@@ -13,7 +14,7 @@ import static net.bytebuddy.matcher.ElementMatchers.named;
/**
* {@link MotanProviderInstrumentation} presents that skywalking will use
* {@link com.a.eye.skywalking.plugin.motan.ProviderInterceptor} to intercept
* {@link MotanProviderInterceptor} to intercept
* all constructor of {@link com.weibo.api.motan.rpc.AbstractProvider} and
* {@link com.weibo.api.motan.rpc.AbstractProvider#call(Request)}.
*
......@@ -28,11 +29,11 @@ public class MotanProviderInstrumentation extends ClassInstanceMethodsEnhancePlu
/**
* Class that intercept all constructor of ${@link com.weibo.api.motan.rpc.AbstractProvider}.
*/
private static final String CONSTRUCTOR_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.ProviderInterceptor";
private static final String CONSTRUCTOR_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.MotanProviderInterceptor";
/**
* Class that intercept {@link com.weibo.api.motan.rpc.AbstractProvider#call(Request)}.
*/
private static final String PROVIDER_INVOKE_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.ProviderInterceptor";
private static final String PROVIDER_INVOKE_INTERCEPT_CLASS = "com.a.eye.skywalking.plugin.motan.MotanProviderInterceptor";
@Override
protected String enhanceClassName() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册