This issue happened when view a folder which has lot of encrypted PDF files.
The error message in next cloud.log as following,
"Error while processing the image: glib: Document is encrypted","status":400}\n","exception"
This issue will exhaust PHP threads when the folder has lot of encrypted PDF files and the Nextcloud server will become unavailable.
The workaround might be turn off the PDF preview.