Timeout CXF #1282
luisfalero
started this conversation in
General
Timeout CXF
#1282
Replies: 2 comments 2 replies
-
The Camel way would be to have an implementation of class MyCxfConfigurer implements CxfConfigurer {
...
@Override
public void configureClient(Client client) {
HTTPConduit httpConduit = (HTTPConduit) client.getConduit();
HTTPClientPolicy httpClientPolicy = new HTTPClientPolicy();
httpClientPolicy.setConnectionTimeout(5000); // Tiempo de espera de conexión en milisegundos
httpClientPolicy.setReceiveTimeout(5000); // Tiempo de espera para recibir en milisegundos
httpClientPolicy.setAllowChunking(false); // Deshabilitar el uso de transferencia de datos fragmentados
httpConduit.setClient(httpClientPolicy);
setupHttpConduit(httpConduit);
}
} you can then set the configurer on CxfEndpoint. The Quarkus CXF way (for clients injected through |
Beta Was this translation helpful? Give feedback.
2 replies
-
You do not need to call it, just pass an instance: @Produces
@SessionScoped
@Named("calculatorSoapEndpoint")
CxfEndpoint calculatorSoapEndpoint() throws Exception {
final CxfEndpoint result = new CxfEndpoint();
...
result.setCxfConfigurer(new MyCxfConfigurer());
...
return result;
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi Everyone,
Could someone help me by indicating how I could add timeout to how much an external SOAP service consumes?
I tried to add the commented lines but it shows an error when adding: "Client client = ClientProxy.getClient(result.createClient());"
Beta Was this translation helpful? Give feedback.
All reactions