Hello,
It may not be easy to invoke it directly, but the code is all in
this method: https://github.com/locationtech/geomesa/blob/geomesa_2.11-2.3.0/geomesa-spark/geomesa-spark-sql/src/main/scala/org/locationtech/geomesa/spark/GeoMesaSparkSQL.scala#L164
If you think it would be helpful, feel free to open a PR to make it
more accessible!
Thanks,
Emilio
On 5/28/19 5:31 AM, GRISOT, REMI wrote:
Hi,
I would like to convert a Spark Dataframe to a Feature
Collection so I can use Geomesa processes. In the Geomesa Spark
SQL doc I found that when you write a dataframe to geomesa using
dataFrame.write.format("geomesa").options(dsParams).option("geomesa.feature",
"featureName").save(),
This will automatically convert the data frame’s underlying
RDD[Row] into an RDD[SimpleFeature] and write to the data
store in parallel.
So I guess that a converter from Row to SimpleFeature exists
somewhere in the Geomesa code and maybe I could re-use it. Could
you please tell me a direction to look at (class or package) to
find this converter?
Thank you!
Rémi
Ce message et toutes les pièces jointes (ci-après le "message")
sont établis à l’intention exclusive des destinataires désignés.
Il contient des informations confidentielles et pouvant être
protégé par le secret professionnel. Si vous recevez ce message
par erreur, merci d'en avertir immédiatement l'expéditeur et de
détruire le message. Toute utilisation de ce message non conforme
à sa destination, toute diffusion ou toute publication, totale ou
partielle, est interdite, sauf autorisation expresse de
l’émetteur. L'internet ne garantissant pas l'intégrité de ce
message lors de son acheminement, Atos (et ses filiales)
décline(nt) toute responsabilité au titre de son contenu. Bien que
ce message ait fait l’objet d’un traitement anti-virus lors de son
envoi, l’émetteur ne peut garantir l’absence totale de logiciels
malveillants dans son contenu et ne pourrait être tenu pour
responsable des dommages engendrés par la transmission de l’un
d’eux.
This message and any attachments (the "message") are intended
solely for the addressee(s). It contains confidential information,
that may be privileged. If you receive this message in error,
please notify the sender immediately and delete the message. Any
use of the message in violation of its purpose, any dissemination
or disclosure, either wholly or partially is strictly prohibited,
unless it has been explicitly authorized by the sender. As its
integrity cannot be secured on the internet, Atos and its
subsidiaries decline any liability for the content of this
message. Although the sender endeavors to maintain a computer
virus-free network, the sender does not warrant that this
transmission is virus-free and will not be liable for any damages
resulting from any virus transmitted.
_______________________________________________
geomesa-users mailing list
geomesa-users@xxxxxxxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.locationtech.org/mailman/listinfo/geomesa-users
|