implementation of blocking input

Bill Burke bburke at redhat.com
Wed Oct 19 13:53:45 EDT 2011


My problem is I'm a noob when it comes to NIO and I'm not sure of the 
consequences of my actions...

It just seems to be able to support non-blocking and blocking IO 
together you need a way to switch to and from a thread per connection model.

On 10/19/11 12:08 PM, Ross Lambert wrote:
> Hi Bill,
>
> I would love to see this implemented in Netty. Our use cases are almost all asynch/non-blocking and Netty has therefore been a fantastic foundation for us. But we have one very irritating case which would be best coded as a blocking call, exactly as you have described it. By "best" I mean least amount of code for me. :-)
>
> I may have some cycles next week for this if you want/need any help. Otherwise, please let me know when you're done, especially if you need a tester. Feel free to contact me directly.
>
> Thanks!
>
> == Ross ==
>
> -----Original Message-----
> From: netty-users-bounces at lists.jboss.org [mailto:netty-users-bounces at lists.jboss.org] On Behalf Of Bill Burke
> Sent: Wednesday, October 19, 2011 8:59 AM
> To: netty-users at lists.jboss.org
> Subject: Re: implementation of blocking input
>
> Thats the plan!  I just wanted to get some feedback from here.
>
> On 10/19/11 5:49 AM, Norman Maurer wrote:
>> BTW, if you have something better in-mind you can also fork it, write
>> a patch and then issue a pull request.
>>
>> It's opensource ;)
>>
>> Bye,
>> Norman
>>
>>
>> 2011/10/19 ljohnston<johnstlr at yahoo.co.uk>:
>>> Hi Bill
>>>
>>> I remember you making this point previously.
>>>
>>> Here's a really horrible suggestion that could break in future.
>>> NioSocketChannel stores the current NioWorker as a package protected member.
>>> NioWorker also stores the current selector as a package protected field.
>>> Could you create a class in a package that parallels the
>>> org.jboss.netty.channel.socket.nio package and expose the selector.
>>> The relevant fields are
>>>
>>> NioSocketChannel.worker
>>> NioWorker.selector
>>>
>>> Perhaps raise an enhancement request to provide a proper way of doing this?
>>>
>>> Cheers
>>> Lee
>>>
>>>
>>> bburke wrote:
>>>>
>>>> I don't want to do context switching between a reader thread and the
>>>> application as it just doesn't perform as well as real, blocking I/O.
>>>>
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://netty-forums-and-mailing-lists.685743.n2.nabble.com/implementa
>>> tion-of-blocking-input-tp6902613p6907929.html
>>> Sent from the Netty User Group mailing list archive at Nabble.com.
>>> _______________________________________________
>>> netty-users mailing list
>>> netty-users at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/netty-users
>>>
>> _______________________________________________
>> netty-users mailing list
>> netty-users at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/netty-users
>
> --
> Bill Burke
> JBoss, a division of Red Hat
> http://bill.burkecentral.com
> _______________________________________________
> netty-users mailing list
> netty-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/netty-users
>
>
> _______________________________________________
> netty-users mailing list
> netty-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/netty-users

-- 
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com


More information about the netty-users mailing list