Hi Jean-Louis,

I cloned the Tomee project from Github:
git clone https://github.com/apache/tomee.git

and then I imported the complete project into Intellij IDEA as a Maven project.

After this I tried to run some test with the EJBContainer the result I 
mentioned. There is no local change done by myself.

I wonder I'm the only guy who uses Intellij IDEA Community Edition? What are 
you doing?

Do you have some more information for me about this comment:
"It uses the service loader méchanism so most likely an API version issue or 
the classpath without openejb-core"

Should I set some system variables etc?

Thanks,
Markus

> Gesendet: Montag, 21. November 2022 um 15:46 Uhr
> Von: "Jean-Louis Monteiro" <jlmonte...@tomitribe.com>
> An: users@tomee.apache.org
> Betreff: Re: Re: Investigating EJBContainer.createEJBContainer
>
> Did you import the entire project or just the example?
> Did IntelliJ load all the dependencies?
> 
> It's more likely an issue with IntelliJ because our build looks good on the
> CI.
> --
> Jean-Louis Monteiro
> http://twitter.com/jlouismonteiro
> http://www.tomitribe.com
> 
> 
> On Thu, Nov 17, 2022 at 4:48 PM <tomee-u...@web.de> wrote:
> 
> > Yes, I can reproduce it.
> >
> > I'm using the Intellij Community edition.
> >
> > For example from scratch I let the test run
> > org.superbiz.stateless.basic.CalculatorTest, all test fail with an errror
> > "Class Configuration".
> >
> > javax.ejb.EJBException: Provider error. No provider found
> >
> >         at
> > javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:67)
> >         at
> > javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:43)
> >         at
> > org.superbiz.stateless.basic.CalculatorTest.startTheContainer(CalculatorTest.java:38)
> >
> > Now the cool thing, if I run it outside the IDE on the command line:
> > mvn surefire:test -Dtest=org.superbiz.stateless.basic.CalculatorTest
> >
> > Results :
> >
> > Tests run: 5, Failures: 0, Errors: 0, Skipped: 0
> >
> > [INFO]
> > ------------------------------------------------------------------------
> > [INFO] BUILD SUCCESS
> >
> > The result is awesome.
> >
> > I wonder what I have to do to get the Intellij IDE to run?
> >
> > Cheers,
> > Markus
> >
> >
> > > Gesendet: Donnerstag, 17. November 2022 um 16:19 Uhr
> > > Von: "Jean-Louis Monteiro" <jlmonte...@tomitribe.com>
> > > An: users@tomee.apache.org
> > > Betreff: Re: Investigating EJBContainer.createEJBContainer
> > >
> > > Can you reproduce on a github example?
> > >
> > > As an alternative, what dependencies do you have?
> > > Can you copy/paste the java source file (with imports)?
> > >
> > > It uses the service loader méchanism so most likely an API version issue
> > or
> > > the classpath without openejb-core
> > >
> > > --
> > > Jean-Louis Monteiro
> > > http://twitter.com/jlouismonteiro
> > > http://www.tomitribe.com
> > >
> > >
> > > On Wed, Nov 16, 2022 at 3:27 PM <tomee-u...@web.de> wrote:
> > >
> > > > Hi,
> > > >
> > > > I pulled tomee from with branch tomee-8.x.
> > > >
> > > > Now when I try to let run a EJBContainer.createEJBContainer() I got
> > this
> > > > message:
> > > >
> > > > javax.ejb.EJBException: Provider error. No provider found
> > > >
> > > >         at
> > > >
> > javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:67)
> > > >         at
> > > >
> > javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:43)
> > > >         at
> > > >
> > org.superbiz.stateless.basic.CalculatorTest.startTheContainer(CalculatorTest.java:38)
> > > >         at
> > > > java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native
> > > > Method)
> > > >         at
> > > >
> > java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
> > > >         at
> > > >
> > java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> > > >         at java.base/java.lang.reflect.Method.invoke(Method.java:568)
> > > >         at
> > > >
> > org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:59)
> > > >         at
> > > >
> > org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
> > > >         at
> > > >
> > org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:56)
> > > >         at
> > > >
> > org.junit.internal.runners.statements.RunBefores.invokeMethod(RunBefores.java:33)
> > > >         at
> > > >
> > org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
> > > >         at
> > > >
> > org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
> > > >         at
> > org.junit.runners.ParentRunner$3.evaluate(ParentRunner.java:306)
> > > >         at org.junit.runners.ParentRunner.run(ParentRunner.java:413)
> > > >         at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
> > > >         at
> > > >
> > com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:69)
> > > >         at
> > > >
> > com.intellij.rt.junit.IdeaTestRunner$Repeater$1.execute(IdeaTestRunner.java:38)
> > > >         at
> > > >
> > com.intellij.rt.execution.junit.TestsRepeater.repeat(TestsRepeater.java:11)
> > > >         at
> > > >
> > com.intellij.rt.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:35)
> > > >         at
> > > >
> > com.intellij.rt.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:235)
> > > >         at
> > com.intellij.rt.junit.JUnitStarter.main(JUnitStarter.java:54)
> > > > Caused by: java.lang.ClassNotFoundException:
> > > > org.apache.openejb.OpenEjbContainer$Provider
> > > >         at
> > > >
> > java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
> > > >         at
> > > >
> > java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
> > > >         at
> > java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:520)
> > > >         at java.base/java.lang.Class.forName0(Native Method)
> > > >         at java.base/java.lang.Class.forName(Class.java:467)
> > > >         at
> > > >
> > org.apache.geronimo.osgi.locator.ProviderLocator.loadClass(ProviderLocator.java:195)
> > > >         at
> > > >
> > org.apache.geronimo.osgi.locator.ProviderLocator.locateServiceClasses(ProviderLocator.java:524)
> > > >         at
> > > >
> > org.apache.geronimo.osgi.locator.ProviderLocator.getServices(ProviderLocator.java:315)
> > > >         at
> > > >
> > javax.ejb.embeddable.EJBContainer.createEJBContainer(EJBContainer.java:54)
> > > >         ... 21 more
> > > >
> > > > Has anybody an idea how I can get the code to run?
> > > >
> > > > Thanks,
> > > > Markus
> > > >
> > > >
> > > >
> > >
> >
>

Reply via email to