• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Testing persistence Api(EJB 3) outside jboss container

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I want to test persistence api outside jboss container.
For that i am using jboss embeddable ..I am trying to run the sample that is given on jboss site but didn't know how to configure the whole sample,so as to use jboss embeddable for JUnit test
After somehow configuring it i am getting "Local server not initialized" error.
Any idea how to do it with Jboss Embeddable
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Basically you will have the following code in your setup



Make sure you call
// Shutdown EJB container
EJB3StandaloneBootstrap.shutdown();

When you are done with the test.

The some-beans.xml looks something like this. The name of the file should be in the format of XXX-beans.xml



So now you can do code that gets and calls EJBs like so



HTH

Mark
 
Do Re Mi Fa So La Tiny Ad
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic