Skip to content

munitnyucontextmanager non helpful error reporting #30536

Closed
@maxandersen

Description

@maxandersen

Describe the bug

I have an app which does not do much but besides starting up a javamail background thread and on every devmode restart I get this error:

2023-01-23 10:42:15,125 INFO  [io.quarkus] (Quarkus Main Thread) qilt stopped in 0.015s
java.util.ServiceConfigurationError: org.eclipse.microprofile.context.spi.ContextManagerExtension: io.smallrye.mutiny.context.MutinyContextManagerExtension not a subtype
	at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:589)
	at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1237)
	at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1265)
	at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1300)
	at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1385)
	at java.base/java.lang.Iterable.forEach(Iterable.java:74)
	at io.smallrye.context.SmallRyeContextManager$Builder.discoverContextManagerExtensions(SmallRyeContextManager.java:318)
	at io.smallrye.context.SmallRyeContextManager$Builder.build(SmallRyeContextManager.java:335)
	at io.smallrye.context.SmallRyeContextManagerProvider.getContextManager(SmallRyeContextManagerProvider.java:48)
	at io.smallrye.context.SmallRyeContextManagerProvider.getContextManager(SmallRyeContextManagerProvider.java:37)
	at io.smallrye.context.SmallRyeContextManagerProvider.getContextManager(SmallRyeContextManagerProvider.java:11)
	at org.eclipse.microprofile.context.ManagedExecutor.builder(ManagedExecutor.java:128)
	at io.quarkus.smallrye.context.runtime.SmallRyeContextPropagationRecorder$4.get(SmallRyeContextPropagationRecorder.java:100)
	at org.eclipse.microprofile.context.ManagedExecutor_f18425d88d17864051ab3b7c3538397f8b96ea03_Synthetic_Bean.createSynthetic(Unknown Source)
	at org.eclipse.microprofile.context.ManagedExecutor_f18425d88d17864051ab3b7c3538397f8b96ea03_Synthetic_Bean.create(Unknown Source)
	at org.eclipse.microprofile.context.ManagedExecutor_f18425d88d17864051ab3b7c3538397f8b96ea03_Synthetic_Bean.create(Unknown Source)
	at io.quarkus.arc.impl.AbstractSharedContext.createInstanceHandle(AbstractSharedContext.java:113)
	at io.quarkus.arc.impl.AbstractSharedContext$1.get(AbstractSharedContext.java:37)
	at io.quarkus.arc.impl.AbstractSharedContext$1.get(AbstractSharedContext.java:34)
	at io.quarkus.arc.impl.LazyValue.get(LazyValue.java:26)
	at io.quarkus.arc.impl.ComputingCache.computeIfAbsent(ComputingCache.java:69)
	at io.quarkus.arc.impl.AbstractSharedContext.get(AbstractSharedContext.java:34)
	at io.quarkus.arc.impl.ClientProxies.getApplicationScopedDelegate(ClientProxies.java:21)
	at org.eclipse.microprofile.context.ManagedExecutor_f18425d88d17864051ab3b7c3538397f8b96ea03_Synthetic_ClientProxy.arc$delegate(Unknown Source)
	at org.eclipse.microprofile.context.ManagedExecutor_f18425d88d17864051ab3b7c3538397f8b96ea03_Synthetic_ClientProxy.toString(Unknown Source)
	at java.base/java.lang.String.valueOf(String.java:2951)
	at io.smallrye.config.common.utils.ConfigSourceUtil.propertiesToMap(ConfigSourceUtil.java:57)
	at io.smallrye.config.SysPropConfigSource.getSystemProperties(SysPropConfigSource.java:57)
	at io.smallrye.config.SysPropConfigSource.<init>(SysPropConfigSource.java:38)
	at io.smallrye.config.SmallRyeConfigBuilder.getDefaultSources(SmallRyeConfigBuilder.java:166)
	at io.smallrye.config.SmallRyeConfig$ConfigSources.buildSources(SmallRyeConfig.java:589)
	at io.smallrye.config.SmallRyeConfig$ConfigSources.<init>(SmallRyeConfig.java:542)
	at io.smallrye.config.SmallRyeConfig.<init>(SmallRyeConfig.java:68)
	at io.smallrye.config.SmallRyeConfigBuilder.build(SmallRyeConfigBuilder.java:532)
	at io.quarkus.runtime.configuration.QuarkusConfigFactory.getConfigFor(QuarkusConfigFactory.java:36)
	at io.smallrye.config.SmallRyeConfigProviderResolver.getConfig(SmallRyeConfigProviderResolver.java:76)
	at io.smallrye.config.SmallRyeConfigProviderResolver.getConfig(SmallRyeConfigProviderResolver.java:64)
	at org.eclipse.microprofile.config.ConfigProvider.getConfig(ConfigProvider.java:85)
	at io.quarkus.runtime.configuration.ConfigInstantiator.handleObject(ConfigInstantiator.java:56)
	at io.quarkus.runtime.logging.LoggingSetupRecorder.handleFailedStart(LoggingSetupRecorder.java:73)
	at io.quarkus.runtime.logging.LoggingSetupRecorder.handleFailedStart(LoggingSetupRecorder.java:68)
	at io.quarkus.deployment.dev.IsolatedDevModeMain.restartApp(IsolatedDevModeMain.java:233)
	at io.quarkus.deployment.dev.IsolatedDevModeMain.restartCallback(IsolatedDevModeMain.java:203)
	at io.quarkus.deployment.dev.RuntimeUpdatesProcessor.doScan(RuntimeUpdatesProcessor.java:537)
	at io.quarkus.deployment.console.ConsoleStateManager.forceRestart(ConsoleStateManager.java:141)
	at io.quarkus.deployment.console.ConsoleStateManager.lambda$installBuiltins$0(ConsoleStateManager.java:98)
	at io.quarkus.deployment.console.ConsoleStateManager$1.accept(ConsoleStateManager.java:73)
	at io.quarkus.deployment.console.ConsoleStateManager$1.accept(ConsoleStateManager.java:46)
	at io.quarkus.deployment.console.AeshConsole.lambda$setup$1(AeshConsole.java:275)
	at org.aesh.terminal.EventDecoder.accept(EventDecoder.java:118)
	at org.aesh.terminal.EventDecoder.accept(EventDecoder.java:31)
	at org.aesh.terminal.io.Decoder.write(Decoder.java:133)
	at org.aesh.readline.tty.terminal.TerminalConnection.openBlocking(TerminalConnection.java:216)
	at org.aesh.readline.tty.terminal.TerminalConnection.openBlocking(TerminalConnection.java:203)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:829)

I assume its because I have some system property set or some serviceloader in classpath that is messing it up but the error is not infomrative.

Expected behavior

would have expected the error to first not happen but if/when it does it should say what in particular it has an issue with.

"io.smallrye.mutiny.context.MutinyContextManagerExtension not a subtype" is not informative.

What is not a subtype or what? what key or config source is it failing on? just some hints would be nice.

Actual behavior

No response

How to Reproduce?

No response

Output of uname -a or ver

No response

Output of java -version

No response

GraalVM version (if different from Java)

No response

Quarkus version or git rev

No response

Build tool (ie. output of mvnw --version or gradlew --version)

No response

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions