Homec4science

records: bibupload timestamp fix

Authored by Lars Holm Nielsen <lars.holm.nielsen@cern.ch> on Apr 3 2014, 13:49.

Description

records: bibupload timestamp fix

  • Fixes an issue causing revision verifier to reject uploads. When bibupload inserts/updates records it sets hstRECORD.job_date=t1 and bibfmt.last_updated=t1 and bibrec.modification_date=t2 (with t2 > t1). This is intended behavior in master (see #1431).

    Revision verifier checks 005 on upload against hstRECORD.job_date (i.e. t1). Records model was getting modification_date/005 from bibrec.modification_date (i.e. t2).

    Thus getting a record and trying to reupload it would get rejected, since the XML would have t2 in 005, which revision verifier would compares against t1 from hstRECORD.

    Modification date ought to be taken from bibrec.modification_date and all three timestamps ought to be the same. Thus below is a hack, that ought to be fixed in bibupload instead. Unfortunately so much other code is might rely on the current behavior that it's hard to change.

Co-authored-by: Esteban J. G. Gabancho <egabancho@gmail.com>
Signed-off-by: Lars Holm Nielsen <lars.holm.nielsen@cern.ch>

Details

Committed
kuncarJun 4 2014, 16:05
Parents
R3600:52b045afce57: formatter: error pass-through
Branches
Unknown
Tags
Unknown

Event Timeline

Jiri Kuncar <jiri.kuncar@cern.ch> committed R3600:d2c9f9a0debb: records: bibupload timestamp fix (authored by Lars Holm Nielsen <lars.holm.nielsen@cern.ch>).Jun 4 2014, 16:05