refactory code
This commit is contained in:
parent
3f2e7904c3
commit
aa55121b8f
|
|
@ -49,8 +49,6 @@ import static org.skywalking.apm.plugin.jdbc.define.Constants.SERVICE_METHOD_INT
|
|||
*/
|
||||
public abstract class ConnectionInstrumentation extends ClassInstanceMethodsEnhancePluginDefine {
|
||||
|
||||
public static final String ENHANCE_CLASS = "com.mysql.jdbc.ConnectionImpl";
|
||||
|
||||
@Override protected ConstructorInterceptPoint[] getConstructorsInterceptPoints() {
|
||||
return new ConstructorInterceptPoint[0];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,7 +29,11 @@ import static org.skywalking.apm.plugin.jdbc.mysql.define.MultiClassNameMatch.by
|
|||
* @author zhangxin
|
||||
*/
|
||||
public class Mysql5xConnectionInstrumentation extends ConnectionInstrumentation {
|
||||
public static final String ENHANCE_CLASS = "com.mysql.jdbc.ConnectionImpl";
|
||||
|
||||
public static final String CJ_JDBC_ENHANCE_CLASS = "com.mysql.cj.jdbc.ConnectionImpl";
|
||||
|
||||
@Override protected ClassMatch enhanceClass() {
|
||||
return byMultiClassMatch(ENHANCE_CLASS, "com.mysql.cj.jdbc.ConnectionImpl");
|
||||
return byMultiClassMatch(ENHANCE_CLASS, CJ_JDBC_ENHANCE_CLASS);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue