thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nitay <nit...@gmail.com>
Subject Silencing GlobalOutput (TOutput) in C++
Date Mon, 14 Sep 2009 05:28:01 GMT
Hey guys,

I have a thrift client that connects to a server in a loop. If it  
fails for whatever reason, it catches the exception, sleeps for three  
seconds, and retries.
Every time this happens however, I get lots of messages spewed to the  
screen by Thrift that look like the following:

Thrift: Sun Sep 13 22:06:42 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused
Thrift: Sun Sep 13 22:06:42 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused
Thrift: Sun Sep 13 22:06:42 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused
...
Thrift: Sun Sep 13 22:06:45 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused
Thrift: Sun Sep 13 22:06:45 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused
Thrift: Sun Sep 13 22:06:45 2009 TSocket::open() connect() <Host:  
localhost Port: 11001>Connection refused

I tracked this down in the source to calls like:

GlobalOutput.perror("TSocket::open() connect() " + getSocketInfo(),  
errno_copy);

GlobalOutput is a global that is of type TOutput. From what I can see  
there is no interface in TOutput to silence these messages. Is there  
something I'm missing here? Should I file a JIRA to silence TOutput?

As a side note, oddly enough these messages always come in batches of  
threes as you can see above, which I could not figure out why. If  
anyone can enlighten me on this I'd appreciate it.

Thanks,
-n
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message