DESCRIPTION

OperationStatus now has an error code

Having error codes will make it easier for users who get errors
to test for what error it is. Right now we only have the message
string and this can actually be different for the same error type.

Change-Id: I067e3145d5d95b09d7ca0ad0445bcfa5d5784d51


COMMENTS

author: Andreas Short
date: 2012-05-26 18:30:07.240000000

Patch Set 1: Do not submit

(3 inline comments)

Again, really happy we're doing this.

There are a few things that need fixing though.

Line:50, src/main/java/net/spy/memcached/protocol/ascii/VersionOperationImpl.java -> Looks like this was incorrect before.  Calling length on a constant string after an assert to verify it starts with that string seems like we're not doing the right thing.  There really shouldn't be an assert here.

Why not just take the whole line?

This is one place that we should just have a unit test for.

Line:181, src/main/java/net/spy/memcached/protocol/binary/OperationImpl.java -> can't we get rid of the cast here?  Is there any good reason to have the method called with an int?

if it really is an int, why not switch on the int?

Line:174, src/main/java/net/spy/memcached/protocol/BaseOperationImpl.java -> wow, never really noticed this before, but sticking the exception message in here is maybe not the best?  Let me think about that.  It would be better to have the throwable somewhere in here.  switching on ErrorCode.EXCEPTION I may want to throw my own exception with this one enclosed.

-------------------------------------
author: Kenny Maynard
date: 2012-06-01 22:57:43.466000000

Patch Set 1: (1 inline comment)



Line:50, src/main/java/net/spy/memcached/protocol/ascii/VersionOperationImpl.java -> I think another bug should be filed for this.

-------------------------------------
author: Tate Garrett
date: 2012-06-04 02:56:46.383000000

Your change could not be merged due to a path conflict.

Please merge (or rebase) the change locally and upload the resolution for review.

-------------------------------------
author: Tate Garrett
date: 2012-06-04 02:57:24.724000000

Your change could not be merged due to a path conflict.

Please merge (or rebase) the change locally and upload the resolution for review.

-------------------------------------
