[Koha-bugs] [Bug 10974] OAI-PMH Resumption Tokens Do Not Handle Time

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Oct 22 00:44:23 CEST 2013


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10974

--- Comment #4 from David Cook <dcook at prosentient.com.au> ---
(In reply to Petter Goksøyr Åsen from comment #3)
> Strange, the resumptionToken request works for me, without applying the
> patch.
> 
> It also works after I apply the patch of course.

Thanks for that Petter. I should've written my test plan better.

In fact, it only looks like it's working.

If you insert some debugging code, you will find that the following token:

oai_dc:50:2012-09-05T13:44:33Z:2013-09-05T13:44:33Z:

is being broken into the following:

metadataPrefix = oai_dc
offset = 50
from = 2012-09-05T13
until = 44
set = 33Z

and the rest of the token will be thrown away.

--

If you re-run the test, take a look at the first result you receive in the
ListRecords response. Change your "until" date to before the datestamp of that
first result.

You will find that record still appears when it shouldn't!

--

Also, the resumption token at the bottom will be similar to the following:

oai_dc:66:2012-09-05T13:44:33Z

This looks like a resumption token with a fully formed From date. 

However, it's a token built up from those split fields I identified before. It
thinks 44 is the until datestamp and 33Z is the set. 

If you try to use that resumptionToken, you will get no results.

--

Please try it again in light of these notes. I'm sure that you'll find I'm
correct :)

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list