Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 33d7d3c

Browse files
committedMay 17, 2023
[#9666] Add redis pubsub atc,atd,echo
1 parent 455c291 commit 33d7d3c

File tree

143 files changed

+7599
-415
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

143 files changed

+7599
-415
lines changed
 

‎collector/src/main/java/com/navercorp/pinpoint/collector/CollectorAppPropertySources.java

+4
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
@PropertySource(name = "CollectorAppPropertySources", value = { CollectorAppPropertySources.COLLECTOR_ROOT, CollectorAppPropertySources.COLLECTOR_PROFILE}),
2525
@PropertySource(name = "CollectorAppPropertySources-GRPC", value = { CollectorAppPropertySources.GRPC_ROOT, CollectorAppPropertySources.GRPC_PROFILE}),
2626
@PropertySource(name = "CollectorAppPropertySources-JDBC", value = { CollectorAppPropertySources.JDBC_ROOT, CollectorAppPropertySources.JDBC_PROFILE}),
27+
@PropertySource(name = "CollectorAppPropertySources-Redis", value = { CollectorAppPropertySources.REDIS_ROOT, CollectorAppPropertySources.REDIS_PROFILE}),
2728
})
2829
public final class CollectorAppPropertySources {
2930
public static final String GRPC_ROOT = "classpath:pinpoint-collector-grpc-root.properties";
@@ -32,6 +33,9 @@ public final class CollectorAppPropertySources {
3233
public static final String JDBC_ROOT = "classpath:jdbc-root.properties";
3334
public static final String JDBC_PROFILE = "classpath:profiles/${pinpoint.profiles.active:local}/jdbc.properties";
3435

36+
public static final String REDIS_ROOT = "classpath:redis-root.properties";
37+
public static final String REDIS_PROFILE = "classpath:profiles/${pinpoint.profiles.active:local}/redis.properties";
38+
3539
public static final String COLLECTOR_ROOT = "classpath:pinpoint-collector-root.properties";
3640
public static final String COLLECTOR_PROFILE = "classpath:profiles/${pinpoint.profiles.active:local}/pinpoint-collector.properties";
3741

‎collector/src/main/java/com/navercorp/pinpoint/collector/cluster/route/AbstractRouteHandler.java

+5-3
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,8 @@
2222
import com.navercorp.pinpoint.thrift.dto.command.TCommandTransfer;
2323
import com.navercorp.pinpoint.thrift.dto.command.TCommandTransferResponse;
2424
import com.navercorp.pinpoint.thrift.dto.command.TRouteResult;
25-
26-
import org.apache.logging.log4j.Logger;
2725
import org.apache.logging.log4j.LogManager;
26+
import org.apache.logging.log4j.Logger;
2827

2928
import java.util.ArrayList;
3029
import java.util.List;
@@ -47,7 +46,10 @@ protected ClusterPoint<?> findClusterPoint(TCommandTransfer deliveryCommand) {
4746
String agentId = deliveryCommand.getAgentId();
4847
long startTimeStamp = deliveryCommand.getStartTime();
4948
final ClusterKey sourceKey = new ClusterKey(applicationName, agentId, startTimeStamp);
49+
return findClusterPoint(sourceKey);
50+
}
5051

52+
public ClusterPoint<?> findClusterPoint(ClusterKey sourceKey) {
5153
List<ClusterPoint<?>> result = new ArrayList<>();
5254

5355
for (ClusterPoint<?> targetClusterPoint : targetClusterPointLocator.getClusterPointList()) {
@@ -62,7 +64,7 @@ protected ClusterPoint<?> findClusterPoint(TCommandTransfer deliveryCommand) {
6264
}
6365

6466
if (result.size() > 1) {
65-
logger.warn("Ambiguous ClusterPoint {}, {}, {} (Valid Agent list={}).", applicationName, agentId, startTimeStamp, result);
67+
logger.warn("Ambiguous ClusterPoint {} (Valid Agent list={}).", sourceKey, result);
6668
return null;
6769
}
6870

0 commit comments

Comments
 (0)
Please sign in to comment.