Fixed NPE in recovery api by serializing the recovery type in StartRecoveryRequest.

Closes #6190