Binary data garbled

Discussion in 'Java' started by George Weis, May 30, 2008.

  1. George Weis

    George Weis Guest

    Hi All:
    We are having a problem with an application that runs under
    tomcat. One thing this application does is send binary files to a
    remote printer. We know that the code in this application has at
    least one problem. It handles the binary data as a String object and
    we are told that we should not be doing this.
    We'll fix this, but we hope this fixes our problem, because the
    application seems to work fine for a few days. Then it gets 'stuck'
    and sends garbled binary files to remote printer from that point on.
    Sometimes restarting the tomcat application seems to fix things.
    Sometimes rebooting the host seems to fix things. Last time nothing
    did and we had to switch over to another tomcat server.
    We are running the application on tomcat 6.0.14, using
    jdk1.5.0.12.

    Anyone have any ideas?

    thanks,

    George
    George Weis, May 30, 2008
    #1
    1. Advertising

  2. George Weis

    Dave Miller Guest

    George Weis wrote:
    > Hi All:
    > We are having a problem with an application that runs under
    > tomcat. One thing this application does is send binary files to a
    > remote printer. We know that the code in this application has at
    > least one problem. It handles the binary data as a String object and
    > we are told that we should not be doing this.
    > We'll fix this, but we hope this fixes our problem, because the
    > application seems to work fine for a few days. Then it gets 'stuck'
    > and sends garbled binary files to remote printer from that point on.

    Suggests that the problem is in the use of cache. Do you write directly
    to the printer or are you writing via the host's spooler? If the former,
    check how the cache is being handled on the printer side; if the later
    look at spooler.

    > Sometimes restarting the tomcat application seems to fix things.
    > Sometimes rebooting the host seems to fix things. Last time nothing
    > did and we had to switch over to another tomcat server.

    Are you writing the data to disk as part of the process? If not, a hard
    reboot has to clear the server's cache which leaves the printer's.

    > We are running the application on tomcat 6.0.14, using
    > jdk1.5.0.12.
    >
    > Anyone have any ideas?
    >
    > thanks,
    >
    > George


    --
    Dave Miller
    Java Web Hosting at:
    http://www.cheap-jsp-hosting.com/
    Dave Miller, May 30, 2008
    #2
    1. Advertising

  3. George Weis

    Arne Vajhøj Guest

    George Weis wrote:
    > We are having a problem with an application that runs under
    > tomcat. One thing this application does is send binary files to a
    > remote printer. We know that the code in this application has at
    > least one problem. It handles the binary data as a String object and
    > we are told that we should not be doing this.
    > We'll fix this, but we hope this fixes our problem, because the
    > application seems to work fine for a few days. Then it gets 'stuck'
    > and sends garbled binary files to remote printer from that point on.
    > Sometimes restarting the tomcat application seems to fix things.
    > Sometimes rebooting the host seems to fix things. Last time nothing
    > did and we had to switch over to another tomcat server.
    > We are running the application on tomcat 6.0.14, using
    > jdk1.5.0.12.


    Start by fixing the known problem and take it from there.

    Arne
    Arne Vajhøj, May 31, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Steve Covert
    Replies:
    2
    Views:
    294
    Steve Covert
    Nov 11, 2003
  2. Peter Row

    cookie value being garbled.

    Peter Row, May 24, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    440
    Peter Row
    May 24, 2004
  3. patrick

    garbled JFrame

    patrick, Dec 5, 2003, in forum: Java
    Replies:
    0
    Views:
    444
    patrick
    Dec 5, 2003
  4. Nishi Bhonsle
    Replies:
    2
    Views:
    454
    William Brogden
    Sep 1, 2004
  5. blbmdsmith
    Replies:
    1
    Views:
    633
    Graham Dumpleton
    Dec 14, 2006
Loading...

Share This Page