mirror of
https://github.com/wahyd4/pinpoint.git
synced 2026-08-23 11:46:46 +10:00
[강운덕] [LUCYSUS-1744] jdbc interceptor 는 공통클래스라 db쪽으로 패키지를 이동시킴
git-svn-id: http://svn.bds.nhncorp.com/pe/hippo-tomcat-profiler/trunk@654 84d0f5b1-2673-498c-a247-62c4ff18d310
This commit is contained in:
@@ -1,20 +1,16 @@
|
||||
package com.profiler.modifier.db.mysql;
|
||||
|
||||
import java.security.ProtectionDomain;
|
||||
import java.sql.Connection;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
import com.profiler.interceptor.Interceptor;
|
||||
import com.profiler.interceptor.bci.InstrumentException;
|
||||
import com.profiler.interceptor.bci.JavaAssistClass;
|
||||
import com.profiler.modifier.db.mysql.interceptors.ExecuteQueryMethodInterceptor;
|
||||
import javassist.*;
|
||||
import com.profiler.modifier.db.interceptor.ExecuteQueryMethodInterceptor;
|
||||
|
||||
import com.profiler.interceptor.bci.ByteCodeInstrumentor;
|
||||
import com.profiler.interceptor.bci.InstrumentClass;
|
||||
import com.profiler.modifier.AbstractModifier;
|
||||
import javassist.bytecode.AccessFlag;
|
||||
|
||||
public class MySQLStatementModifier extends AbstractModifier {
|
||||
|
||||
@@ -37,12 +33,12 @@ public class MySQLStatementModifier extends AbstractModifier {
|
||||
|
||||
try {
|
||||
InstrumentClass statementClass = byteCodeInstrumentor.getClass(javassistClassName);
|
||||
// Interceptor interceptor = newInterceptor(classLoader, protectedDomain, "com.profiler.modifier.db.mysql.interceptors.ExecuteQueryMethodInterceptor");
|
||||
// Interceptor interceptor = newInterceptor(classLoader, protectedDomain, "com.profiler.modifier.db.interceptor.ExecuteQueryMethodInterceptor");
|
||||
Interceptor interceptor = new ExecuteQueryMethodInterceptor();
|
||||
statementClass.addInterceptor("executeQuery", new String[]{"java.lang.String"}, interceptor);
|
||||
|
||||
|
||||
Interceptor interceptor1 = newInterceptor(classLoader, protectedDomain, "com.profiler.modifier.db.mysql.interceptors.ExecuteUpdateMethodInterceptor");
|
||||
Interceptor interceptor1 = newInterceptor(classLoader, protectedDomain, "com.profiler.modifier.db.interceptor.ExecuteUpdateMethodInterceptor");
|
||||
statementClass.addInterceptor("executeUpdate", new String[]{"java.lang.String", "boolean", "boolean"}, interceptor1);
|
||||
|
||||
statementClass.addTraceVariable("__url", "__setUrl", "__getUrl", "java.lang.String");
|
||||
|
||||
Reference in New Issue
Block a user