Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Broken Pipe exception

1 view
Skip to first unread message

laredotornado

unread,
Oct 19, 2009, 1:28:08 PM10/19/09
to
Hi,

I'm using Java 1.5. What does a "broken pipe" exception mean in the
context of parsing a file? Below is my code and the exception is
generated on the "xmlReader.parse" line. Stack trace is below. Any
ideas for troubleshooting further are appreciated. Thanks, - Dave


GPGInputSource gpgInputSource =
new GPGInputSource(new FileInputStream(file));
try {
InputStream inputStream =
getInflatorStream(file.getName(), gpgInputSource.getInputStream
());
xmlReader.parse(new InputSource(inputStream));
} catch(AddressRequestLimitException e) {
logger.error(e.getMessage(), e);
} finally {
if(gpgInputSource.close() != 0)
logger.error(gpgInputSource.getStandardErrorString());
if(gpgOutputSource.close() != 0)
logger.error(gpgOutputSource.getStandardErrorString());
}


java.lang.RuntimeException: java.lang.RuntimeException: Broken Pipe!
at
myco.dor.dmv.driver.youthful.xml.AddressRequestFileHandler.endElement
(AddressRequestFileHandler.java:128)
at org.apache.xerces.parsers.AbstractSAXParser.endElement
(Unknown Source)
at org.apache.xerces.impl.xs.XMLSchemaValidator.endElement
(Unknown Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown
Source)
at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl
$FragmentContentDispatcher.dispatch(Unknown Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument
(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown
Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown
Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown
Source)
at myco.dor.dmv.driver.youthful.xml.AddressFileUtility.lookup
(AddressFileUtility.java:201)
at myco.dor.dmv.driver.youthful.AddressFileProcessor.execute
(AddressFileProcessor.java:178)
at myco.dor.dmv.driver.youthful.AddressFileProcessor.main
(AddressFileProcessor.java:82)
Caused by: java.lang.RuntimeException: Broken Pipe!
at
myco.dor.dmv.driver.youthful.PhpAddressNormalizer.normalAddress
(PhpAddressNormalizer.java:33)
at
myco.dor.dmv.driver.youthful.xml.AddressRequestFileHandler.endElement
(AddressRequestFileHandler.java:124)
... 12 more

markspace

unread,
Oct 19, 2009, 1:48:40 PM10/19/09
to
laredotornado wrote:
> Hi,
>
> I'm using Java 1.5. What does a "broken pipe" exception mean in the
> context of parsing a file? Below is my code and the exception is


It means "IO Error," basically. Something external to the process
closed or stopped the connection.

> generated on the "xmlReader.parse" line. Stack trace is below. Any
> ideas for troubleshooting further are appreciated. Thanks, - Dave


Google "broken pipe socket" to get some ideas what might be going on.
Basically you have to troubleshoot the network or the system, not the app.

Could be:

1. Network time out
2. CPU limit (time waiting/processing)
3. Other side closes connection/times out
4. Other local/remote network failure
5. Sunspots
6. ... other....

rossum

unread,
Oct 19, 2009, 3:05:27 PM10/19/09
to
On Mon, 19 Oct 2009 10:48:40 -0700, markspace <nos...@nowhere.com>
wrote:

>Could be:
>
>1. Network time out
>2. CPU limit (time waiting/processing)
>3. Other side closes connection/times out
>4. Other local/remote network failure
>5. Sunspots

Following the takeover, are they now Oraclespots?

rossum

>6. ... other....

Lothar Kimmeringer

unread,
Oct 19, 2009, 6:54:53 PM10/19/09
to
laredotornado wrote:

> I'm using Java 1.5. What does a "broken pipe" exception mean in the
> context of parsing a file?

The message and type of the Exception comes from your own code:


> java.lang.RuntimeException: java.lang.RuntimeException: Broken Pipe!
> at
> myco.dor.dmv.driver.youthful.xml.AddressRequestFileHandler.endElement
> (AddressRequestFileHandler.java:128)

so you might check there what can cause this.


Regards, Lothar
--
Lothar Kimmeringer E-Mail: spam...@kimmeringer.de
PGP-encrypted mails preferred (Key-ID: 0x8BC3CD81)

Always remember: The answer is forty-two, there can only be wrong
questions!

Roedy Green

unread,
Oct 19, 2009, 9:40:42 PM10/19/09
to
On Mon, 19 Oct 2009 10:28:08 -0700 (PDT), laredotornado
<laredo...@zipmail.com> wrote, quoted or indirectly quoted someone
who said :

>Caused by: java.lang.RuntimeException: Broken Pipe!

see http://mindprod.com/jgloss/runerrormessages.html#BROKENPIPE
--
Roedy Green Canadian Mind Products
http://mindprod.com

Nothing is so good as it seems beforehand.
~ George Eliot (born: 1819-11-22 died: 1880-12-22 at age: 61) (Mary Ann Evans)

EJP

unread,
Oct 19, 2009, 11:10:42 PM10/19/09
to
Roedy Green wrote:
>
>> Caused by: java.lang.RuntimeException: Broken Pipe!
>
> see http://mindprod.com/jgloss/runerrormessages.html#BROKENPIPE

All the explanations there are wrong. What this error means is that the
process reading the pipe has closed it, so you can't write more data to it.

Roedy Green

unread,
Oct 20, 2009, 2:51:51 AM10/20/09
to
On Tue, 20 Oct 2009 03:10:42 GMT, EJP
<esmond....@not.bigpond.com> wrote, quoted or indirectly quoted
someone who said :

>All the explanations there are wrong. What this error means is that the

>process reading the pipe has closed it, so you can't write more data to it.

Perhaps for this particular case. However if you google this error
message you will find others have traced the error message to the
causes mentioned.

EJP

unread,
Oct 20, 2009, 9:41:20 PM10/20/09
to
Roedy Green wrote:
> if you google this error
> message you will find others have traced the error message to the
> causes mentioned.

So you are assuming that everything on the Internet is true?

'Broken pipe' corresponds to EPIPE/SIGPIPE which has the single cause I
mentioned: 'EPIPE: An attempt is made to write to a pipe that is not
open for reading by any process'.

Lothar Kimmeringer

unread,
Oct 21, 2009, 6:42:49 AM10/21/09
to
EJP wrote:

> So you are assuming that everything on the Internet is true?
>
> 'Broken pipe' corresponds to EPIPE/SIGPIPE

Sorry to say that, but all the "broken pipe" messages I've seen
so far were lower case. In the OP we have a "Broken Pipe!" so
this message comes from different class than the usual.

As well, no sockets are used here but a FileInputStream, so
this message could come from GPGInputSource or one of the
classes the OP was implementing by himself.

So without further knowledge of the origin of this message
(and the RuntimeException being thrown instead of an IOException)
as I asked yesterday, it's just pure guessing.

0 new messages