[GMU-3] Fix class cast exception during fields mapping Created: 16/Dec/20  Updated: 10/Mar/21  Resolved: 18/Dec/20

Status: Closed
Project: generate-marc-utils
Components: None
Affects versions: None
Fix versions: 1.1.0

Type: Bug Priority: P2
Reporter: Andrii Novytskyi Assignee: Igor Gorchakov
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original estimate: Not Specified

Attachments: Text File ClassCastLog.txt     PNG File screenshot-1.png    
Issue links:
Defines
defines MDEXP-12 Create Inventory Holdings to MFHD rec... Closed
Sprint: Concorde - Sprint 104
Story Points: 1
Development Team: Concorde

 Description   

Purpose:

For holdings and items, during the mapping process, the class cast exception occurs during creating RecordInfo, for simple fields when their jsonPath contains array (for example "$.holdings[*].hrid")
The error log:
ClassCastLog.txt

Acceptance criteria:

  • ClassCastException fixed, and recordInfo is always present.
  • Unit tests are updated


 Comments   
Comment by Magda Zacharska [ 17/Dec/20 ]

Igor Gorchakov and Andrii Novytskyi - is there a way to validate the fix?

Comment by Andrii Novytskyi [ 18/Dec/20 ]

Magda Zacharska create a mapping profile with holdings or items, with selected hrId field, and start export, and check that hrId is present is the marc file

Comment by Andrii Novytskyi [ 18/Dec/20 ]

verified on local with the latest changes from gmu. Exported with default MFH rules, as a result, no exceptions, and fields are present in marc file:

Generated at Thu Feb 08 22:15:45 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.