On Wed, Feb 3, 2010 at 7:31 PM, Emmanuel LŽcharny <[email protected]> wrote:
> Muhammad Ichsan a écrit :
>>
>> Dear All,
>>
>> I'm using Mina 2 with TextLineCodeFactory as the protocol codec. As
                                     ^^^^^^^^^^^^^^^^^^^^^^^^
>
> Simply add a '\n' at the end of each message. The codec you are using
> (Text*Line*Codec) is expeciting to see *lines*, not messages.
>
>

It just don't work (as I thought), because I'm using mina not plain
socket. From plain socket, I do have to use '\n'. Have you seen my
code? I the codec factory already handle this.

The messages are delivered all together not one by one. Look at this result:

--0
--1
--2
--3
--4
--5
--6
--7
--8
--9
--10
--11
--12
--13
--14
--15
--16
--17
--18
--19

Got from client: Client.message.0
Got from client: Client.message.1
Got from client: Client.message.2
Got from client: Client.message.3
Got from client: Client.message.4
Got from client: Client.message.5
Got from client: Client.message.6
Got from client: Client.message.7
Got from client: Client.message.8
Got from client: Client.message.9
Got from client: Client.message.10
On server took: 2
Got from client: Client.message.11
Got from client: Client.message.12
Got from client: Client.message.13
Got from client: Client.message.14
Got from client: Client.message.15
Got from client: Client.message.16
Got from client: Client.message.17
Got from client: Client.message.18
Got from client: Client.message.19


-- 
~The best men are men who benefit to others
http://michsan.web.id

Yang berkualitas memang beda rasanya!
http://rizqi-cookies.com

Reply via email to