skywalking接入例子错误,且尝试修复后也没采集到信息
- Dominant language
- Java
- Stars
- 2.4k
- Forks
- 2k
- PR merge metrics
- No merged PRs in 30d
Description

会找不到ObservationRegistry observationRegistry这个bean,然后我声明了一个之后服务能运行了,但是也采集不到dubbo的信息
我的代码:
```
@Configuration
public class ObservationConfiguration {
@Bean
ObservationRegistry observationRegistry() {
// Here we create the Observation Registry with attached handlers
ObservationRegistry registry = ObservationRegistry.create();
// Here we add a meter handler
registry.observationConfig()
.observationHandler(new ObservationHandler.FirstMatchingCompositeObservationHandler(
(ObservationHandler) new SkywalkingMeterHandler(new SkywalkingMeterRegistry())
));
return registry;
}
@Bean
ApplicationModel applicationModel(ObservationRegistry observationRegistry) {
ApplicationModel applicationModel = ApplicationModel.defaultModel();
observationRegistry.observationConfig()
.observationHandler(new ObservationHandler.FirstMatchingCompositeObservationHandler(
new SkywalkingSenderTracingHandler(), new SkywalkingReceiverTracingHandler(),
new SkywalkingDefaultTracingHandler()
));
applicationModel.getBeanFactory().registerBean(observationRegistry);
return applicationModel;
}
}
```
pom
```
org.springframework.boot
spring-boot-starter-actuator
2.7.10
org.apache.dubbo
dubbo-metrics-api
3.1.7
org.apache.skywalking
apm-toolkit-micrometer-1.10
9.0.0
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.