ThreadRenamingRunnable

Jason Stevens jstevens at pillardata.com
Wed Jun 10 10:56:33 EDT 2009


Thanks! :)

-----Original Message-----
From: netty-users-bounces at lists.jboss.org [mailto:netty-users-bounces at lists.jboss.org] On Behalf Of "??? (Trustin Lee)"
Sent: Wednesday, June 10, 2009 2:58 AM
To: netty-users at lists.jboss.org
Subject: Re: ThreadRenamingRunnable

Here the fix comes:

https://jira.jboss.org/jira/browse/NETTY-172

HTH :)
Trustin

On 2009-06-10 오후 4:47, "이희승 (Trustin Lee)" wrote:
> Hi Jason,
> 
> Sorry about the late reply first of all.
> 
> I like your idea and will implement it as you suggested.
> 
> Thanks!
> Trustin
> 
> On 2009-06-05 오전 7:09, jasons2645 wrote:
>>
>> I am running into a similar issue where it would be nice to have control over
>> thread names.  A suggestion for solving this...
>>
>> Since ThreadRenamingRunnable is a public class, it seems like a good way to
>> provide this customization would be to introduce an interface named
>> something like ThreadNameDeterminer which would have a single method: String
>> determineThreadName( String originalThreadName, String
>> nettyProposedThreadName );  
>>
>> DefaultThreadNameDeterminer could be installed by default on
>> ThreadRenamingRunnable, and modified by a client via a static setter method. 
>> DefaultThreadNameDeterminer would just return the netty-proposed thread
>> name.  
>>
>> This would give users the flexibility to do whatever they want wrt thread
>> naming while providing good default behavior; it also eliminates the need to
>> try to 'find out' if the user has set a thread name themselves.
>>
>>>>> However, I agree with you that it would be nice if 'New I/O
>>>>> (client|server) (boss|worker)' could be customizable.  Perhaps
>>>>> ThreadRenamingRunnable could be improved so that it does not rename
>>>>> the current thread completely but append additional information to the
>>>>> current thread name if a user set the thread name already?
>>>>
>>>> Hmm.. but how do I determine 'if a user set the thread name already?'
>>>> That's a tricky problem..
> 
> 


-- 
- Trustin Lee, http://gleamynode.net/





More information about the netty-users mailing list