[infinispan-issues] [JBoss JIRA] Created: (ISPN-773) Malformed memcached cas command should result in CLIENT_ERROR

Galder Zamarreño (JIRA) jira-events at lists.jboss.org
Tue Nov 16 05:11:46 EST 2010


Malformed memcached cas command should result in CLIENT_ERROR
-------------------------------------------------------------

                 Key: ISPN-773
                 URL: https://jira.jboss.org/browse/ISPN-773
             Project: Infinispan
          Issue Type: Bug
          Components: Cache Server
    Affects Versions: 4.2.0.BETA1, 4.1.0.Final
            Reporter: Galder Zamarreño
            Assignee: Galder Zamarreño
             Fix For: 4.2.0.CR1, 4.2.0.Final


>From Michal:

[mlinhard at michal-linhard ~]$ echo -e "cas bad blah 0 0 0\r\n\r\n" | nc localhost 11211 
SERVER_ERROR org.infinispan.server.core.ServerException: java.lang.NumberFormatException: For input string: "blah" 
[mlinhard at michal-linhard ~]$ echo -e "cas bad 0 blah 0 0\r\n\r\n" | nc localhost 11211 
SERVER_ERROR org.infinispan.server.core.ServerException: java.lang.NumberFormatException: For input string: "blah" 
[mlinhard at michal-linhard ~]$ echo -e "cas bad 0 0 blah 0\r\n\r\n" | nc localhost 11211 
SERVER_ERROR org.infinispan.server.core.ServerException: java.lang.NumberFormatException: For input string: "blah" 
[mlinhard at michal-linhard ~]$ echo -e "cas bad 0 0 0 blah\r\n\r\n" | nc localhost 11211 
SERVER_ERROR org.infinispan.server.core.ServerException: java.lang.NumberFormatException: For input string: "blah" 

in each case memcached server module should have replied with "CLIENT_ERROR <error>\r\n" 
as required in: https://github.com/memcached/memcached/blob/master/doc/protocol.txt 

FYI: original memcached server implementation replies "CLIENT_ERROR bad command line format\r\n" (which is also expected by their test suite, but not required by protocol) 

Also, verify what Memcached server does with "cas foo 0 0 6 \r\nbarva2\r\n" as opposed to Infinispan Memcached.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

       



More information about the infinispan-issues mailing list