[pycsw-devel] Federated Search question
Tom Kralidis
tomkralidis at gmail.com
Wed Mar 30 12:54:50 PDT 2016
On Wed, 30 Mar 2016, Alejandro Mostovoi wrote:
> Date: Wed, 30 Mar 2016 19:24:58 +0000
> From: Alejandro Mostovoi <ahmostovoi at gmail.com>
> To: "pycsw-devel at lists.osgeo.org" <pycsw-devel at lists.osgeo.org>
> Subject: [pycsw-devel] Federated Search question
>
> Hi All,
> I'm trying to make a distributed search against other CSW server. Both
> servers use ISO 19139 metadata standard.
> I'm performing a GetRecords operation using this xml:
>
> <csw:GetRecords xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" xmlns:ogc="
> http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml"
> service="CSW" version="2.0.2" resultType="results"
> *outputSchema="http://www.isotc211.org/2005/gmd
> <http://www.isotc211.org/2005/gmd>"*> <csw:DistributedSearch hopCount="2"/>
> <csw:Query typeNames="gmd:MD_Metadata">
> <csw:ElementSetName>full</csw:ElementSetName>
> </csw:Query>
> </csw:GetRecords>
>
> The response should have 2 records, but it has only 1 record and a comment
> which says: <!-- 1 result from <csw server url> --> and nothing else.
>
> I made another test, changing the outputSchema to
>
> *outputSchema="http://www.opengis.net/cat/csw/2.0.2*
> and the response has the 2 records, but with a different schema.
>
> I need to get the 2 records with the *gmd* schema. What I'm doing wrong?
>
> The pycsw version is 1.10.3, on Ubuntu Server 14.04 64-bit.
>
> Thanks in advance.
> Alejandro
>
My first guess is that the CSW that you are federated against is refusing to transform
all metadata records to ISO. Or that pycsw is not telling it to do so for some reason.
What happens when you apply the following queries directly against the federated CSW:
query 1:
<csw:GetRecords xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" service="CSW" version="2.0.2" resultType="results" xmlns:gmd="http://www.isotc211.org/gmd" outputSchema="http://www.isotc211.org/2005/gmd">
<csw:Query typeNames="gmd:MD_Metadata">
<csw:ElementSetName>full</csw:ElementSetName>
</csw:Query>
</csw:GetRecords>
query 2:
<csw:GetRecords xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" service="CSW" version="2.0.2" resultType="results">
<csw:Query typeNames="csw:Record">
<csw:ElementSetName>full</csw:ElementSetName>
</csw:Query>
</csw:GetRecords>
If the federated CSW is returning 2 records in both cases, then there is a moving part in pycsw's
distributed search. In this case, if you turn on logging (level=DEBUG), run only the two requests
and send the logging output (offline) that would be great. If there's any chance of sending the federated
CSW in question (offline) I can try to reproduce and debug deeper locally.
..Tom
More information about the pycsw-devel
mailing list