Michael Vorburger created FINERACT-1251: -------------------------------------------
Summary: Uploaded Document Size is determined and stored wrong Key: FINERACT-1251 URL: https://issues.apache.org/jira/browse/FINERACT-1251 Project: Apache Fineract Issue Type: Bug Reporter: Michael Vorburger While writing the (new) {{DocumentTest}} working on FINERACT-1218 for FINERACT-1201, I've noticed that the {{fileSize}} which the {{DocumentManagementApiResource.createDocument()}} puts into the {{DocumentCommand}} to hand the {{DocumentWritePlatformService.createDocument()}} to save in the DB is wrong. The size of the uploaded document is NOT {{@HeaderParam("Content-Length") @Parameter(description = "Content-Length")}}. The same mistake is made in and will have to be fixed in the {{DocumentManagementApiResource.updateDocument()}} method The {{DocumentTest}} currently just "compensates" for the currently wrong size. PS: The {{ImagesApiResource}} has a similar bug, but it's less important there because the {{fileSize}} is only used to validate that no huge images are uploaded, and not actually stored in the database, so it doesn't matter that much there. -- This message was sent by Atlassian Jira (v8.3.4#803005)