[OAI-implementers] handling unavailable data
Thu, 29 Mar 2001 12:41:38 -0800
i would think returning empty lists is not a good idea because the
service provider could make long-term assumptions based on that - in the
case of ListMetadataFormats that there are none.
my suggestion would be to use HTTP error codes to indicate that the
server cannot respond because of some internal problem ... for example,
you could use "503 Service unavailable" and possibly return a
"retry-after" time, which supports automatic harvesters quite nicely
(even the repository explorer will honor those) ... for completeness, if
you want a really solid interface, you might consider using some flavor
of upper-bounded exponential backoff so that the retry-after times
follow a 1,2,4,8,...,r sequence for subsequent requests while the
database is unavailable.
hope this helps ...
Ben Henley wrote:
> I am currently implementing a simple OAI repository.
> I've looked through the specs but I can't find the answer to this
> What is the recommended behaviour if data is temporarily
> For example, suppose I have the information about supported metadata
> formats stored in an SQL accessible database table. An OAI agent makes a
> request to my repository but the database is unavailable for some reason.
> In the reference implementation I've looked at (the ASP one), a
> partial answer could be returned. ie. <ListMetadataFormats>, <responseDate>
> and <requestURL> elements would be sent but not <metadataFormat>. As I
> understand http://www.openarchives.org/OAI/1.0/OAI_ListMetadataFormats.xsd,
> the metadataFormat element is not compulsory (minOccurs=0).
> So a failure to retrieve any records could cause the repository to
> lie by omission and say that it has no metadataFormats.
> Obviously the same could apply for other requests.
> Is this a real problem? If data is not available, should a request
> be ignored or is there a special message to return? Or is it assumed that
> clients will revisit archives so rare failures like this will be forgotten?
> Ben Henley <mailto:firstname.lastname@example.org>
> Special Projects Editor
> BioMed Central
> OAI-implementers mailing list
hussein suleman -- email@example.com -- vtcs -- http://purl.org/net/hussein