Fix the msg encode/decode error

When using Mysql-python driver, the message id is converted to
long type, which will lead to a L letter in the last. So convert
it to int type before encoding.

Change-Id: I8792548d2882bd1e2c6c7b3273504746b7150d6f
Merge "Fix the msg encode/decode error"