International-Data-Spaces-Association / DataspaceConnectorUI

User interface for the Dataspace Connector.
Apache License 2.0
10 stars 14 forks source link

Cannot upload 230kB file when creating a resource #245

Closed sebplorenz closed 2 years ago

sebplorenz commented 2 years ago

When creating a resource offering in the "Representation" tab I added a 230kB file. When saving the offering I'm getting an error message. The logs of the DSC UI contain the following error:

>>> DATA:  [ 'af8ef7ed-3db9-4030-8846-9049260ce7d1' ]
PayloadTooLargeError: request entity too large
    at readStream (/usr/src/app/src/backend/node_modules/raw-body/index.js:156:17)
    at getRawBody (/usr/src/app/src/backend/node_modules/raw-body/index.js:109:12)
    at read (/usr/src/app/src/backend/node_modules/body-parser/lib/read.js:79:3)
    at jsonParser (/usr/src/app/src/backend/node_modules/body-parser/lib/types/json.js:135:5)
    at Layer.handle [as handle_request] (/usr/src/app/src/backend/node_modules/express/lib/router/layer.js:95:5)
    at trim_prefix (/usr/src/app/src/backend/node_modules/express/lib/router/index.js:328:13)
    at /usr/src/app/src/backend/node_modules/express/lib/router/index.js:286:9
    at Function.process_params (/usr/src/app/src/backend/node_modules/express/lib/router/index.js:346:12)
    at next (/usr/src/app/src/backend/node_modules/express/lib/router/index.js:280:10)
    at urlencodedParser (/usr/src/app/src/backend/node_modules/body-parser/lib/types/urlencoded.js:100:7)

Seems that 230kB are too big for the UI to handle. But this is a common file size.

SebastianOpriel commented 2 years ago

Duplicate of https://github.com/International-Data-Spaces-Association/DataspaceConnectorUI/issues/234 solved by https://github.com/International-Data-Spaces-Association/DataspaceConnectorUI/commit/399c79f970e2c447de2197245d4d2b34dcb404d4