tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carlos Oliva" <>
Subject RE: Servlet caching?
Date Fri, 22 Oct 2004 19:16:35 GMT
Thanks for your clarification.  At least the bug says "Sate In progress ..."

Let us hope...

-----Original Message-----
From: Shapira, Yoav [] 
Sent: Friday, October 22, 2004 3:01 PM
To: Tomcat Users List
Subject: RE: Servlet caching?

Note that this is an RFE, not a bug, so don't hold your breath, and
further that you can register an use your own PrintService SPI already
in JDK 1.4, and that's probably one reason the Sun folks aren't jumping
to implement this RFE.

Yoav Shapira

>-----Original Message-----
>From: Carlos Oliva []
>Sent: Friday, October 22, 2004 2:55 PM
>To: 'Tomcat Users List'
>Subject: RE: Servlet caching?
>Hi Steffen,
>Thank you for your response.  I found that there is indeed a bug fro
>problem reported for the SUN JDK.  You can view it at:
>It also seems that this bug has not yet been solved.  Its status is in
>This is a short version of the bug report:
>Bug ID:  4744405
>Votes  17
>Synopsis  RFE: lookupPrintServices() to refresh the printers list
>Category  java:classes_2d
>Reported Against  1.4 , 1.4.1
>Release Fixed
>State  In progress, request for enhancement
>Related Bugs  5028849 , 5033703
>Submit Date  10-SEP-2002
>Description  *This also happened on Windows platform.
>java version "1.4.1-rc"
>Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-rc-b19)
>Java HotSpot(TM) Client VM (build 1.4.1-rc-b19, mixed mode)
>When invoke method lookupPrintServices() on class PrinterJob or
>PrintServiceLookup, the printers list can not refreshed when adding or
>deleting printers dynamically.
>Steps to follow to reproduce the problem:
> 1. Compile and run the included test case
> 2. The print dialog shows up and avaible printers information is
>out on screen. Click "cancel" to dismiss the dialog. The test case is
> 3. Use Printer Selector Tool to add a new printer into selected
>list and save changes.
> 4. Back to the terminal that run the test case an click "enter" button
>continue. Then a new thread will be created to invoke the
>lookupPrintServices() and pop up the print dialog again.
> 5. The screen output shows that invoking lookupPrintServices() doesn't
>reflect the newly added printer information, neither does the print
>//-------- source code begin-----------//
>import java.awt.print.*;
>import javax.print.*;
>public class MTPrinterTest extends Thread {
>    public static void main(String[] args) {
>        MTPrinterTest t1 = new MTPrinterTest();
>        t1.start();
>        try {
>  ;
>        } catch (Exception e){}
>        MTPrinterTest t2 = new MTPrinterTest();
>        t2.start();
>    }
>    public void run() {
>        PrinterJob printerJob;
>        PrintService[] printServices;
>        printerJob = PrinterJob.getPrinterJob();
>        printServices = printerJob.lookupPrintServices();
>        System.out.println("Number of servies found: " +
>        for (int i =0; i< printServices.length; i++)
>            System.out.println("--> Available Printer " + i + ": " +
>        printerJob.printDialog();
>    }
>//-------- source code end ----------//
>Work Around  Exit the current running application and run it again,
>printers list get refreshed. Seems the running JVM can not get updated
>printer information
>-----Original Message-----
>From: Steffen Heil []
>Sent: Friday, October 15, 2004 8:25 AM
>To: 'Tomcat Users List'
>Subject: AW: Servlet caching?
>> If I write a java program to list the services and run the program
>the command line, I can see the newly added service right away.
>Modify your program to list the services, wait one minute, list the
>Install a printer in that time.
>See, if the application reflects that change. If not, the Lookup is
>  Steffen
>To unsubscribe, e-mail:
>For additional commands, e-mail:

This e-mail, including any attachments, is a confidential business
communication, and may contain information that is confidential, proprietary
and/or privileged.  This e-mail is intended only for the individual(s) to
whom it is addressed, and may not be saved, copied, printed, disclosed or
used by anyone else.  If you are not the(an) intended recipient, please
immediately delete this e-mail from your computer system and notify the
sender.  Thank you.

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message