Skip to content
This repository has been archived by the owner on Jan 18, 2022. It is now read-only.

Actually allowing 30MB data to be stored #88

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sagrawal31
Copy link
Contributor

AsynchronousMailAttachment domain adds a maxLength validation of 30MB but according to this SO answer https://stackoverflow.com/questions/3503841/jpa-mysql-blob-returns-data-too-long, the default type of byte[] content is BLOB hence only 65,535 bytes (64 kb) is allowed. This PR changing the datatype to LONGBLOB to allow saving at least 30MB of file.

@sagrawal31
Copy link
Contributor Author

Any update here?

@xpusostomos
Copy link

The trouble with this patch is its mysql specific. The code should be changed to BLOB, but if anything this is a bug in mysql that it insists on departing from other databases in having different blobs.

@sagrawal31
Copy link
Contributor Author

Your point makes sense @xpusostomos but if I consider MongoDB as "other databases", there is no need to even specifying a length as the database doesn't support any kind of such validation.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants