修复部分问题
This commit is contained in:
parent
7d6e83d681
commit
b08470b8b6
|
|
@ -53,7 +53,7 @@ public class Config {
|
|||
|
||||
public static String DRIVER_CLASS = "com.mysql.jdbc.Driver";
|
||||
|
||||
public static String URL = "jdbc:mysql://127.0.0.1:3316/test";
|
||||
public static String URL = "jdbc:mysql://127.0.0.1:3307/test";
|
||||
|
||||
public static int MAX_IDLE = 1;
|
||||
|
||||
|
|
@ -86,7 +86,7 @@ public class Config {
|
|||
|
||||
public static class MailSenderInfo {
|
||||
|
||||
public static String MAIL_HOST = "mail.com";
|
||||
public static String MAIL_HOST = "mail.qq.com";
|
||||
|
||||
public static String TRANSPORT_PROTOCOL = "smtp";
|
||||
|
||||
|
|
@ -94,11 +94,11 @@ public class Config {
|
|||
|
||||
public static boolean SSL_ENABLE = false;
|
||||
|
||||
public static String USERNAME = "username";
|
||||
public static String USERNAME = "skywalking@foxmail.com";
|
||||
|
||||
public static String PASSWORD = "password";
|
||||
public static String PASSWORD = "tcaeuhuslkjlebjg";
|
||||
|
||||
public static String SENDER = "sender@mail.com";
|
||||
public static String SENDER = "skywalking@foxmail.com";
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@ import javax.mail.*;
|
|||
import javax.mail.internet.AddressException;
|
||||
import javax.mail.internet.InternetAddress;
|
||||
import javax.mail.internet.MimeMessage;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Properties;
|
||||
|
||||
public class MailSender {
|
||||
|
|
@ -24,7 +26,7 @@ public class MailSender {
|
|||
|
||||
config.setProperty("mail.transport.protocol", Config.MailSenderInfo.TRANSPORT_PROTOCOL);
|
||||
config.setProperty("mail.smtp.auth", String.valueOf(Config.MailSenderInfo.SMTP_AUTH));
|
||||
config.setProperty("mail.smtp.socketFactory.port", "465");
|
||||
config.setProperty("mail.smtp.socketFactory.port", "587");
|
||||
config.setProperty("mail.debug", "true");
|
||||
//config.setProperty("mail.smtp.ssl.enable", "true");
|
||||
if (Config.MailSenderInfo.SSL_ENABLE) {
|
||||
|
|
@ -56,11 +58,14 @@ public class MailSender {
|
|||
}
|
||||
message.addRecipients(Message.RecipientType.TO, recipientAccountArray);
|
||||
if (ccList != null && ccList.length > 0) {
|
||||
InternetAddress[] ccAccountArray = new InternetAddress[ccList.length];
|
||||
List<InternetAddress> ccAccountArray = new ArrayList<InternetAddress>();
|
||||
for (int i = 0; i < ccList.length; i++) {
|
||||
ccAccountArray[i] = new InternetAddress(ccList[i]);
|
||||
if (ccList[i] != null && ccList[i].length() > 0)
|
||||
ccAccountArray.add(new InternetAddress(ccList[i]));
|
||||
}
|
||||
if (ccAccountArray.size() > 0) {
|
||||
message.addRecipients(Message.RecipientType.CC, ccAccountArray.toArray(new InternetAddress[ccAccountArray.size()]));
|
||||
}
|
||||
message.addRecipients(Message.RecipientType.CC, ccAccountArray);
|
||||
}
|
||||
message.setSubject(title);
|
||||
message.setContent(content, "text/html;charset=UTF-8");
|
||||
|
|
|
|||
|
|
@ -69,6 +69,12 @@
|
|||
<artifactId>skywalking-toolkit-log4j-2.x-activation</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.a.eye</groupId>
|
||||
<artifactId>skywalking-toolkit-logback-1.x-activation</artifactId>
|
||||
<version>${project.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<finalName>${artifactId}</finalName>
|
||||
|
|
|
|||
|
|
@ -158,7 +158,7 @@ public class Span {
|
|||
|
||||
public RequestSpan.Builder buildRequestSpan(RequestSpan.Builder builder) {
|
||||
builder.setTraceId(this.traceId).setParentLevel(this.parentLevel).setLevelId(this.levelId).setSpanType(this.spanType).setApplicationCode(Config.SkyWalking.APPLICATION_CODE)
|
||||
.setUsername(Config.SkyWalking.USERNAME).setRouteKey(routeKey);
|
||||
.setStartDate(this.startDate).setUsername(Config.SkyWalking.USERNAME).setRouteKey(routeKey);
|
||||
return builder;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -30,5 +30,17 @@
|
|||
<version>3.2.0</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>redis.clients</groupId>
|
||||
<artifactId>jedis</artifactId>
|
||||
<version>2.8.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.a.eye</groupId>
|
||||
<artifactId>skywalking-util</artifactId>
|
||||
<version>2.0-2016</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
</project>
|
||||
|
|
|
|||
|
|
@ -1,8 +1,8 @@
|
|||
package com.a.eye.skywalking.storage.alarm;
|
||||
package com.a.eye.skywalking.routing.alarm;
|
||||
|
||||
import com.a.eye.skywalking.storage.alarm.checker.*;
|
||||
import com.a.eye.skywalking.storage.alarm.sender.AlarmMessageSenderFactory;
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
import com.a.eye.skywalking.routing.alarm.checker.*;
|
||||
import com.a.eye.skywalking.routing.alarm.sender.AlarmMessageSenderFactory;
|
||||
import com.a.eye.skywalking.routing.disruptor.ack.AckSpanHolder;
|
||||
import com.a.eye.skywalking.util.TraceIdUtil;
|
||||
import com.lmax.disruptor.EventHandler;
|
||||
|
||||
|
|
@ -12,7 +12,7 @@ import java.util.List;
|
|||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
*/
|
||||
public class SpanAlarmHandler implements EventHandler<AckSpanData> {
|
||||
public class SpanAlarmHandler implements EventHandler<AckSpanHolder> {
|
||||
private List<ISpanChecker> spanCheckers = new ArrayList<ISpanChecker>();
|
||||
|
||||
public SpanAlarmHandler() {
|
||||
|
|
@ -21,16 +21,16 @@ public class SpanAlarmHandler implements EventHandler<AckSpanData> {
|
|||
spanCheckers.add(new ExecuteTimePossibleErrorChecker());
|
||||
}
|
||||
|
||||
private String generateAlarmMessageKey(AckSpanData span, FatalReason reason) {
|
||||
return span.getUserName() + "-" + span.getApplicationCode() + "-" + (System.currentTimeMillis() / (10000 * 6)) + reason.getDetail();
|
||||
private String generateAlarmMessageKey(AckSpanHolder span, FatalReason reason) {
|
||||
return span.getAckSpan().getUsername() + "-" + span.getAckSpan().getApplicationCode() + "-" + (System.currentTimeMillis() / (10000 * 6)) + reason.getDetail();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEvent(AckSpanData spanData, long sequence, boolean endOfBatch) throws Exception {
|
||||
public void onEvent(AckSpanHolder spanData, long sequence, boolean endOfBatch) throws Exception {
|
||||
for (ISpanChecker spanChecker : spanCheckers) {
|
||||
CheckResult result = spanChecker.check(spanData);
|
||||
if (!result.isPassed()) {
|
||||
AlarmMessageSenderFactory.getSender().send(generateAlarmMessageKey(spanData, result.getFatalReason()), TraceIdUtil.formatTraceId(spanData.getTraceId()), result.getMessage());
|
||||
AlarmMessageSenderFactory.getSender().send(generateAlarmMessageKey(spanData, result.getFatalReason()), TraceIdUtil.formatTraceId(spanData.getAckSpan().getTraceId()), result.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
|
|
@ -1,15 +1,15 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
import com.a.eye.skywalking.storage.config.Config;
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
import com.a.eye.skywalking.routing.config.Config;
|
||||
import com.a.eye.skywalking.routing.disruptor.ack.AckSpanHolder;
|
||||
|
||||
public class ExceptionChecker implements ISpanChecker {
|
||||
|
||||
@Override
|
||||
public CheckResult check(AckSpanData span) {
|
||||
if (span.getStatusCode() != 1)
|
||||
public CheckResult check(AckSpanHolder span) {
|
||||
if (span.getAckSpan().getStatusCode() != 1)
|
||||
return new CheckResult();
|
||||
String exceptionStack = span.getExceptionStack();
|
||||
String exceptionStack = span.getAckSpan().getExceptionStack();
|
||||
if (exceptionStack == null) {
|
||||
exceptionStack = "";
|
||||
} else if (exceptionStack.length() > Config.Alarm.ALARM_EXCEPTION_STACK_LENGTH) {
|
||||
|
|
@ -1,7 +1,6 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
import com.a.eye.skywalking.network.grpc.AckSpan;
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
import com.a.eye.skywalking.routing.disruptor.ack.AckSpanHolder;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
|
|
@ -9,8 +8,8 @@ import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
|||
public abstract class ExecuteTimeChecker implements ISpanChecker {
|
||||
|
||||
@Override
|
||||
public CheckResult check(AckSpanData span) {
|
||||
long cost = span.getCost();
|
||||
public CheckResult check(AckSpanHolder span) {
|
||||
long cost = span.getAckSpan().getCost();
|
||||
if (isOverThreshold(cost)) {
|
||||
return new CheckResult(getFatalLevel(), generateAlarmMessage(span));
|
||||
}
|
||||
|
|
@ -22,8 +21,8 @@ public abstract class ExecuteTimeChecker implements ISpanChecker {
|
|||
|
||||
protected abstract FatalReason getFatalLevel();
|
||||
|
||||
protected String generateAlarmMessage(AckSpanData span) {
|
||||
return span.getViewPointId() + " cost " + span.getCost() + " ms.";
|
||||
protected String generateAlarmMessage(AckSpanHolder span) {
|
||||
return span.getAckSpan().getViewpointId() + " cost " + span.getAckSpan().getCost() + " ms.";
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
|
|
@ -1,9 +1,10 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
*/
|
||||
public enum FatalReason {
|
||||
|
||||
EXCEPTION_ERROR(""), EXECUTE_TIME_ERROR("-ExecuteTime-PossibleError"), EXECUTE_TIME_WARNING("-ExecuteTime-Warning");
|
||||
private String detail;
|
||||
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
package com.a.eye.skywalking.routing.alarm.checker;
|
||||
|
||||
|
||||
import com.a.eye.skywalking.routing.disruptor.ack.AckSpanHolder;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
*/
|
||||
public interface ISpanChecker {
|
||||
CheckResult check(AckSpanHolder span);
|
||||
}
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
package com.a.eye.skywalking.storage.alarm.sender;
|
||||
package com.a.eye.skywalking.routing.alarm.sender;
|
||||
|
||||
import com.a.eye.skywalking.logging.api.ILog;
|
||||
import com.a.eye.skywalking.logging.api.LogManager;
|
||||
import com.a.eye.skywalking.storage.config.Config;
|
||||
import com.a.eye.skywalking.routing.config.Config;
|
||||
import redis.clients.jedis.Jedis;
|
||||
|
||||
/**
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package com.a.eye.skywalking.storage.alarm.sender;
|
||||
package com.a.eye.skywalking.routing.alarm.sender;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
|
|
@ -1,8 +1,8 @@
|
|||
package com.a.eye.skywalking.storage.alarm.sender;
|
||||
package com.a.eye.skywalking.routing.alarm.sender;
|
||||
|
||||
import com.a.eye.skywalking.logging.api.ILog;
|
||||
import com.a.eye.skywalking.logging.api.LogManager;
|
||||
import com.a.eye.skywalking.storage.config.Config;
|
||||
import com.a.eye.skywalking.routing.config.Config;
|
||||
import org.apache.commons.pool2.impl.GenericObjectPoolConfig;
|
||||
import redis.clients.jedis.Jedis;
|
||||
import redis.clients.jedis.JedisPool;
|
||||
|
|
@ -35,4 +35,24 @@ public class Config {
|
|||
|
||||
public static int FLUSH_SIZE = 100;
|
||||
}
|
||||
|
||||
|
||||
public static class Alarm {
|
||||
|
||||
public static String REDIS_SERVER = "127.0.0.1:6379";
|
||||
|
||||
public static boolean ALARM_OFF_FLAG = false;
|
||||
|
||||
public static int ALARM_EXCEPTION_STACK_LENGTH = 300;
|
||||
|
||||
public static long ALARM_REDIS_INSPECTOR_INTERVAL = 100;
|
||||
|
||||
public static int REDIS_MAX_IDLE = 10;
|
||||
|
||||
public static int REDIS_MIN_IDLE = 1;
|
||||
|
||||
public static int REDIS_MAX_TOTAL = 30;
|
||||
|
||||
public static int ALARM_EXPIRE_SECONDS = 1000 * 60 * 90;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import com.a.eye.skywalking.health.report.HeathReading;
|
|||
import com.a.eye.skywalking.logging.api.ILog;
|
||||
import com.a.eye.skywalking.logging.api.LogManager;
|
||||
import com.a.eye.skywalking.network.grpc.AckSpan;
|
||||
import com.a.eye.skywalking.routing.alarm.SpanAlarmHandler;
|
||||
import com.a.eye.skywalking.routing.config.Config;
|
||||
import com.a.eye.skywalking.routing.disruptor.AbstractSpanDisruptor;
|
||||
import com.lmax.disruptor.InsufficientCapacityException;
|
||||
|
|
@ -25,7 +26,7 @@ public class AckSpanDisruptor extends AbstractSpanDisruptor {
|
|||
public AckSpanDisruptor(String connectionURL) {
|
||||
ackSpanDisruptor = new Disruptor<AckSpanHolder>(new AckSpanFactory(), Config.Disruptor.BUFFER_SIZE, DaemonThreadFactory.INSTANCE);
|
||||
ackSpanEventHandler = new RouteAckSpanBufferEventHandler(connectionURL);
|
||||
ackSpanDisruptor.handleEventsWith(ackSpanEventHandler);
|
||||
ackSpanDisruptor.handleEventsWith(ackSpanEventHandler, new SpanAlarmHandler());
|
||||
ackSpanDisruptor.start();
|
||||
ackSpanRingBuffer = ackSpanDisruptor.getRingBuffer();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,6 +8,13 @@ import com.a.eye.skywalking.network.grpc.AckSpan;
|
|||
public class AckSpanHolder {
|
||||
private AckSpan ackSpan;
|
||||
|
||||
public AckSpanHolder() {
|
||||
}
|
||||
|
||||
public AckSpanHolder(AckSpan ackSpan) {
|
||||
this.ackSpan = ackSpan;
|
||||
}
|
||||
|
||||
public void setAckSpan(AckSpan ackSpan) {
|
||||
this.ackSpan = ackSpan;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,9 +2,10 @@ package com.a.eye.skywalking.storage.alarm;
|
|||
|
||||
import com.a.eye.skywalking.network.grpc.AckSpan;
|
||||
import com.a.eye.skywalking.network.grpc.TraceId;
|
||||
import com.a.eye.skywalking.storage.alarm.sender.AlarmMessageSender;
|
||||
import com.a.eye.skywalking.storage.alarm.sender.AlarmMessageSenderFactory;
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
import com.a.eye.skywalking.routing.alarm.SpanAlarmHandler;
|
||||
import com.a.eye.skywalking.routing.alarm.sender.AlarmMessageSender;
|
||||
import com.a.eye.skywalking.routing.alarm.sender.AlarmMessageSenderFactory;
|
||||
import com.a.eye.skywalking.routing.disruptor.ack.AckSpanHolder;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
|
@ -25,10 +26,10 @@ public class SpanAlarmHandlerTest {
|
|||
private AlarmMessageSender messageHandler;
|
||||
@InjectMocks
|
||||
private SpanAlarmHandler handler;
|
||||
private AckSpanData normalAckSpan;
|
||||
private AckSpanData costMuchSpan;
|
||||
private AckSpanData costTooMuchSpan;
|
||||
private AckSpanData exceptionSpan;
|
||||
private AckSpanHolder normalAckSpan;
|
||||
private AckSpanHolder costMuchSpan;
|
||||
private AckSpanHolder costTooMuchSpan;
|
||||
private AckSpanHolder exceptionSpan;
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
|
|
@ -40,10 +41,10 @@ public class SpanAlarmHandlerTest {
|
|||
.addSegments(2016).addSegments(startTime).addSegments(2).addSegments(100).addSegments(30)
|
||||
.addSegments(1).build());
|
||||
|
||||
normalAckSpan = new AckSpanData(builder.build());
|
||||
costMuchSpan = new AckSpanData(builder.setCost(600).build());
|
||||
costTooMuchSpan = new AckSpanData(builder.setCost(4000).build());
|
||||
exceptionSpan = new AckSpanData(builder.setCost(20).setStatusCode(1).setExceptionStack("occur exception").build());
|
||||
normalAckSpan = new AckSpanHolder(builder.build());
|
||||
costMuchSpan = new AckSpanHolder(builder.setCost(600).build());
|
||||
costTooMuchSpan = new AckSpanHolder(builder.setCost(4000).build());
|
||||
exceptionSpan = new AckSpanHolder(builder.setCost(20).setStatusCode(1).setExceptionStack("occur exception").build());
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
@ -31,11 +31,7 @@
|
|||
<version>1.17</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>redis.clients</groupId>
|
||||
<artifactId>jedis</artifactId>
|
||||
<version>2.8.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.a.eye</groupId>
|
||||
<artifactId>skywalking-util</artifactId>
|
||||
|
|
|
|||
|
|
@ -1,10 +0,0 @@
|
|||
package com.a.eye.skywalking.storage.alarm.checker;
|
||||
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
|
||||
/**
|
||||
* Created by xin on 2016/12/8.
|
||||
*/
|
||||
public interface ISpanChecker {
|
||||
CheckResult check(AckSpanData span);
|
||||
}
|
||||
|
|
@ -43,22 +43,4 @@ public class Config {
|
|||
public static String PATH_PREFIX = "/skywalking/storage_list/";
|
||||
}
|
||||
|
||||
public static class Alarm {
|
||||
|
||||
public static String REDIS_SERVER = "127.0.0.1:6379";
|
||||
|
||||
public static boolean ALARM_OFF_FLAG = false;
|
||||
|
||||
public static int ALARM_EXCEPTION_STACK_LENGTH = 300;
|
||||
|
||||
public static long ALARM_REDIS_INSPECTOR_INTERVAL = 100;
|
||||
|
||||
public static int REDIS_MAX_IDLE = 10;
|
||||
|
||||
public static int REDIS_MIN_IDLE = 1;
|
||||
|
||||
public static int REDIS_MAX_TOTAL = 30;
|
||||
|
||||
public static int ALARM_EXPIRE_SECONDS = 1000 * 60 * 90;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -86,4 +86,8 @@ public class RequestSpanData extends AbstractSpanData {
|
|||
public String getViewPoint(){
|
||||
return requestSpan.getViewPointId();
|
||||
}
|
||||
|
||||
public String getSpanTypeDesc() {
|
||||
return requestSpan.getSpanTypeDesc();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ public class SpanDataHelper {
|
|||
}
|
||||
|
||||
builder = builder.setLevelId(requestSpanData.getLevelId()).setParentLevelId(requestSpanData.getParentLevelId()).setProcessNo(requestSpanData.getProcessNo())
|
||||
.setSpanType(requestSpanData.getType()).setStartTime(requestSpanData.getStartTime())
|
||||
.setSpanType(requestSpanData.getType()).setSpanTypeDesc(requestSpanData.getSpanTypeDesc()).setStartTime(requestSpanData.getStartTime())
|
||||
.setStatusCode(ackSpanData.getStatusCode())
|
||||
.setViewpoint(requestSpanData.getViewPoint())
|
||||
.setTraceId(TraceId.newBuilder().addAllSegments(Arrays.asList(requestSpanData.getTraceIdSegments())));
|
||||
|
|
|
|||
|
|
@ -7,7 +7,6 @@ import com.a.eye.skywalking.logging.api.LogManager;
|
|||
import com.a.eye.skywalking.network.grpc.AckSpan;
|
||||
import com.a.eye.skywalking.network.grpc.RequestSpan;
|
||||
import com.a.eye.skywalking.network.listener.server.SpanStorageServerListener;
|
||||
import com.a.eye.skywalking.storage.alarm.SpanAlarmHandler;
|
||||
import com.a.eye.skywalking.storage.config.Config;
|
||||
import com.a.eye.skywalking.storage.data.spandata.AckSpanData;
|
||||
import com.a.eye.skywalking.storage.data.spandata.RequestSpanData;
|
||||
|
|
@ -36,7 +35,7 @@ public class StorageListener implements SpanStorageServerListener {
|
|||
requestSpanRingBuffer = requestSpanDisruptor.getRingBuffer();
|
||||
|
||||
ackSpanDisruptor = new Disruptor<AckSpanData>(new AckSpanFactory(), Config.Disruptor.BUFFER_SIZE, DaemonThreadFactory.INSTANCE);
|
||||
ackSpanDisruptor.handleEventsWith(new StoreAckSpanEventHandler(), new SpanAlarmHandler());
|
||||
ackSpanDisruptor.handleEventsWith(new StoreAckSpanEventHandler());
|
||||
ackSpanDisruptor.start();
|
||||
ackSpanRingBuffer = ackSpanDisruptor.getRingBuffer();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,7 @@ public class TraceTreeInfo {
|
|||
|
||||
public void setHasBeenSpiltNodes(List<TraceNodeInfo> nodes) {
|
||||
this.nodes = nodes;
|
||||
this.nodeSize = nodes.size();
|
||||
}
|
||||
|
||||
public void setRealNodeSize(int nodeSize) {
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@
|
|||
<li class="list-group-item"><strong>花费时间:</strong>{{>cost}}<strong>毫秒</strong></li>
|
||||
<li class="list-group-item"><strong>业务字段:</strong>{{>businessKey}}</li>
|
||||
<li class="list-group-item"><strong>应用Code:</strong>{{>applicationCode}}</li>
|
||||
<li class="list-group-item"><strong>主机信息:</strong>{{>address}}}</li>
|
||||
<li class="list-group-item"><strong>主机信息:</strong>{{>address}}</li>
|
||||
<li class="list-group-item"><strong>调用进程号:</strong>{{>processNo}}</li>
|
||||
<li class="list-group-item"><strong>异常堆栈:</strong>
|
||||
{{if exceptionStack}}
|
||||
|
|
|
|||
Loading…
Reference in New Issue