-
Type:
Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 4.0
-
Fix Version/s: 3.4.8
-
Component/s: Transformations
-
Labels:None
-
Environment:Mac OS X
-
Bug Priority:
PDF thumbnails fail to render under Mac OS X stock JRE deployment. This is due to Mac specifics of JRE (http://developer.apple.com/library/mac/#technotes/tn2083/_index.html). Solution, in case of Tomcat, is to add "-Djava.awt.headless=true" to JAVA_OPTS in tomcat/scripts/ctl.sh
Sample stack trace:
Caused by: org.alfresco.service.cmr.repository.ContentIOException: 00300068 Content conversion failed:
reader: ContentAccessor[ contentUrl=store://2012/1/30/15/42/7f4429ba-56ed-4bbe-9f92-ece728ede881.bin, mimetype=application/pdf, size=1162925, encoding=UTF-8, locale=en_US]
writer: ContentAccessor[ contentUrl=store:///Applications/alfresco-4.0.c/tomcat/temp/Alfresco/FailoverTransformer_intermediate_PdfBoxPdfToImageContentTransformer_2073277337537723264.png, mimetype=image/png, size=0, encoding=UTF-8, locale=en_US]
options: ImageTransformationOptions [commandOptions=, resizeOptions=ImageResizeOptions [width=100, height=100, maintainAspectRatio=true, percentResize=false, resizeToThumbnail=false, allowEnlargement=false], cropOptions=null, autoOrient=true]
at org.alfresco.repo.content.transform.AbstractContentTransformer2.transform(AbstractContentTransformer2.java:177)
at org.alfresco.repo.content.transform.FailoverContentTransformer.transformInternal(FailoverContentTransformer.java:158)
at org.alfresco.repo.content.transform.AbstractContentTransformer2.transform(AbstractContentTransformer2.java:161)
... 88 more
Caused by: java.lang.NoClassDefFoundError: Could not initialize class java.awt.image.BufferedImage
at org.apache.pdfbox.pdmodel.PDPage.convertToImage(PDPage.java:716)
...