<div dir="ltr">Hi Alessio, <div><br></div><div>no problem I just got back from Kubecon and followed PTO. I will update the branches in Swarm to keep the issues updated.</div><div><br></div><div>Regards,</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Dec 14, 2017 at 9:40 AM, Alessio Soldano <span dir="ltr"><<a href="mailto:asoldano@redhat.com" target="_blank">asoldano@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>Hi Pavol,<br></div>sorry for the late reply. Weinan is now having a look at this and I believe he's getting back to you soon.<br><br></div>Cheers<span class="HOEnZb"><font color="#888888"><br></font></span></div><span class="HOEnZb"><font color="#888888">Alessio</font></span><div><div class="h5"><br><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Nov 24, 2017 at 1:38 PM, Pavol Loffay <span dir="ltr"><<a href="mailto:ploffay@redhat.com" target="_blank">ploffay@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I have tried to register ClientRequestFilter, DynamicFeature to ResteasyProviderFactory.getIns<wbr>tance(). None of these were triggered in the client. Maybe because client builder is by default using:<div>LocalResteasyProviderFactory(R<wbr>esteasyProviderFactory.newInst<wbr>ance()) see <a href="https://github.com/resteasy/Resteasy/blob/master/resteasy-client/src/main/java/org/jboss/resteasy/client/jaxrs/ResteasyClientBuilder.java#L360" target="_blank">https://github.com/resteasy/Re<wbr>steasy/blob/master/resteasy-cl<wbr>ient/src/main/java/org/jboss/<wbr>resteasy/client/jaxrs/Resteasy<wbr>ClientBuilder.java#L360</a><div><br></div><div>When I set the provider factory explicitly registered filters are executed. </div><div><br></div><div>Do you have any idea? <br></div><div><br></div><div><br></div><div>We also need to use different ExecutorService as I have mentioned in the first email. </div><div>I have extended ResteasyClientBuilder and defined service/SPI pointing to that impl;. It worked for resteasy on Jetty but not in Wildly swarm fraction. However I am not sure how reliable this is.</div><span class="m_-4370598175359771856HOEnZb"><font color="#888888"><div><br></div><div><br></div><div>Pavol</div><div><div><br></div><div><div><br></div></div></div></font></span></div></div><div class="m_-4370598175359771856HOEnZb"><div class="m_-4370598175359771856h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 22, 2017 at 6:45 PM, Pavol Loffay <span dir="ltr"><<a href="mailto:ploffay@redhat.com" target="_blank">ploffay@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I have also noticed that response code in servlet filter for an unmapped exception is 200, when the final response code returned to the client is 500. Where could I get the final response code? </div><div class="m_-4370598175359771856m_3702812837773064080HOEnZb"><div class="m_-4370598175359771856m_3702812837773064080h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Nov 22, 2017 at 6:33 PM, Pavol Loffay <span dir="ltr"><<a href="mailto:ploffay@redhat.com" target="_blank">ploffay@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Thanks Alessio,<br></div><div><br></div><div>I run into another problem now tracing related. I am using servlet filter to catch exceptions thrown from handlers. If the handler is async I get this <a href="https://pastebin.com/SxNGUVc0" target="_blank">https://pastebin.com/SxNG<wbr>UVc0</a> and the exception </div><div>is not propagated to the filter (in Jersey it is propagated, CXF has the same behaviour as resteasy). </div><div><br></div><div>Do you know how could I catch this exception?</div><div><br></div><div>Regards,</div><div><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651h5"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 21, 2017 at 6:02 PM, Alessio Soldano <span dir="ltr"><<a href="mailto:asoldano@redhat.com" target="_blank">asoldano@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi Pavol,<br></div>as mentioned on hipchat, an idea could be to rely on the ResteasyProviderFactory (which has a getInstance static method) and install a dynamic client feature in it (e.g. using registerProviderInstance(Objec<wbr>t obj) method).</div><div>Perhaps you can try that and see if it fits your scenario.</div><div>For the executor, I'm afraid I don't see an already existing solution, besides having your own ClientBuilder that overrides the executorService setup; perhaps we can make this configurable in the ResteasyProviderFactory, though.<br></div><div><br></div><div>If someone from the team has further idea, just reply ;-)</div><div>Cheers</div><span class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860HOEnZb"><font color="#888888"><div>Alessio<br></div><br></font></span></div><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860HOEnZb"><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860h5"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 21, 2017 at 5:22 PM, Pavol Loffay <span dir="ltr"><<a href="mailto:ploffay@redhat.com" target="_blank">ploffay@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi, <div><br></div><div>I am looking at microprofile-opentracing integ<wbr>ration for Wildfly Swarm. Briefly, it is a distributed tracing for JAX-RS both server and client. </div><div><br></div><div>Issue [1] describes what is necessary. But I will repeat here:</div><div><br></div><div>Server</div><div>1. register server jax-rs filters (no problem, server features are auto-discovered)</div><div>2. use servlet filter to finish the span and log any exception to the span - because jax-rs filters do not capture exceptions</div><div><br></div><div>Client</div><div>1. register tracing filters</div><div>2. use OpenTracing-aware ExecutorService - it's needed for async API to correctly propagate parent.</div><div>(3.) TCK is not defined yet. However, if they want to create spans for UnknownHostException then we cannot use jax-rs client filters because they are not executed. Network attempt happens before the filter when the exception is thrown. To solve this we have to implement tracing in resteasy or supply apache HC with tracing filters enabled (it also has some problems).</div><div><br></div><div><br></div><div>The biggest issue is with client because we need `ClientBuilder.newBuilder()` to return client/builder with enabled tracing.</div><div><br></div><div>[1] <a href="https://issues.jboss.org/browse/SWARM-1691" target="_blank">https://issues.jboss.org/brows<wbr>e/SWARM-1691</a><span class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860m_-4240671770291609041HOEnZb"><font color="#888888"><br><div><br></div><div><div><br></div>-- <br><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860m_-4240671770291609041m_-7661757849193610681gmail-m_-5740794066001034419gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:uppercase"><span>PAVOL</span> <span>LOFFAY</span></p><p style="font-family:overpass,sans-serif;margin:0px;font-size:10px;color:rgb(153,153,153)"><a href="https://www.redhat.com/" style="color:rgb(0,136,206);margin:0px" target="_blank">Red Hat <span>Česká republika</span></a></p><span style="font-family:overpass,sans-serif;font-size:10px;margin:0px;color:rgb(153,153,153)"><p style="margin:0px"><a href="https://maps.google.com/?q=%C4%8Cesk%C3%A1+republika+Purky%C5%88ova+115&entry=gmail&source=g" target="_blank">Purkyňova 115</a> TPB-B 612 00 Brno</p></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><p style="font-family:overpass,sans-serif;margin:0px 0px 6px;font-size:10px;color:rgb(153,153,153)"><span>M: <a href="tel:+421948286055" style="color:rgb(0,136,206);font-size:11px;margin:0px" target="_blank">+421948286055</a> </span></p><table style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium" border="0"><tbody><tr><td width="100px"><a href="https://red.ht/sig" target="_blank"><img width="90" height="auto"></a></td></tr></tbody></table></div></div></div></div></div></div></div>
</div></font></span></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651m_923778205305209860gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:uppercase"><span>PAVOL</span> <span>LOFFAY</span></p><p style="font-family:overpass,sans-serif;margin:0px;font-size:10px;color:rgb(153,153,153)"><a href="https://www.redhat.com/" style="color:rgb(0,136,206);margin:0px" target="_blank">Red Hat <span>Česká republika</span></a></p><span style="font-family:overpass,sans-serif;font-size:10px;margin:0px;color:rgb(153,153,153)"><p style="margin:0px"><a href="https://maps.google.com/?q=%C4%8Cesk%C3%A1+republika+Purky%C5%88ova+115+%3Chttps://maps.google.com/?q%3D%25C4%258Cesk%25C3%25A1%2Brepublika%2BPurky%25C5%2588ova%2B115%26entry%3Dgmail%26source%3Dg%3E&entry=gmail&source=g" target="_blank">Purkyňova 115</a> TPB-B 612 00 Brno</p></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><p style="font-family:overpass,sans-serif;margin:0px 0px 6px;font-size:10px;color:rgb(153,153,153)"><span>M: <a href="tel:+421948286055" style="color:rgb(0,136,206);font-size:11px;margin:0px" target="_blank">+421948286055</a> </span></p><table style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium" border="0"><tbody><tr><td width="100px"><a href="https://red.ht/sig" target="_blank"><img width="90" height="auto"></a></td></tr></tbody></table></div></div></div></div></div></div></div>
</div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-4370598175359771856m_3702812837773064080m_-8558121718871810651gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:uppercase"><span>PAVOL</span> <span>LOFFAY</span></p><p style="font-family:overpass,sans-serif;margin:0px;font-size:10px;color:rgb(153,153,153)"><a href="https://www.redhat.com/" style="color:rgb(0,136,206);margin:0px" target="_blank">Red Hat <span>Česká republika</span></a></p><span style="font-family:overpass,sans-serif;font-size:10px;margin:0px;color:rgb(153,153,153)"><p style="margin:0px"><a href="https://maps.google.com/?q=%C4%8Cesk%C3%A1+republika+Purky%C5%88ova+115&entry=gmail&source=g" target="_blank">Purkyňova 115</a> TPB-B 612 00 Brno</p></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><p style="font-family:overpass,sans-serif;margin:0px 0px 6px;font-size:10px;color:rgb(153,153,153)"><span>M: <a href="tel:+421948286055" style="color:rgb(0,136,206);font-size:11px;margin:0px" target="_blank">+421948286055</a> </span></p><table style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium" border="0"><tbody><tr><td width="100px"><a href="https://red.ht/sig" target="_blank"><img width="90" height="auto"></a></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_-4370598175359771856m_3702812837773064080gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:uppercase"><span>PAVOL</span> <span>LOFFAY</span></p><p style="font-family:overpass,sans-serif;margin:0px;font-size:10px;color:rgb(153,153,153)"><a href="https://www.redhat.com/" style="color:rgb(0,136,206);margin:0px" target="_blank">Red Hat <span>Česká republika</span></a></p><span style="font-family:overpass,sans-serif;font-size:10px;margin:0px;color:rgb(153,153,153)"><p style="margin:0px"><a href="https://maps.google.com/?q=%C4%8Cesk%C3%A1+republika+Purky%C5%88ova+115&entry=gmail&source=g" target="_blank">Purkyňova 115</a> TPB-B 612 00 Brno</p></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><p style="font-family:overpass,sans-serif;margin:0px 0px 6px;font-size:10px;color:rgb(153,153,153)"><span>M: <a href="tel:+421948286055" style="color:rgb(0,136,206);font-size:11px;margin:0px" target="_blank">+421948286055</a> </span></p><table style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium" border="0"><tbody><tr><td width="100px"><a href="https://red.ht/sig" target="_blank"><img width="90" height="auto"></a></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>
</div></div></blockquote></div><br></div></div></div></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><p style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-weight:bold;margin:0px;padding:0px;font-size:14px;text-transform:uppercase"><span>PAVOL</span> <span>LOFFAY</span></p><p style="font-family:overpass,sans-serif;margin:0px;font-size:10px;color:rgb(153,153,153)"><a href="https://www.redhat.com/" style="color:rgb(0,136,206);margin:0px" target="_blank">Red Hat <span>Česká republika</span></a></p><span style="font-family:overpass,sans-serif;font-size:10px;margin:0px;color:rgb(153,153,153)"><p style="margin:0px">Purkyňova 115 TPB-B 612 00 Brno</p></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><span style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"></span><p style="font-family:overpass,sans-serif;margin:0px 0px 6px;font-size:10px;color:rgb(153,153,153)"><span>M: <a href="tel:+421948286055" style="color:rgb(0,136,206);font-size:11px;margin:0px" target="_blank">+421948286055</a> </span></p><table border="0" style="color:rgb(0,0,0);font-family:overpass,sans-serif;font-size:medium"><tbody><tr><td width="100px"><a href="https://red.ht/sig" target="_blank"><img src="https://www.redhat.com/files/brand/email/sig-redhat.png" width="90" height="auto"></a></td></tr></tbody></table></div></div></div></div></div></div></div>
</div>