You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@spark.apache.org by Richard Marscher <rm...@localytics.com> on 2016/06/23 18:16:37 UTC

Option Encoder

Is there a proper way to make or get an Encoder for Option in Spark 2.0?
There isn't one by default and while ExpressionEncoder from catalyst will
work, it is private and unsupported.

-- 
*Richard Marscher*
Senior Software Engineer
Localytics
Localytics.com <http://localytics.com/> | Our Blog
<http://localytics.com/blog> | Twitter <http://twitter.com/localytics> |
Facebook <http://facebook.com/localytics> | LinkedIn
<http://www.linkedin.com/company/1148792?trk=tyah>

Re: Option Encoder

Posted by Koert Kuipers <ko...@tresata.com>.
an implicit encoder for Option[X] given an implicit encoder for X would be
nice, i run into this often too.

i do not think it exists. your best is to hope ExpressionEncoder will do...


On Thu, Jun 23, 2016 at 2:16 PM, Richard Marscher <rm...@localytics.com>
wrote:

> Is there a proper way to make or get an Encoder for Option in Spark 2.0?
> There isn't one by default and while ExpressionEncoder from catalyst will
> work, it is private and unsupported.
>
> --
> *Richard Marscher*
> Senior Software Engineer
> Localytics
> Localytics.com <http://localytics.com/> | Our Blog
> <http://localytics.com/blog> | Twitter <http://twitter.com/localytics> |
> Facebook <http://facebook.com/localytics> | LinkedIn
> <http://www.linkedin.com/company/1148792?trk=tyah>
>