reta commented on code in PR #1346:
URL: https://github.com/apache/cxf/pull/1346#discussion_r1290854141


##########
systests/spring-boot/src/test/java/org/apache/cxf/systest/jaxrs/spring/boot/SpringJaxrsObservabiityTest.java:
##########
@@ -0,0 +1,173 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.cxf.systest.jaxrs.spring.boot;
+
+import java.time.Duration;
+
+import com.fasterxml.jackson.jakarta.rs.json.JacksonJsonProvider;
+
+import brave.sampler.Sampler;
+import jakarta.ws.rs.client.ClientBuilder;
+import jakarta.ws.rs.client.WebTarget;
+import jakarta.ws.rs.core.Response;
+import org.apache.cxf.Bus;
+import org.apache.cxf.feature.Feature;
+import org.apache.cxf.systest.ArrayListSpanReporter;
+import org.apache.cxf.systest.jaxrs.resources.Library;
+import org.apache.cxf.tracing.micrometer.ObservationClientFeature;
+import org.apache.cxf.tracing.micrometer.ObservationFeature;
+import org.springframework.beans.factory.annotation.Autowired;
+import 
org.springframework.boot.actuate.autoconfigure.observation.web.servlet.WebMvcObservationAutoConfiguration;
+import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
+import 
org.springframework.boot.test.autoconfigure.actuate.observability.AutoConfigureObservability;
+import org.springframework.boot.test.context.SpringBootTest;
+import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
+import org.springframework.boot.test.web.server.LocalServerPort;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.ComponentScan;
+import org.springframework.test.context.ActiveProfiles;
+import zipkin2.Span;
+import zipkin2.reporter.Reporter;
+
+import io.micrometer.core.instrument.MeterRegistry;
+import io.micrometer.core.instrument.Tags;
+import io.micrometer.core.tck.MeterRegistryAssert;
+import io.micrometer.observation.ObservationRegistry;
+import io.micrometer.tracing.Span.Kind;
+import io.micrometer.tracing.test.simple.SpansAssert;
+
+import org.junit.jupiter.api.AfterEach;
+import org.junit.jupiter.api.Test;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.awaitility.Awaitility.await;
+import static org.hamcrest.Matchers.hasSize;
+
+@SpringBootTest(webEnvironment = WebEnvironment.RANDOM_PORT, classes = 
SpringJaxrsObservabiityTest.TestConfig.class)
+@ActiveProfiles("jaxrs")
+@AutoConfigureObservability
+public class SpringJaxrsObservabiityTest {
+
+    @Autowired
+    private MeterRegistry registry;
+    
+    @Autowired
+    private ObservationRegistry observationRegistry;
+
+    @Autowired
+    private ArrayListSpanReporter arrayListSpanReporter;
+
+    @LocalServerPort
+    private int port;
+
+    @EnableAutoConfiguration(exclude = 
WebMvcObservationAutoConfiguration.class)

Review Comment:
   For JAX-RS (aka WebMvc :D), the most common scenario would be to have HTTP 
traces but I have not found the way to trade `rpc` for `http`, without 
`WebMvcObservationAutoConfiguration` I do have both on server side, could you 
help me please to understand the proper configuration?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to