× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I have a servlet that was located on a windows tomcat server. I installed this app on the iseries. It basically creates a gif that is displayed on a web page.

Here is a snippet:
protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
random = getrandom(random);
response.setContentType("image/gif");
OutputStream out = response.getOutputStream();

When i run the app, i get the following error:

*exception*

javax.servlet.ServletException: Servlet execution threw an exception

*root cause*

java.lang.InternalError: Can't connect to X11 window server using ':0.0' as the value of the DISPLAY variable.
sun.awt.X11GraphicsEnvironment.initDisplay(Native Method)
sun.awt.X11GraphicsEnvironment.access$100(X11GraphicsEnvironment.java:64)
sun.awt.X11GraphicsEnvironment$1.run(X11GraphicsEnvironment.java:167)
java.security.AccessController.doPrivileged(AccessController.java:202)
sun.awt.X11GraphicsEnvironment.<clinit>(X11GraphicsEnvironment.java:143)
java.lang.J9VMInternals.initializeImpl(Native Method)
java.lang.J9VMInternals.initialize(J9VMInternals.java:200)
java.lang.Class.forNameImpl(Native Method)
java.lang.Class.forName(Class.java:139)
java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:79)
java.awt.image.BufferedImage.createGraphics(BufferedImage.java:1146)
java.awt.image.BufferedImage.getGraphics(BufferedImage.java:1136)
loginimggen.loginimggen.doGet(loginimggen.java:33)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)


Any idea what causes this?

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.