[FOLIO-1156] Add a method to add/update/delete lists of records in one transaction Created: 20/Feb/18 Updated: 18/Jan/22 |
|
| Status: | Open |
| Project: | FOLIO |
| Components: | None |
| Affects versions: | None |
| Fix versions: | None |
| Type: | Task | Priority: | P3 |
| Reporter: | Jon Miller | Assignee: | Jakub Skoczen |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original estimate: | Not Specified | ||
| Issue links: |
|
||||||||||||||||
| Sprint: | |||||||||||||||||
| Development Team: | Core: Platform | ||||||||||||||||
| Description |
|
Would be possible to add methods or modify the existing (REST) methods to allow lists of users rather than single records to be added, updated or deleted? What I'm wondering is if you can make it so that when you do a POST/PUT/DELETE, the server checks to see if it's a single record or a list of records. If it's a single record, it would work the same as it does now. I.e. add/update/delete the user then do a SQL COMMIT. In the case of the list of users, it would iterate over the list of users adding/updating/deleting each one and then do the SQL COMMIT at the end. There needs to be a way to add/update/delete more than one user at a time. If the commit size is 1 row, performance is extremely poor. However this is solved, I think it should be done across the board for all FOLIO CRUD APIs. |
| Comments |
| Comment by Ann-Marie Breaux (Inactive) [ 13/Jul/20 ] |
|
Hi @jakub Following up from a data migration subgroup meeting. This is assigned to Core Platform, but no activity on it. Any updates? Should it maybe be put into one of the features of the migration Epic? |
| Comment by Julian Ladisch [ 18/Sep/20 ] |
|
For adding and updating a list of records RMB already provides the PgUtil.postSync method that all modules can use: https://github.com/folio-org/raml-module-builder/blob/v31.1.0/domain-models-runtime/src/main/java/org/folio/rest/persist/PgUtil.java For deleting a list of records RMB needs to provide a similar method PgUtil.delete, but this is still missing, we have
Please create a feature request for each back-end module where deleting a list of records is needed in the module's Jira project and list the API endpoints in decreasing priority so that the developers can start with the most relevant APIs. Mark that the feature request is blocked by
We need the feature request in each individual module project for capacity planning and assigning them to different development teams: https://folio-org.atlassian.net/wiki/display/REL/Team+vs+module+responsibility+matrix |
| Comment by Ann-Marie Breaux (Inactive) [ 18/Sep/20 ] |
|
Thanks for the guidance, Julian Ladisch. Since this is migration-related, sounds like some possible Jira work for Ian Walls |