[server][RestResourceAction] Extract common code for RestAction PUT/POST

related to #873