[ 
https://issues.apache.org/jira/browse/HTRACE-363?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15275726#comment-15275726
 ] 

Mike Drob commented on HTRACE-363:
----------------------------------

Something like...

{code}
TraceScope scope = tracer.newScope();
SpanId other = new SpanId(...);
TraceScope child = tracer.newScope(x);
{code}

In this example, if I understood correctly `child` would have two parents -- 
`scope` and `other`. I almost broke this behaviour on another issue because we 
don't have tests to verify that our APIs work this way and it was not 
immediately clear from the docs and examples we have.

> Add tests for newScope with parent id
> -------------------------------------
>
>                 Key: HTRACE-363
>                 URL: https://issues.apache.org/jira/browse/HTRACE-363
>             Project: HTrace
>          Issue Type: Test
>          Components: core
>            Reporter: Mike Drob
>
> We should add some tests to verify that when there is a currently active 
> scope and `newScope` is called with a valid parent id that both are included 
> in the child span. The current code does this correctly, I think, but we 
> should have tests to prevent accidental regressions in the future.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to