Hi Jens,
yes correct, I mean in text format.
I try to explain in detail. I implemented my own client class with a method
to call thrift functions (std::function in the following code) and handle
some types of exceptions:
void ThriftClient::serviceCall(const std::function< void() >& functor) {
connect();
if (connected()) {
try {
functor();
} catch (apache::thrift::transport::TTransportException&
exception) {
if (exception.getType() ==
apache::thrift::transport::TTransportException::TIMED_OUT) {
disconnect();
throwTimeoutException();
}
}
}
I "throwTimeoutException()" I would like to send a message with the name of
the service function that caused the timeout.
Regards
Gianni
*Da:* Jens Geyer <[email protected]>
> *Inviato:* sabato 4 ottobre 2025 19:01
> *A:* [email protected] <[email protected]>
> *Oggetto:* Re: how to get the service function name from a client
>
> Hi,
>
> Not sure if I understand the issue ... the client should know the
> function being called, correct?
>
> Have fun,
> JensG
>
>
>
> Am 03.10.2025 um 09:36 schrieb Gianni Ambrosio:
> > Dear All,
> > from a client, when I get an
> apache::thrift::transport::TTransportException
> > and the exception type
> > is apache::thrift::transport::TTransportException::TIMED_OUT, I would
> like
> > to get the name of the thrift service function name that caused the
> > timeout. Is it possible?
> >
> > Regards
> > Gianni
>