[JBoss JIRA] Closed: (NETTY-223) Netty renames configured thread name for threads executing in a pool

Trustin Lee (JIRA) jira-events at lists.jboss.org
Thu Sep 3 22:19:23 EDT 2009


     [ https://jira.jboss.org/jira/browse/NETTY-223?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Trustin Lee closed NETTY-223.
-----------------------------

    Resolution: Won't Fix


Actually, you can deny the attempt to rename the threads with ThreadNameDeterminer by calling ThreadRenamingRunnable.setThreadNameDeterminer - just return null.



> Netty renames configured thread name for threads executing in a pool
> --------------------------------------------------------------------
>
>                 Key: NETTY-223
>                 URL: https://jira.jboss.org/jira/browse/NETTY-223
>             Project: Netty
>          Issue Type: Feature Request
>            Reporter: Elias Ross
>            Assignee: Trustin Lee
>
> It was a little bit of a surprise to discover that the names of the threads from the factory, for executors created by Executors.newCachedThreadPool(ThreadFactory tf), were renamed by Netty.
> Usually threads are named upon creation by the thread pool and not renamed. In my experience, at least.
> (If they were renamed to something, it'd be nice to associate it with a particular server instance, like the port. They're pretty generic at the moment.)
> Maybe Netty simply needs to be shipped with a factory class similar to Executors, which creates a thread pool with naming you use internally.
>         NioServerSocketChannelFactory factory = 
>             new NioServerSocketChannelFactory(
>                     NettyExecutors.bossThreadPool(),
>                     NettyExecutors.workerThreadPool()
>                     );
> And why not simply have:
>         NioServerSocketChannelFactory factory = 
>             new NioServerSocketChannelFactory();
> I have a lot of different sorts of handlers and would like to keep them straight. ThreadGroups are one option, but their names don't get logged in the system log with Log4j.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the netty-dev mailing list