question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Application crash with both Micrometer and Fault Tolerance extension

See original GitHub issue

Describe the bug When you add both micrometer and fault tolerance extension, you’ll be facing the following exception

2020-09-09 12:54:35,488 ERROR [io.qua.dep.dev.IsolatedDevModeMain] (main) Failed to start quarkus: java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.arc.deployment.ArcProcessor#validate threw an exception: javax.enterprise.inject.spi.DeploymentException: javax.enterprise.inject.AmbiguousResolutionException: Ambiguous dependencies for type org.eclipse.microprofile.metrics.MetricRegistry and qualifiers [@Default]
	- java member: io.smallrye.faulttolerance.metrics.MetricsCollectorFactory#registry
	- declared on CLASS bean [types=[io.smallrye.faulttolerance.metrics.MetricsCollectorFactory, java.lang.Object], qualifiers=[@Default, @Any], target=io.smallrye.faulttolerance.metrics.MetricsCollectorFactory]
       - available beans:
		- CLASS bean [types=[org.eclipse.microprofile.metrics.MetricRegistry, java.lang.Object, io.quarkus.smallrye.faulttolerance.runtime.NoopMetricRegistry], qualifiers=[@Default, @Any], target=io.quarkus.smallrye.faulttolerance.runtime.NoopMetricRegistry]
		- PRODUCER METHOD bean [types=[org.eclipse.microprofile.metrics.MetricRegistry, io.quarkus.micrometer.runtime.binder.mpmetrics.MetricRegistryAdapter, java.lang.Object], qualifiers=[@Default, @Any], target=io.quarkus.micrometer.runtime.binder.mpmetrics.MetricRegistryAdapter produceRegistry(io.micrometer.core.instrument.MeterRegistry registry), declaringBean=io.quarkus.micrometer.runtime.binder.mpmetrics.MpMetricsRegistryProducer]

As I created the io.quarkus.smallrye.faulttolerance.runtime.NoopMetricRegistry I know what’s going on 😉

The fault tolerance need a metric registry to registers it’s metrics. In case the smallrye-metric extension is not present we provides a NoopMetricRegistry. We need to update this code to also check for the presence of the Micrometer extension.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:14 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
joao-dantascommented, Sep 17, 2020

Just saw this issue now while moving to 1.8.0. Glad that it is already fixed.

1reaction
loicmathieucommented, Sep 9, 2020

OK then, if no maven dependencies I’m OK with it 😉

Read more comments on GitHub >

github_iconTop Results From Across the Web

SmallRye Fault Tolerance - Quarkus
If your application uses the Quarkus extension for SmallRye Metrics, SmallRye Fault Tolerance will emit metrics to MicroProfile Metrics.
Read more >
Fault Tolerance in Distributed Systems - ICS, UCI
Crash failure = the process halts. It is irreversible. In synchronous system, it is easy to detect crash failure (using heartbeat signals and...
Read more >
Fault Tolerant Heap - Win32 apps | Microsoft Learn
The Fault Tolerant Heap (FTH) is a subsystem of Windows 7 responsible for monitoring application crashes and autonomously applying ...
Read more >
Implementing Microservicilities with Quarkus and MicroProfile
Microservicilities is a list of cross-cutting concerns that a service must implement apart from the business logic. These concerns include invocation, ...
Read more >
Fault-tolerant control of an error-corrected qubit - NSF PAR
With improved two-qubit gates and the use of intermediate measurements, a stabilized logical qubit can be achieved. Quantum computers are ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found