Job creation via Active MQ doesn't populate all occurences of the same field

Bug #1102401 reported by Matthias Ronge
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Goobi.Production
Status tracked in 1.10
1.10
Fix Released
Undecided
Unassigned
1.8.git
Fix Released
High
Matthias Ronge

Bug Description

The Active MQ interface was written in belief that each labelled field would only be present once. This isn't true in all cases, and creating new processes may fail if there are multiple instances of the same field.

Revision history for this message
Matthias Ronge (matthias-ronge) wrote :
Revision history for this message
Matthias Ronge (matthias-ronge) wrote :
Changed in goobi-production:
status: New → Fix Committed
assignee: nobody → Matthias Ronge (matthias-ronge)
Changed in goobi-production:
status: Fix Committed → In Progress
importance: Undecided → High
Revision history for this message
Ralf Claussnitzer (ralf-claussnitzer-deactivatedaccount) wrote :

This looks like a workaround for a design issue. What is the use of having the same {key, value} pair multiple times? This should be implemented as a map. Can we do this? Or is this all hidden somewhere in UGH?

Where do "multiple instances of the same field" come from?
Where is this a feature?
When is this situation an actual problem?

Revision history for this message
Matthias Ronge (matthias-ronge) wrote :

This is about ProzesskopieForm’s private List<AdditionalField> additionalFields

Examining the list entries shows that, for the AdditionalField with titel="Titel" there are two entries, one of them with isnotdoctype="multivolume" and the other one with isdoctype="multivolume". They are generated from examining projects.xml, which reads:

<!-- Title for Monograph and Periodical -->
<item docstruct="topstruct" from="vorlage" isnotdoctype="multivolume"
 metadata="TitleDocMain" required="true" ughbinding="true"> Titel </item>
[...]
<!-- Title just for the Multivolume -->
<item docstruct="topstruct" from="vorlage" isdoctype="multivolume"
 metadata="TitleDocMain" required="true" ughbinding="true"> Titel </item>

It seems Goobi generates all possible cases and, on switching the docType, only changes which ones to show. Changing this to a Map would also mean that this initialization process would be needed to be rewritten to re-initalize the map whenever one changes the docType.

Revision history for this message
Ralf Claussnitzer (ralf-claussnitzer-deactivatedaccount) wrote :

Thanks for clarification. By reading the parameter names (String key, String value) one might think of map, but appearently, "key" is looks like a n-tuple.

Revision history for this message
Matthias Ronge (matthias-ronge) wrote :
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.