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

Colin Patrick McCabe commented on HTRACE-358:
---------------------------------------------

Seems reasonable.  I wish there were a more elegant way to do this without 
creating another subclass, but I don't see one.  I like the overload on 
{{Tracer#newTraceExecutorService}}.

{code}
87        protected Runnable wrap(Runnable runnable) {
88          return tracer.wrap(runnable, scopeName);
89        }
90      
91        protected <V> Callable<V> wrap(Callable<V> callable) {
92          return tracer.wrap(callable, scopeName);
93        }
{code}
Hmm.  Rather than adding these new APIs, can we just have an API for getting 
the Tracer owned by the base class?  The derived class has access to this 
anyway because it needs it to construct the base class.  I would also prefer 
that this method be package-private for now rather than protected... let's keep 
the API surface small.

> Provide convenience wrapper around ScheduledExecutorService
> -----------------------------------------------------------
>
>                 Key: HTRACE-358
>                 URL: https://issues.apache.org/jira/browse/HTRACE-358
>             Project: HTrace
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 4.1
>            Reporter: Mike Drob
>            Assignee: Mike Drob
>         Attachments: HTRACE-358.patch.txt
>
>
> We already provide a convenience wrapper around {{ExecutorService}}, it would 
> not be onerous to also provide a wrapper around {{ScheduledExecutorService}}



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

Reply via email to