xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Bowditch <bowditch_ch...@hotmail.com>
Subject Re: FOP Servlet in restricted environment
Date Wed, 06 May 2009 12:58:15 GMT
Luke-SuperDude wrote:

> Hi,

Hi Luke,

> 
> I am trying to get a Fop Servlet working in a Godaddy Linux java hosting
> account. I am running a servlet like the example wich a feed with an xml.
> create a fo out of it and try to build a pdf. It works fine locally on my
> own system, but not on this restricted hosting environment. I get the
> following error and i can't figure out what to do. I know it is the fop in
> its init doing stuff:
> 
> java.security.AccessControlException: access denied (java.io.FilePermission
> /root read)
> 
> java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
> 	java.security.AccessController.checkPermission(AccessController.java:427)
> 	java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
> 	java.lang.SecurityManager.checkRead(SecurityManager.java:871)
> 	java.io.File.exists(File.java:700)
> 	org.apache.fop.fonts.FontCache.getUserHome(FontCache.java:87)
> 	org.apache.fop.fonts.FontCache.getDefaultCacheFile(FontCache.java:100)
> 	org.apache.fop.fonts.FontCache.load(FontCache.java:117)
> 	org.apache.fop.apps.FopFactory.setUseCache(FopFactory.java:692)
> 	org.apache.fop.apps.FopFactory.<init>(FopFactory.java:158)
> 	org.apache.fop.apps.FopFactory.newInstance(FopFactory.java:166)
> 	DocGen.init(DocGen.java:82)
> 	javax.servlet.GenericServlet.init(GenericServlet.java:211)
> 	sun.reflect.GeneratedMethodAccessor53.invoke(Unknown Source)

Looks like this error occurs when FOP is checking for its Font Cache. 
You can disable the cacue with the use-cache option as documented here:

http://xmlgraphics.apache.org/fop/trunk/configuration.html#general-elements

Simply put the XML element <use-cache>false</use-cache> into the 
fop.xconf file.

<snip/>

Chris



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Mime
View raw message