mirror of
https://github.com/wahyd4/pinpoint.git
synced 2026-08-18 17:26:14 +10:00
[유치수] [NOBTS] add applicationName
git-svn-id: http://svn.bds.nhncorp.com/pe/hippo-web/trunk@846 84d0f5b1-2673-498c-a247-62c4ff18d310
This commit is contained in:
@@ -32,8 +32,7 @@ public class FlowChartController {
|
||||
|
||||
@RequestMapping(value = "/flow", method = RequestMethod.GET)
|
||||
public String flow(Model model, @RequestParam("application") String applicationName, @RequestParam("from") long from, @RequestParam("to") long to) {
|
||||
String[] agentIds = flow.selectAgentIdsFromApplicationName(applicationName);
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromTraceIndex(agentIds, from, to);
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromApplicationTraceIndex(applicationName, from, to);
|
||||
|
||||
RPCCallTree callTree = flow.selectRPCCallTree(traceIds);
|
||||
|
||||
@@ -47,15 +46,62 @@ public class FlowChartController {
|
||||
|
||||
@RequestMapping(value = "/flowserver", method = RequestMethod.GET)
|
||||
public String flowserver(Model model, @RequestParam("application") String applicationName, @RequestParam("from") long from, @RequestParam("to") long to) {
|
||||
String[] agentIds = flow.selectAgentIdsFromApplicationName(applicationName);
|
||||
// TODO 제거 하거나, interceptor로 할것.
|
||||
StopWatch watch = new StopWatch();
|
||||
watch.start("scanTraceindex");
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromTraceIndex(agentIds, from, to);
|
||||
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromApplicationTraceIndex(applicationName, from, to);
|
||||
|
||||
watch.stop();
|
||||
logger.info("time:{} {}", watch.getLastTaskTimeMillis(), traceIds.size());
|
||||
watch.start("selectServerCallTree");
|
||||
|
||||
ServerCallTree callTree = flow.selectServerCallTree(traceIds);
|
||||
|
||||
watch.stop();
|
||||
logger.info("time:{}", watch.getLastTaskTimeMillis());
|
||||
|
||||
model.addAttribute("nodes", callTree.getNodes());
|
||||
model.addAttribute("links", callTree.getLinks());
|
||||
model.addAttribute("businessTransactions", callTree.getBusinessTransactions().getBusinessTransactionIterator());
|
||||
model.addAttribute("traces", callTree.getBusinessTransactions().getTracesIterator());
|
||||
|
||||
logger.debug("callTree:{}", callTree);
|
||||
|
||||
return "flowserver";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/flow2", method = RequestMethod.GET)
|
||||
public String flowbyHost(Model model, @RequestParam("host") String[] hosts, @RequestParam("from") long from, @RequestParam("to") long to) {
|
||||
String[] agentIds = flow.selectAgentIds(hosts);
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromTraceIndex(agentIds, from, to);
|
||||
|
||||
RPCCallTree callTree = flow.selectRPCCallTree(traceIds);
|
||||
|
||||
model.addAttribute("nodes", callTree.getNodes());
|
||||
model.addAttribute("links", callTree.getLinks());
|
||||
|
||||
logger.debug("callTree:{}", callTree);
|
||||
|
||||
return "flow";
|
||||
}
|
||||
|
||||
@RequestMapping(value = "/flowserver2", method = RequestMethod.GET)
|
||||
public String flowserverByHost(Model model, @RequestParam("host") String[] hosts, @RequestParam("from") long from, @RequestParam("to") long to) {
|
||||
String[] agentIds = flow.selectAgentIds(hosts);
|
||||
|
||||
// TODO 제거 하거나, interceptor로 할것.
|
||||
StopWatch watch = new StopWatch();
|
||||
watch.start("scanTraceindex");
|
||||
|
||||
Set<TraceId> traceIds = flow.selectTraceIdsFromTraceIndex(agentIds, from, to);
|
||||
|
||||
watch.stop();
|
||||
logger.info("time:{} {}", watch.getLastTaskTimeMillis(), traceIds.size());
|
||||
watch.start("selectServerCallTree");
|
||||
|
||||
ServerCallTree callTree = flow.selectServerCallTree(traceIds);
|
||||
|
||||
watch.stop();
|
||||
logger.info("time:{}", watch.getLastTaskTimeMillis());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user