Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The purpose of the spike is to investigate and provide a technical solution for an export subset of the record fields in the delimited format, especially inventory item records that don't have MARC record equivalent.

Solution

The technical solution contains several parts that require different changes. The main idea is generating .csv or another file in delimited format contain contains field values of inventory records. In this case, there no needs to make request requests to SRS and records should be revived directly form mod-inventory-storage. At the same time, each export can have a different combination of fields, therefore, it necessary to provide the possibility for a user to choose a set of fields before running data export. New functionality should be integrated into the existing export flow and should not affect implemented mapping functionality.

Example of the output .csv file with records content:


 

View file
nameexample-delimited-records.csv
height250

1) Creating a new kind of export profile to allow the user to choose a set of fields.  To allow the user to choose a set of record fields it's required to new user experience on the UI side. From the side of data and entities there are two options:

a) Create a new entity to collect all fields. Such should pretty similar to mapping profile entity:

Drawio
bordertrue
diagramNamedelimited_records_mapping_profile
simpleViewerfalse
width
linksauto
tbstyletop
lboxtrue
diagramWidth831
revision3

...

List<Map<String, String>> map(List<JsonObject> records, MappingProfile mappingProfile, String jobExecutionId, OkapiConnectionParams connectionParams);

Where one Map object in the List represents one row of the file. As an alternate option, a new separate service can be created for this functionality.

...