mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DIRMINA-655) Add a more general purpose text based decoder
Date Wed, 07 Jan 2009 00:05:44 GMT

    [ https://issues.apache.org/jira/browse/DIRMINA-655?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12661385#action_12661385

Emmanuel Lecharny commented on DIRMINA-655:

Thinking a bit more about the proposal :

As you know, you have no guarantee that a terminated message will be transmitted in one single
block. What if the received bytes just get decoded and the regexp is partially matched ? 

For instance using the LINE_TERM regexp, what if we receive \r\n in two messages ? I guess
that you will match LINE_TERM twice, and potentially consider that you have two lines to deal
with, when it's just an artefact, as the sender really wanted to terminate its message with
a '\r\n'

This is where it gets tricky ...

> Add a more general purpose text based decoder
> ---------------------------------------------
>                 Key: DIRMINA-655
>                 URL: https://issues.apache.org/jira/browse/DIRMINA-655
>             Project: MINA
>          Issue Type: New Feature
>    Affects Versions: 2.0.0-M4
>         Environment: Mina 2.0.0-M4, Java 1.6, Fedora 10
>            Reporter: Matthieu Chase Heimer
>            Priority: Minor
>         Attachments: RegExDecoder.java
> There are many text based protocols who have messages that are terminated by a delimiter
other than an end of line. A protocol decoder that is more generic than TextLineDecoder would
be a nice addition. It should also be easy to extend so developers can focus on coverting
text messages to domain objects and not on converting  and parsing IoBuffers.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message