Pinpoint: Group the request and report the call-chain by the request group.

Created on 26 Dec 2018  路  8Comments  路  Source: pinpoint-apm/pinpoint

Which module is your feature request related to?
ALL

Is your feature request related to a problem?
NO

Describe the solution you'd like
I found that the requests are grouped by the business in some apm product for example the dynatrace.

For example when the target app is based on spring mvc.
The requests are grouped by the handler methods which has RequestMapping annotations.
And report the call-chain data by the group.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

stale

Most helpful comment

sorry, we named the call stack in pinpoint with call-chain.

Yes, I suggest to group the call stack with URL statistics.

For example there is some code in the Spring MVC as following.

@Controller
public class SecondController {

    @GetMapping("/address/{name}")
    @ResponseBody
    public List<String> address(@PathVariable("name") String name) {
        List<String> address = new ArrayList<>();
        address.add("first");
        address.add("second");
        return address;
    }
}

We can group the callstack all the request which is handled by the annotation of the method address, even more we can report the callstack by this to avoid that some handler is missed.

what do you think about it.

All 8 comments

hi guys, I am a java developer and I am interested in pinpoint. If pinpoint plan to accept my suggestion, I can contribute my code. thanks guys. looking forward for your final decision.

@xiaoshao Hi
I do not know what the call-chain means.
Does this feature mean URL statistics?

Example Screenshot
https://github.com/slanatech/swagger-stats/raw/master/screenshots/methods.png?raw=true
image

sorry, we named the call stack in pinpoint with call-chain.

Yes, I suggest to group the call stack with URL statistics.

For example there is some code in the Spring MVC as following.

@Controller
public class SecondController {

    @GetMapping("/address/{name}")
    @ResponseBody
    public List<String> address(@PathVariable("name") String name) {
        List<String> address = new ArrayList<>();
        address.add("first");
        address.add("second");
        return address;
    }
}

We can group the callstack all the request which is handled by the annotation of the method address, even more we can report the callstack by this to avoid that some handler is missed.

what do you think about it.

We welcome your suggestions

I agree with your idea.
We have plans to aggregate statistical data into the RequestMapping annotations,
but we do not have enough time to develop.

Below is our idea.

  1. Use RequestMapping annotation.

    • When using real url, it is difficult to aggregate rest style url



      • eg: /book/{id}/



  1. Unable to handle annotation in bytecode api

    • We will add API
    • If the annotation data can be extracted to the runtime, API addition is unnecessary
  2. Aggregation plan
    聽聽聽 1. agent memory
    聽聽聽 2. collector
    聽聽聽聽聽 - Use the Table.incrementColumnValue() API of hbase
    聽聽聽 3. flink
    聽聽聽 Not determined

  3. Data type
    聽聽聽 1. Histogram
    聽聽聽聽聽聽聽 - Counts 1s, 3s, 5s
    聽聽聽聽 2. totalAverage reponse time
    聽聽聽 Not determined

@emeroad My idea focus on the javaagent.

I found that the spring MVC register the handler in AbstractUrlHandlerMapping and AbstractHandlerMethodMapping After read the spring mvc code.

  1. We can add interceptor for these classes to collected all the rest uri.
  2. match the uri in the request with the rest uri we collected in the first step.
  3. Create a new sampler for the callstack reporting according the rest uri as the replacement of SamplingRateSampler
  4. Add a new field transactionType in TraceId or TraceRoot => looking forward for you suggesting which one is better.
  5. Add a new field transactionType in span in order that we can group the callstack by transaction type.
  6. Add transaction type as the http header to the http request.

After finished this, I can do more thing for other module.

what do u think about it ?

This issue/proposal has been automatically marked as stale because it hasn't had any recent activity. It will automatically be closed if no further activity occurs for 20days. If you think this should still be open, or the problem still persists, just pop a reply in the comments and one of the maintainers will (try!) to follow up. Thank you for your interest and contribution to the Pinpoint Community.

This issue/proposal has been automatically marked as stale because it hasn't had any recent activity. It will automatically be closed if no further activity occurs for 20days. If you think this should still be open, or the problem still persists, just pop a reply in the comments and one of the maintainers will (try!) to follow up. Thank you for your interest and contribution to the Pinpoint Community.

Was this page helpful?
0 / 5 - 0 ratings