Search in sources :

Example 1 with AliHBaseUETable

use of org.apache.hadoop.hbase.client.AliHBaseUETable in project LinkAgent by shulieTech.

the class AliHBaseUETableInterceptor method exceptionTrace.

@Override
public SpanRecord exceptionTrace(Advice advice) {
    AliHBaseUETable hTable = (AliHBaseUETable) advice.getTarget();
    SpanRecord spanRecord = new SpanRecord();
    String tableName = getTableName(hTable);
    spanRecord.setService(tableName);
    spanRecord.setMethod(advice.getBehaviorName());
    spanRecord.setRequest(advice.getParameterArray()[0]);
    spanRecord.setResponse(advice.getThrowable());
    spanRecord.setResultCode(ResultCode.INVOKE_RESULT_FAILED);
    return spanRecord;
}
Also used : SpanRecord(com.pamirs.pradar.interceptor.SpanRecord) AliHBaseUETable(org.apache.hadoop.hbase.client.AliHBaseUETable)

Example 2 with AliHBaseUETable

use of org.apache.hadoop.hbase.client.AliHBaseUETable in project LinkAgent by shulieTech.

the class AliHBaseUETableInterceptor method beforeTrace.

@Override
public SpanRecord beforeTrace(Advice advice) {
    AliHBaseUETable hTable = (AliHBaseUETable) advice.getTarget();
    SpanRecord spanRecord = new SpanRecord();
    String tableName = getTableName(hTable);
    spanRecord.setService(tableName);
    spanRecord.setMethod(advice.getBehaviorName());
    spanRecord.setRequest(advice.getParameterArray()[0]);
    return spanRecord;
}
Also used : SpanRecord(com.pamirs.pradar.interceptor.SpanRecord) AliHBaseUETable(org.apache.hadoop.hbase.client.AliHBaseUETable)

Example 3 with AliHBaseUETable

use of org.apache.hadoop.hbase.client.AliHBaseUETable in project LinkAgent by shulieTech.

the class AliHBaseUETableInterceptor method afterTrace.

@Override
public SpanRecord afterTrace(Advice advice) {
    AliHBaseUETable hTable = (AliHBaseUETable) advice.getTarget();
    SpanRecord spanRecord = new SpanRecord();
    String tableName = getTableName(hTable);
    spanRecord.setService(tableName);
    spanRecord.setMethod(advice.getBehaviorName());
    spanRecord.setRequest(advice.getParameterArray()[0]);
    spanRecord.setResponse(advice.getReturnObj());
    return spanRecord;
}
Also used : SpanRecord(com.pamirs.pradar.interceptor.SpanRecord) AliHBaseUETable(org.apache.hadoop.hbase.client.AliHBaseUETable)

Aggregations

SpanRecord (com.pamirs.pradar.interceptor.SpanRecord)3 AliHBaseUETable (org.apache.hadoop.hbase.client.AliHBaseUETable)3