hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brock Noland (JIRA)" <>
Subject [jira] [Commented] (HIVE-7868) AvroSerDe error handling could be improved
Date Sun, 24 Aug 2014 00:37:11 GMT


Brock Noland commented on HIVE-7868:

As opposed to returning an "error string as schema" we could instead catch the exception thrown
by {{AvroSerdeUtils.determineSchemaOrThrowException}}, log and store it inside AvroSerde.
Then if any other method such as serialized/deserailize is subsequently called we can throw
the exception.

> AvroSerDe error handling could be improved
> ------------------------------------------
>                 Key: HIVE-7868
>                 URL:
>             Project: Hive
>          Issue Type: Improvement
>            Reporter: Brock Noland
> When an Avro schema is invalid, AvroSerDe returns an error message instead of throwing
an exception. This is described in {{AvroSerdeUtils.determineSchemaOrReturnErrorSchema}}:
> {noformat}
>   /**
>    * Attempt to determine the schema via the usual means, but do not throw
>    * an exception if we fail.  Instead, signal failure via a special
>    * schema.  This is used because Hive calls init on the serde during
>    * any call, including calls to update the serde properties, meaning
>    * if the serde is in a bad state, there is no way to update that state.
>    */
> {noformat}
> I believe we should find a way to provide a better experience to our users.

This message was sent by Atlassian JIRA

View raw message