-Djava.awt.headless=true I used this on a servlet I did as well...
> -----Original Message-----
> From: owner-openmap-users@bbn.com [mailto:owner-openmap-users@bbn.com]
> On Behalf Of Christian Weaves
> Sent: Wednesday, June 23, 2004 3:33 AM
> To: openmap-users@bbn.com
> Subject: [OpenMap Users] Problem when deploying an application
>
> Hi there, thanks for all your help so far. I have one more question.
> Does anybody have any idea how to get around this problem?
>
> I'm running openmap as a tomcat (5.0.25) web application. I developed
> the application on Red Hat Fedora Core and it works fine. However when
> I deploy it to the actual webserver (which doesnt have a gui such as
> gnome or kde) my servlet falls over when the following call is made:
>
> MapRequestHandler iServer = new MapRequestHandler(mapProps);
>
> I guess there's something missing on the webserver but not too sure
> what! Do I need to run it headless, if so how do I do this with a web
> application? Thanks for reading..
>
> Here's the stack trace:
>
> javax.servlet.ServletException: Servlet execution threw an exception
>
> *root cause*
>
> java.lang.NoClassDefFoundError
> java.lang.Class.forName0(Native Method)
> java.lang.Class.forName(Class.java:141)
> java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(Graphics
> Environment.java:62)
> java.awt.Font.initializeFont(Font.java:308)
> java.awt.Font.<init>(Font.java:344)
> javax.swing.plaf.metal.DefaultMetalTheme$FontDelegate.getFont(Def
> aultMetalTheme.java:195)
> javax.swing.plaf.metal.DefaultMetalTheme.getFont(DefaultMetalThem
> e.java:153)
> javax.swing.plaf.metal.DefaultMetalTheme.getMenuTextFont(DefaultM
> etalTheme.java:141)
> javax.swing.plaf.metal.MetalLookAndFeel$FontActiveValue.createVal
> ue(MetalLookAndFeel.java:1408)
> javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:199)
> javax.swing.UIDefaults.get(UIDefaults.java:129)
> javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:44)
> javax.swing.UIDefaults.getFont(UIDefaults.java:349)
> javax.swing.UIManager.getFont(UIManager.java:491)
> javax.swing.LookAndFeel.installColorsAndFont(LookAndFeel.java:89)
> javax.swing.plaf.basic.BasicPopupMenuUI.installDefaults(BasicPopu
> pMenuUI.java:75)
> javax.swing.plaf.basic.BasicPopupMenuUI.installUI(BasicPopupMenuU
> I.java:63)
> javax.swing.JComponent.setUI(JComponent.java:449)
> javax.swing.JPopupMenu.setUI(JPopupMenu.java:195)
> javax.swing.JPopupMenu.updateUI(JPopupMenu.java:204)
> javax.swing.JPopupMenu.<init>(JPopupMenu.java:169)
> javax.swing.JPopupMenu.<init>(JPopupMenu.java:154)
> com.bbn.openmap.omGraphics.BasicStrokeEditorMenu.<init>(BasicStro
> keEditorMenu.java:63)
> com.bbn.openmap.omGraphics.DrawingAttributes.getBasicStrokeEditor
> (DrawingAttributes.java:1216)
> com.bbn.openmap.omGraphics.DrawingAttributes.setStroke(DrawingAtt
> ributes.java:380)
> com.bbn.openmap.omGraphics.DrawingAttributes.setProperties(Drawin
> gAttributes.java:1368)
> com.bbn.openmap.omGraphics.DrawingAttributes.<init>(DrawingAttrib
> utes.java:300)
> com.bbn.openmap.layer.shape.ShapeLayer.setProperties(ShapeLayer.j
> ava:183)
> com.bbn.openmap.util.ComponentFactory.create(ComponentFactory.jav
> a:346)
> com.bbn.openmap.util.ComponentFactory.create(ComponentFactory.jav
> a:259)
> com.bbn.openmap.util.ComponentFactory.create(ComponentFactory.jav
> a:207)
> com.bbn.openmap.image.ImageServer.getLayers(ImageServer.java:736)
> com.bbn.openmap.image.ImageServer.setProperties(ImageServer.java:
> 485)
> com.bbn.openmap.image.ImageServer.setProperties(ImageServer.java:
> 473)
> com.bbn.openmap.image.MapRequestHandler.setProperties(MapRequestH
> andler.java:110)
> com.bbn.openmap.image.MapRequestHandler.<init>(MapRequestHandler.
> java:106)
> com.bbn.openmap.image.MapRequestHandler.<init>(MapRequestHandler.
> java:102)
> com.lledr.eussafety.struts.navigation.GenerateMapImage.doPost(Gen
> erateMapImage.java:107)
> com.lledr.eussafety.struts.navigation.GenerateMapImage.doGet(Gene
> rateMapImage.java:56)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
> javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
>
>
> --
> [To unsubscribe to this list send an email to "majdart@bbn.com"
> with the following text in the BODY of the message "unsubscribe
> openmap-users"]
-- [To unsubscribe to this list send an email to "majdart@bbn.com" with the following text in the BODY of the message "unsubscribe openmap-users"]Received on Wed Jun 23 08:57:21 2004
This archive was generated by hypermail 2.1.8 : Thu May 12 2005 - 07:18:39 EDT