Implement and improve receive message process

Signed-off-by: plysan <plysab@gmail.com>