Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-20 Thread Enrico Olivelli
+1 on 3 forse me too Il mar 20 mar 2018, 09:15 Sijie Guo ha scritto: > On Tue, Mar 20, 2018 at 12:50 AM, Ivan Kelly wrote: > > > On Mon, Mar 19, 2018 at 6:37 PM, Sijie Guo wrote: > > > It is not a blocker for me. > > > > > > But if we

Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-20 Thread Sijie Guo
On Tue, Mar 20, 2018 at 12:50 AM, Ivan Kelly wrote: > On Mon, Mar 19, 2018 at 6:37 PM, Sijie Guo wrote: > > It is not a blocker for me. > > > > But if we want consistency, either applying pattern "asyncXYZ()" or > > "xyzAsync()" for async operations works

Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-20 Thread Ivan Kelly
On Mon, Mar 19, 2018 at 6:37 PM, Sijie Guo wrote: > It is not a blocker for me. > > But if we want consistency, either applying pattern "asyncXYZ()" or > "xyzAsync()" for async operations works for me. xyzAsync is better than asyncXyz, as it will put the async and sync

Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-19 Thread Sijie Guo
It is not a blocker for me. But if we want consistency, either applying pattern "asyncXYZ()" or "xyzAsync()" for async operations works for me. - Sijie On Mon, Mar 19, 2018 at 4:20 AM, Ivan Kelly wrote: > Hi folks, > > I'm currently changing some parts of pulsar to use the

Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-19 Thread Ivan Kelly
> Is implementing Closable a "valueable" feature for us in the new API ? (I > think the answer is 'yes') I'm not so sure how useful Closeable is here. It is handy in tests, but in production code you are never going to use the try-with-resources pattern, as you'll be using async calls for

Re: [DISCUSS] Inconsistency in Handle based APIs - Specifically "close"

2018-03-19 Thread Enrico Olivelli
2018-03-19 12:20 GMT+01:00 Ivan Kelly : > Hi folks, > > I'm currently changing some parts of pulsar to use the new APIs and > the inconsistency in the close api has raised its head again, so I'm > restarting this discussion. > > Handle has the following methods: > async: