Hello Dear List,

we have a table holding email attachments as bytea, and we would like to filter out images of small dimensions, which are not of any value to our logic.

I took a look at pg_image extension, tested it, and it proved problematic, it killed my 200+ days uptime FreeBSD box :( . I dropped the extension and uninstalled this as soon as fsck finally finished.

So I would like to ask you, basically we have PNGs and JPEGs, is there an easy way of parsing their headers and getting info about their dimensions?

I could write a C function for that. For PNG it is quite easy but for JPEG it gets a little bit complicated, albeit doable, just asking for something out of the box. Currently we load images (in our java enterprise system) and filter them in Java, but this brings wildfly down to its knees pretty easy and quickly.


Thank you and happy Easter.



Reply via email to