The error is the following:
java.util.ServiceConfigurationError: org.apache.logging.log4j.spi.Provider: org.apache.logging.log4j.core.impl.Log4jProvider 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 org.apache.logging.log4j.util.ProviderUtil.loadProviders(ProviderUtil.java:101)
at org.apache.logging.log4j.util.ProviderUtil.<init>(ProviderUtil.java:67)
at org.apache.logging.log4j.util.ProviderUtil.lazyInit(ProviderUtil.java:142)
at org.apache.logging.log4j.util.ProviderUtil.hasProviders(ProviderUtil.java:126)
at org.apache.logging.log4j.LogManager.<clinit>(LogManager.java:89)
at org.apache.logging.slf4j.Log4jLoggerFactory.getContext(Log4jLoggerFactory.java:43)
at org.apache.logging.log4j.spi.AbstractLoggerAdapter.getLogger(AbstractLoggerAdapter.java:46)
at org.apache.logging.slf4j.Log4jLoggerFactory.getLogger(Log4jLoggerFactory.java:29)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:363)
at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:388)
at com.mulesoft.mule.munit.recording.client.RecordingClient.<clinit>(RecordingClient.java:35)
at org.mule.tooling.ui.contribution.munit.recorder.RecordingListener.launchesAdded(RecordingListener.java:196)
at org.eclipse.debug.internal.core.LaunchManager$LaunchesNotifier.run(LaunchManager.java:273)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:45)
at org.eclipse.debug.internal.core.LaunchManager$LaunchesNotifier.notify(LaunchManager.java:262)
at org.eclipse.debug.internal.core.LaunchManager.fireUpdate(LaunchManager.java:1038)
at org.eclipse.debug.internal.core.LaunchManager.addLaunch(LaunchManager.java:679)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:760)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:716)
at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:1021)
at org.eclipse.debug.internal.ui.DebugUIPlugin$2.run(DebugUIPlugin.java:1224)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
Not sure what is causing this.
Forum Ambassador Manish Kumar Yadav (Hitachi Energy)
Hi Michal,
Without seeing Studio, it is tough to add answer here but let me add for you.
- Create a Demo Project and write sample MUnit on your own , so that Munit Tools Module get added in project path,
- Or Right Click on project -> Go to the MUnit-> then Click on Configure MUnit MAVEN Support
- If above , Manual Munit Working then Go for Test Recording
Assuming :
You know the below Limitation of TEST Recording in Mule 4;
Important Limitation: https://docs.mulesoft.com/munit/2.3/test-recorder
Thanks,
Manish Kumar Yadav
MuleSoft Forum Moderator