Check document version on update

Qhen update a document, if the field "@version" is passed in the posted
body, a check is performed against it and a HTTP 400 (BAD REQUEST) is
returned in case of version mismatch
New custom HTTP code in case of wrong version

Added a new custom code: 40001 which is returned in the bb_code field in
case of version error
New exception for version mismatches
Check @version field

@version field must be an Integer