You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by Trustin Lee <tr...@gmail.com> on 2007/04/12 11:23:24 UTC
New feature in 2.0: Request-Response Filter
Hi folks,
Today, I added a new feature to the trunk. The issue has been filed
since the early days of MINA, but we didn't give it high priority
because it was a good-to-have feature. I apologize those who wait for
this issue to be resolved for a long time.
The Request-Response filter is very useful for a client application
that deals with a request-response protocol. Please refer to my last
comment of the following JIRA page for the detailed explanation and
example:
https://issues.apache.org/jira/browse/DIRMINA-92#action_12488311
Any questions and additional feature request on this filter are welcome.
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP Key ID: 0x0255ECA6
Re: New feature in 2.0: Request-Response Filter
Posted by Trustin Lee <tr...@gmail.com>.
Hi John,
On 4/13/07, John E. Conlon <jc...@verticon.com> wrote:
> Hi Trustin,
>
> Just updated my working trunk and I noticed a problem with the feature
> you just added.
>
> The class RequestTimeoutException extends IOException and tries to call
> the superclass constructor with inappropriate arguments. (IOException
> has a paramaterless constructor and one that accepts a string.)
They were added since JDK 1.6. I made it backward-compatible now.
Thanks for the heads up!
> BTW - Those are some very beautiful wedding photos. Hearty
> congratulations.
:D
Trustin
--
what we call human nature is actually human habit
--
http://gleamynode.net/
--
PGP Key ID: 0x0255ECA6
Re: New feature in 2.0: Request-Response Filter
Posted by Emmanuel Lecharny <el...@gmail.com>.
gh_aiyz a écrit :
>Hi all, where can I get the latest code of mina 2.0?
>
>
Hi,
you can 'svn co http://svn.apache.org/repos/asf/mina/trunk/', this is
the trunk, containing the 2.0.0 current development version
Emmanuel
Re: Re: New feature in 2.0: Request-Response Filter
Posted by gh_aiyz <gh...@hotmail.com>.
Hi all, where can I get the latest code of mina 2.0?
Thanks
gh_aiyz
2007-04-14
发件人: John E. Conlon
发送时间: 2007-04-13 04:01:32
收件人: dev@mina.apache.org
抄送:
主题: Re: New feature in 2.0: Request-Response Filter
Hi Trustin,
Just updated my working trunk and I noticed a problem with the feature
you just added.
The class RequestTimeoutException extends IOException and tries to call
the superclass constructor with inappropriate arguments. (IOException
has a paramaterless constructor and one that accepts a string.)
public RequestTimeoutException(Request request, String message,
Throwable cause) {
super(message, cause);
...
public RequestTimeoutException(Request request, Throwable cause) {
super(cause);
...
cheers,
John
BTW - Those are some very beautiful wedding photos. Hearty
congratulations.
Trustin Lee wrote:
> Hi folks,
>
> Today, I added a new feature to the trunk. The issue has been filed
> since the early days of MINA, but we didn't give it high priority
> because it was a good-to-have feature. I apologize those who wait for
> this issue to be resolved for a long time.
>
> The Request-Response filter is very useful for a client application
> that deals with a request-response protocol. Please refer to my last
> comment of the following JIRA page for the detailed explanation and
> example:
>
> https://issues.apache.org/jira/browse/DIRMINA-92#action_12488311
>
> Any questions and additional feature request on this filter are welcome.
>
> Trustin
Re: New feature in 2.0: Request-Response Filter
Posted by "John E. Conlon" <jc...@verticon.com>.
Hi Trustin,
Just updated my working trunk and I noticed a problem with the feature
you just added.
The class RequestTimeoutException extends IOException and tries to call
the superclass constructor with inappropriate arguments. (IOException
has a paramaterless constructor and one that accepts a string.)
public RequestTimeoutException(Request request, String message,
Throwable cause) {
super(message, cause);
...
public RequestTimeoutException(Request request, Throwable cause) {
super(cause);
...
cheers,
John
BTW - Those are some very beautiful wedding photos. Hearty
congratulations.
Trustin Lee wrote:
> Hi folks,
>
> Today, I added a new feature to the trunk. The issue has been filed
> since the early days of MINA, but we didn't give it high priority
> because it was a good-to-have feature. I apologize those who wait for
> this issue to be resolved for a long time.
>
> The Request-Response filter is very useful for a client application
> that deals with a request-response protocol. Please refer to my last
> comment of the following JIRA page for the detailed explanation and
> example:
>
> https://issues.apache.org/jira/browse/DIRMINA-92#action_12488311
>
> Any questions and additional feature request on this filter are welcome.
>
> Trustin
Re: New feature in 2.0: Request-Response Filter
Posted by Maarten Bosteels <mb...@gmail.com>.
Hi folks,
Until now I had only implemented server apps with MINA (IoAcceptor), and no
client apps (IoConnector).
I started working on a small tutorial about ProtocolDecoder/ProtocolEncoder
to complement Mark's Getting Started Guide,
and while implementing the client side I was wondering if a ReadFuture would
be an interesting feauture.
Suppose you have a request-response protocol and you want to implement the
client synchronously:
connect, send a request and wait until the response comes in.
What is currently the best way to go ?
With a ReadFuture it could be done like this:
Object request = ...;
ConnectFuture connectFuture = connector.connect(new
InetSocketAddress("localhost",5555));
connectFuture.join(100);
if (connectFuture.isConnected()) {
IoSession session = connectFuture.getSession();
session.write( request );
ReadFuture readFuture = session.read();
readFuture.join();
if (readFuture.messageRead()) {
Object response = readFuture.getResult();
doSomethingWith(response);
}
session.close().join();
}
What do you think ?
Maarten
On 4/12/07, Trustin Lee <tr...@gmail.com> wrote:
>
> Hi folks,
>
> Today, I added a new feature to the trunk. The issue has been filed
> since the early days of MINA, but we didn't give it high priority
> because it was a good-to-have feature. I apologize those who wait for
> this issue to be resolved for a long time.
>
> The Request-Response filter is very useful for a client application
> that deals with a request-response protocol. Please refer to my last
> comment of the following JIRA page for the detailed explanation and
> example:
>
> https://issues.apache.org/jira/browse/DIRMINA-92#action_12488311
>
> Any questions and additional feature request on this filter are welcome.
>
> Trustin
> --
> what we call human nature is actually human habit
> --
> http://gleamynode.net/
> --
> PGP Key ID: 0x0255ECA6
>