Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Example Queries #38

Open
taegyunkim opened this issue Sep 3, 2020 · 1 comment
Open

Example Queries #38

taegyunkim opened this issue Sep 3, 2020 · 1 comment

Comments

@taegyunkim
Copy link
Collaborator

taegyunkim commented Sep 3, 2020

Queries that outputs filter.cc file that can successfully compiled.

  1. How many traces went through a particular microservice A?
    MATCH n WHERE n.service_name == A RETURN count; count is a udf function which increments a counter by a whenever we see a request

  2. How many traces went through microservices A, B, and C in that order?
    MATCH x->y, y->z, WHERE x.service_name==a, y.service_name==b, z.service_name==c, RETURN count

  3. Get me the name of the service with highest latency
    MATCH x WHERE x.service_name == frontend RETURN max_latency
    max_latency is a udf

Need further development

Latency

Latency is not a supported property

  1. What is the average latency of an RPC from microservice A to microservice B?
    MATCH x->y WHERE x.service_name==a, y.service_name==b GROUP y.latency BY avg

  2. Get me a histogram of end-to-end trace latencies or RPC latencies?
    MATCH x WHERE x.service_name == frontend GROUP x.latency BY histogram

Graph depth & and breadth

They're both graph properties and can be implemented by providing udfs.

  1. Get me a histogram of trace service depths
    MATCH x WHERE x.service_name == frontend GROUP x.depth BY histogram

  2. Get me a histogram of trace service breadths (the maximum fan out to child spans)
    MATCH x WHERE x.service_name == frontend GROUP x.breadth BY histogram

@taegyunkim taegyunkim changed the title Convert example english written queries to our query language Example Queries Sep 11, 2020
@taegyunkim
Copy link
Collaborator Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant