Is there a workaround for using GlideSysAttachment().getContent() for file size is bigger than 5MB ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2022 08:00 PM
According to the Docs, GlideSysAttachment().getContent() is limited to read 5MB.
Is there are workaround for files that is bigger than 5MB ?
GlideSysAttachment | ServiceNow Developers
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-12-2022 08:26 PM
Hi @kozy_f
There is a size limit in place for prcessing attachments to manage memory on your instance. The only way around this would be to increase the out of the box max size of 5MB, but this can cause memory issues and could potentially cause the instance to run out of memory. Changing this limitation would NOT be supported by ServiceNow if this caused any performance repercussions. That being said, you could increase the max size limit as follows...
1. System Properties -> All Properties
2. Click "New" to create a new system property "com.glide.attachment.max_get_size" and enter value in bytes (for example 7000000 for 7MB).
3. Save