[CITE-Forum] CSW 2.0.2 Test Specification: nextRecord value when maxRecords="0"

Dirk Stenger cite at lat-lon.de
Fri Dec 15 04:11:31 EST 2017


Thank you! I added a comment to the issue and further discussion should
be done there.

Regards,

Dirk



Am 14.12.2017 um 20:44 schrieb Tom Kralidis:
>
> Thanks Roger/Dirk.
>
> Dirk: the failing test is indeed 23.1.  I've posted the full trace at [1]
> and opened a associated GitHub issue at [2]
>
> Thanks
>
> ..Tom
>
> [1] https://github.com/geopython/pycsw/pull/557#issuecomment-351815650
> [2] https://github.com/opengeospatial/ets-csw202/issues/22
>
> On Tue, 12 Dec 2017, Dirk Stenger via CITE-Forum wrote:
>
>> Date: Tue, 12 Dec 2017 15:49:05 +0100
>> From: Dirk Stenger via CITE-Forum <cite-forum at lists.opengeospatial.org>
>> Reply-To: Dirk Stenger <cite at lat-lon.de>
>> To: cite-forum at lists.opengeospatial.org
>> Subject: Re: [CITE-Forum] CSW 2.0.2 Test Specification: nextRecord
>> value when
>>     maxRecords="0"
>>
>> Hi Roger,
>>
>>
>> thank you for reporting this.
>>
>> Are you referring to test "csw-2.0.2-GetRecords-tc23.1"?
>>
>> I also do not see the reason why "csw:SearchResults/@nextRecord = 1" is
>> expected. However, if you confirm that this is the correct test, we
>> should create an issue on GitHub [1] to finalize the discussion there
>> (and also to create a fix).
>>
>>
>> Regards,
>>
>> Dirk
>>
>>
>> [1] https://github.com/opengeospatial/ets-csw202/issues
>>
>>
>>
>>
>> Am 11.12.2017 um 12:28 schrieb Duthie, Roger J.A. via CITE-Forum:
>>>
>>> Dear CITE Forum,
>>>
>>>
>>> This is my first post to this mailing group, so: hello!
>>>
>>>
>>> I have recently been working on a harvester and validation service for
>>> internal use at my organisation.  The harvestable endpoint of our
>>> metadata catalogue uses CSW and specifically the PyCSW package. 
>>> Firstly, I had noticed an inconsistency in the response from PyCSW
>>> when the numberOfRecordsReturned was less than the maxRecords, but the
>>> number of matched records was greater than maxRecords; this can can
>>> happen if startPosition != 0.  In these cases, the
>>> numberOfRecordsReturned erroneously took the value of maxRecords.  As
>>> a result I started helping fix this problem with the PyCSW team.
>>>
>>>
>>> This went well, as the fix was rather simple; however, my analysis
>>> exposed another issue which is preventing the patch I have written
>>> from being accepted.  The issue is that, with the fix to the software
>>> and associated functional tests, PyCSW does not pass all the CITE
>>> tests. 
>>>
>>>
>>> The issue arises when maxRecords="0", which should force the same
>>> behaviour as if resultType="hits" //[/v07-006r1 "OpenGIS Catalogue
>>> Services Specification specification v2.0.2" 10.8.4.7 p149/].  Looking
>>> at what that behaviour should be [/10.8.4.3 p147]:/
>>>
>>> /"[...] the catalogue service shall return a < GetRecordsResponse >
>>> element containing an empty < SearchResults > element that indicates
>>> the estimated size of the result set. Optional attributes may or may
>>> not be set accordingly."/
>>> //
>>>
>>>
>>> When I was making my fix for the other issue, the value of nextRecord
>>> was discussed on the PyCSW IRC channel (freenode #pycsw).  The answer
>>> to the question, what should the nextRecord attribute be when no
>>> records have been returned, but all records have been reported, was
>>> nextRecord=0.  This also is the value nextRecord would take if the
>>> last of the records had been returned. 
>>>
>>>
>>> However, it is true that the specification does not dictate what this
>>> value should be.  The question to the CITE forum is: is nextRecord=1
>>> expected for some reason that I haven't found yet, or is this test
>>> being over unnecessarily strict on this?
>>>
>>>
>>> Thanks for reading, I look forward to seeing a response.  Let me know
>>> if any further information is required.
>>>
>>>
>>> All the best,
>>>
>>> Roger Duthie
>>>
>>> Data Manager / Software Developer
>>>
>>> British Antarctic Survey
>>>
>>> Cambridge, UK
>>>
>>>
>>> P.S.
>>>
>>> The particular test is:
>>>
>>> |The response to a GetRecords request that specifies
>>> maxRecords="0" must not include any results.|
>>> The request and response from the test:
>>>
>>>
>>> Request
>>>
>>> <csw:GetRecords xmlns="http://www.occamlab.com/ctl"
>>>                 xmlns:csw="http://www.opengis.net/cat/csw/2.0.2"
>>>                 xmlns:ctl="http://www.occamlab.com/ctl"
>>>                 xmlns:dc="http://purl.org/dc/elements/1.1/"
>>>                 xmlns:dct="http://purl.org/dc/terms/"
>>>                 xmlns:gen="java:com.occamlab.te.Generator"
>>>                 xmlns:gml="http://www.opengis.net/gml"
>>>                 xmlns:ogc="http://www.opengis.net/ogc"
>>>                 xmlns:ows="http://www.opengis.net/ows"
>>>                 xmlns:p="http://teamengine.sourceforge.net/parsers"
>>>                 xmlns:parsers="http://www.occamlab.com/te/parsers"
>>>                 xmlns:saxon="http://saxon.sf.net/"
>>>                 xmlns:te="http://www.occamlab.com/te"
>>>                 xmlns:tec="java:com.occamlab.te.TECore"
>>>                 xmlns:tems="java:com.occamlab.te.web.MonitorServlet"
>>>                 xmlns:xi="http://www.w3.org/2001/XInclude"
>>>                 xmlns:xlink="http://www.w3.org/1999/xlink"
>>>                 xmlns:xs="http://www.w3.org/2001/XMLSchema"
>>>                 xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>>>                 maxRecords="0"
>>>                 resultType="results"
>>>                 service="CSW"
>>>                 version="2.0.2">
>>>    <csw:Query typeNames="csw:Record">
>>>       <csw:ElementName>dc:identifier</csw:ElementName>
>>>       <csw:ElementName>ows:BoundingBox</csw:ElementName>
>>>       <csw:Constraint version="1.1.0">
>>>          <ogc:Filter>
>>>             <ogc:Not>
>>>                <ogc:BBOX>
>>>                   <ogc:PropertyName>ows:BoundingBox</ogc:PropertyName>
>>>                   <gml:Envelope
>>> srsName="urn:x-ogc:def:crs:EPSG:6.11:4326">
>>>                      <gml:lowerCorner>60.0 12.0</gml:lowerCorner>
>>>                      <gml:upperCorner>70.0 20.0</gml:upperCorner>
>>>                   </gml:Envelope>
>>>                </ogc:BBOX>
>>>             </ogc:Not>
>>>          </ogc:Filter>
>>>       </csw:Constraint>
>>>    </csw:Query>
>>> </csw:GetRecords>
>>>
>>> Response
>>>
>>>       <csw:GetRecordsResponse
>>> xmlns:csw="http://www.opengis.net/cat/csw/2.0.2"
>>>                         xmlns:dc="http://purl.org/dc/elements/1.1/"
>>>                         xmlns:dct="http://purl.org/dc/terms/"
>>>                         xmlns:gmd="http://www.isotc211.org/2005/gmd"
>>>                         xmlns:gml="http://www.opengis.net/gml"
>>>                         xmlns:ows="http://www.opengis.net/ows"
>>>                         xmlns:xs="http://www.w3.org/2001/XMLSchema"
>>>                        
>>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>>>                         version="2.0.2"
>>>                        
>>> xsi:schemaLocation="http://www.opengis.net/cat/csw/2.0.2
>>> http://schemas.opengis.net/csw/2.0.2/CSW-discovery.xsd">
>>>   <csw:SearchStatus timestamp="2017-12-07T11:30:59Z"/>
>>>   <csw:SearchResults nextRecord="0" numberOfRecordsMatched="11"
>>> numberOfRecordsReturned="0"
>>>                      
>>> recordSchema="http://www.opengis.net/cat/csw/2.0.2"/>
>>>    <!--Response received in [501]
>>> milliseconds--></csw:GetRecordsResponse>
>>> Error message from CITE:
>>> |[FAILURE] Expected csw:SearchResults/@nextRecord = 1.|
>>>
>>>
>>>
>>> ------------------------------------------------------------------------
>>>
>>> This message (and any attachments) is for the recipient only. NERC is
>>> subject to the Freedom of Information Act 2000 and the contents of
>>> this email and any reply you make may be disclosed by NERC unless it
>>> is exempt from release under the Act. Any material supplied to NERC
>>> may be stored in an electronic records management system.
>>> ------------------------------------------------------------------------
>>>
>>>
>>>
>>> _______________________________________________
>>> CITE-Forum mailing list
>>> CITE-Forum at lists.opengeospatial.org
>>> https://lists.opengeospatial.org/mailman/listinfo/cite-forum
>>
>> -- 
>> ### -->  Bitte beachten Sie unsere neuen Rufnummern  <--  ###
>>
>> -- 
>> l a t / l o n  GmbH
>> Aennchenstrasse 19                    53177 Bonn, Germany
>> phone ++49 +228 9477 9877             fax ++49 +228 9477 0154
>> http://www.lat-lon.de                 http://www.deegree.org
>>
>> lat/lon gesellschaft für raumbezogene informationssysteme mbH
>> Registergericht: Amtsgericht Bonn, HRB 13042
>> Geschäftsführer: Jens Fitzke und Torsten Friebe
>>
>>

-- 
### -->  Bitte beachten Sie unsere neuen Rufnummern  <--  ###

--
l a t / l o n  GmbH
Aennchenstrasse 19                    53177 Bonn, Germany
phone ++49 +228 9477 9877             fax ++49 +228 9477 0154
http://www.lat-lon.de                 http://www.deegree.org

lat/lon gesellschaft für raumbezogene informationssysteme mbH
Registergericht: Amtsgericht Bonn, HRB 13042
Geschäftsführer: Jens Fitzke und Torsten Friebe



More information about the CITE-Forum mailing list