One Star

publish metadata to geonetwork

Hi,
I'm trying to publish some metadata to geonetwork. I looked at the corresponding tutorial, and adapted the example to my situation. Since i didn't manage to get metadata from sPostgisOutput (see previous post), i decided to output my Postgis data to a new shapefile, and use this shapefile's metadata output. So far so nice.
But when i trigger a "OnComponentOK" from this shapefile to a sCataloguePublisher, set up as in the example, I get the following message
"org.talend.sdi.metadata.GeoNetwork | Connected to GeoNetwork.
org.talend.sdi.metadata.Catalogue | Invalid XML Document 'Error on line 33 of document : The element type "META" must be terminated by the matching end-tag "". Nested exception: The element type "META" must be terminated by the matching end-tag "".'
null
sCataloguePublisher_1 | Metadata published."
and/but nothing is published on the catalogue.
It's pretty disappointing.
Any idea to help me ?
Thanks,
Jean

6 REPLIES
One Star Fxp
One Star

Re: publish metadata to geonetwork

Hi,
It looks like you get an error from the GeoNetwork catalogue when inserting the metadata.
Could you post your xml metadata document for test ?
You could also try a metadata XML insert from the admin interface to check the import.
HTH.
Francois
One Star

Re: publish metadata to geonetwork

Hi,
Thanks for the answer. You're right, i did not think of publishing the XML file and then insert it via the geonetwork interface.
The fact is i can't find how to write de metadata output as an XML file, in SDI's interface. It looks like i'm not allowed to output metadata to classic XML file output.
Any idea ?
Four Stars

Re: publish metadata to geonetwork

Hi,
You can use tFileOutputXML in XML Menu.
Regards
One Star Fxp
One Star

Re: publish metadata to geonetwork

Hello,
Hi,
Thanks for the answer. You're right, i did not think of publishing the XML file and then insert it via the geonetwork interface.
The fact is i can't find how to write de metadata output as an XML file, in SDI's interface. It looks like i'm not allowed to output metadata to classic XML file output.
Any idea ?

The XML document should be in the same directory as your shapefile, with shapefile_name.shp.xml as filename.
HTH. Francois
One Star

Re: publish metadata to geonetwork

Right, thanks. It didn't think of looking in the filesystem.
OK. So, the errors are on validation of the document. first error is about the "Equivalent scale Denominator" (name in geonetwork's interface) not filled.
I get an error "Exception in endElement: cvc-datatype-valid.1.2.1: '' is not a valid value for 'integer'."
Looks like the problem is that some compulsary informations are missing, so it fails to pass the validation.
Here is the XML file generated by SDI (that is, in fact, almost empty except from the geographical bouding box)



36c3f008-3225-46d2-8ad7-ab3cd618d659


eng













































___SDI_AUTO___TODO











2008-06-30T16:35:01


ISO 19115:2003/19139


1.0









56










TODO









<BR /> <CHARACTERSTRING>Toponymes for TV (jean)</CHARACTERSTRING> <BR />



2008-06-30T16:35:01















Metadata abstract jean


Metadata Purpose














___SDI_AUTO___


thumbnail


png






XXX









XXX




























eng





boundaries




















3.13169279


10.94161413


22.53219891


26.26297897

















D:/SDI-All-V1.2.0-TOSV2.3.2/workspace/out.shp


WWWSmiley Very HappyOWNLOAD-1.0-http--download





File for download



















Generated by Talend SDI.






One Star Fxp
One Star

Re: publish metadata to geonetwork

Hi, for now Talend is taking care of filling the following info using your input in the component properties:
* title
* abstract
* purpose
* topic category
... and automatically set:
* bbox
* number of features
* feature types
* creation date
Then all other informations are set in the XML templates used (look at workspace/.spatial/md/template/iso19139.xml). Feel free to edit the template (or create a new one) to set info like contact, maxscale denominator, and other ... which could not be set automatically.
Maybe some other elements could be set by Talend during the process (e.g CRS, lineage ...) but this has not be done so far ... And not planned from my side for now.
If you have comments, inputs, advices on how to improve that metadata creation process do not hesitate to discuss that point here.
HTH.
Francois