Details
-
Bug
-
Status: Closed (View Workflow)
-
P2
-
Resolution: Duplicate
-
None
-
None
-
None
-
2
-
Vega
-
Chalmers
Description
Overview:
Chalmers recently reported an issue - when they are trying to open loans for a given user, the UI displays a white screen reporting an error that contributors cannot be fetched for a null object or similar. On digging further, we identified that the item referenced in the loan is missing. Sample request which has been fixed since by correcting data - https://chalmers.folio.ebsco.com/users/db27aa12-83a2-47ab-8f1f-97c64c58acd2/loans/open
Steps to Reproduce:
- Log into any FOLIO environment as User X
- Not sure if this is possible from UI but create a loan and then delete the item associated using API
- Try opening the loans associated with the user and we can see the white screen
Expected Results:
A graceful error message indicating the cause of the problem. Like 'item associated with loan is missing'
Actual Results:
White screen with no indication of real error either in console js or n/w traffic
Additional Information
Again for Chalmers, we noticed that the timer job that expires patron sessions isn't working and failing with a NPE like below (the notice portion of this issue will be handled as part of CIRC-926 & CIRC-925):
12:17:50 INFO TenantManager timer call failed to module mod-circulation-18.0.9 for tenant fs00001000 : POST request for mod-circulation-18.0.9 /circulation/notice-session-expiration-by-timeout failed with 500: java.lang.NullPointerException java.lang.NullPointerException at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193) at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1380) at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481) at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471) at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708) at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499) at org.folio.circulation.domain.LocationRepository.getCampuses(LocationRepository.java:151) at org.folio.circulation.domain.notice.session.PatronActionSessionRepository.fetchCampusesForLoanItems(PatronActionSessionRepository.java:175) at org.folio.circulation.support.Result.after(Result.java:313) at org.folio.circulation.domain.notice.session.PatronActionSessionRepository.lambda$fetchLoans$11(PatronActionSessionRepository.java:163) at java.util.concurrent.CompletableFuture.uniCompose(CompletableFuture.java:952) at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:926) at java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:474) at java.util.concurrent.CompletableFuture.postFire(CompletableFuture.java:561) at java.util.concurrent.CompletableFuture$UniCompose.tryFire(CompletableFuture.java:929) at java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:442) at java.lang.Thread.run(Thread.java:748)
On investigating further and digging literally into every reference, identified that the NPE was being caused because items associated with loans were missing. It could have saved a lot of time in troubleshooting if these references were checked in code(defensive coding) and appropriate error messaging was in place.
Please feel free to break these into separate UI and backend stories as needed.
TestRail: Results
Attachments
Issue Links
- defines
-
UXPROD-3409 Vega - Lotus Enhancements/Bugfixes/Tech Debt
-
- Closed
-