Fix log entry serialization.
Add log entry marshaling.
Fix command serialization issues.