You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by "Hanson Char (JIRA)" <ji...@apache.org> on 2006/07/04 19:46:29 UTC

[jira] Created: (DIRMINA-224) Data Corruption

Data Corruption
---------------

         Key: DIRMINA-224
         URL: http://issues.apache.org/jira/browse/DIRMINA-224
     Project: Directory MINA
        Type: Bug

    Versions: 0.8.2    
 Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
java version "1.5.0_05"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
    Reporter: Hanson Char


Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (DIRMINA-224) Data Corruption

Posted by "Hanson Char (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/DIRMINA-224?page=comments#action_12419591 ] 

Hanson Char commented on DIRMINA-224:
-------------------------------------

I can see why the Decoder needs to be created with new instances.  
However, the Encoder is entirely stateless.  So singleton will work just fine.  What am I missing here ?

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>     Assignee: Trustin Lee
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (DIRMINA-224) Data Corruption

Posted by "Hanson Char (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]

Hanson Char updated DIRMINA-224:
--------------------------------

    Attachment: TEST-test.JUnitTest.jar

Here is the log file of a sample junit test run on Linux 7.2.   Simply

  jar xf TEST-test.JUnitTest.jar

to expand and access the TEST-test.JUnitTest.txt.

The problems can be seen to occur at lines:
707, 806, 992, 1110

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>     Versions: 0.8.2
>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>  Attachments: Mina-0.8.2-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (DIRMINA-224) Data Corruption

Posted by "Hanson Char (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]

Hanson Char updated DIRMINA-224:
--------------------------------

    Attachment: Mina-0.9.4-bug.jar

I ported the test harness to use Mina 0.9.4 and it seems the problem went away.

Attached is the 0.9.4 version of the same test harness.

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>     Versions: 0.8.2
>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (DIRMINA-224) Data Corruption

Posted by "Hanson Char (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]

Hanson Char updated DIRMINA-224:
--------------------------------

    Attachment: Mina-0.8.2-bug.jar

You can run the test on Linux 7.2 to see the problem:

Type:

jar xf Mina-0.8.2-bug.jar
ant

(Apache Ant version 1.6.5 compiled on June 2 2005)

The junit test almost always failed on Linux 7.2., but never faile on Windows XP.

In one sample run:
1) the expected "message Testing 212" gets corrupted to become "ing 212"
2) the expected "pingpong" message sometimes gets corrupted to become "g"




> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>     Versions: 0.8.2
>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>  Attachments: Mina-0.8.2-bug.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Resolved: (DIRMINA-224) Data Corruption

Posted by "Trustin Lee (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]
     
Trustin Lee resolved DIRMINA-224:
---------------------------------

    Resolution: Invalid

I found your Decoder implementation is invalid.  Basically it shouldn't work with 0.9.4 under high load because your implementation doesn't take account into the case that a message is splitted into more than one packets.  Please try to replace it with TextCodecFactory which is introduced in 0.9.x.

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>     Assignee: Trustin Lee
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (DIRMINA-224) Data Corruption

Posted by "Trustin Lee (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]

Trustin Lee updated DIRMINA-224:
--------------------------------

    Fix Version: 0.8.3
                 0.9.5
        Version: 0.9.4
      Assign To: Trustin Lee

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>     Versions: 0.8.2, 0.9.4
>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>     Assignee: Trustin Lee
>      Fix For: 0.8.3, 0.9.5
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Updated: (DIRMINA-224) Data Corruption

Posted by "Trustin Lee (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/DIRMINA-224?page=all ]

Trustin Lee updated DIRMINA-224:
--------------------------------

    Fix Version:     (was: 0.8.3)
                     (was: 0.9.5)
        Version:     (was: 0.8.2)
                     (was: 0.9.4)

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>     Assignee: Trustin Lee
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Commented: (DIRMINA-224) Data Corruption

Posted by "Trustin Lee (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/DIRMINA-224?page=comments#action_12419451 ] 

Trustin Lee commented on DIRMINA-224:
-------------------------------------

Plus, please try to create one encoder/decoder instance per session.  You can create a singleton that can process multiple sessions at the same time, but it's quite hard to implement.  Please refer to the 'reverser' example included in 0.8.2.

> Data Corruption
> ---------------
>
>          Key: DIRMINA-224
>          URL: http://issues.apache.org/jira/browse/DIRMINA-224
>      Project: Directory MINA
>         Type: Bug

>  Environment: Linux version 2.4.29-3.2a (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #1 Fri May 27 10:39:22 PDT 2005
> java version "1.5.0_05"
> Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_05-b05)
> Java HotSpot(TM) Client VM (build 1.5.0_05-b05, mixed mode)
>     Reporter: Hanson Char
>     Assignee: Trustin Lee
>  Attachments: Mina-0.8.2-bug.jar, Mina-0.9.4-bug.jar, TEST-test.JUnitTest.jar
>
> Messages written to the session get corrupted when Mina 0.8.2 is run on Linux 7.2, but not when run on Windows XP.  Note there is no explicit use of thread pool.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira