• 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

Simple Test Bean in JRun - can't get deploy tool to see bean

 
Trailboss
Posts: 23778
IntelliJ IDE Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've done EJB before with weblogic and with Sun's reference implementation. But I can't get it to work with JRun.
Here's my bean code:
<pre>
package ejb ;
import java.util.*;
import javax.ejb.* ;
public class TestBean implements SessionBean
{
public String getText()
{
return "Spoooooon!" ;
}
public void setSessionContext( SessionContext ctx ){}
public void ejbRemove(){}
public void ejbActivate(){}
public void ejbPassivate(){}
}
package ejb ;
import javax.ejb.* ;
import java.rmi.* ;
public interface TestHome extends EJBHome
{
public TestRemote create() throws CreateException, RemoteException;
}
package ejb ;
import javax.ejb.* ;
import java.rmi.* ;
public interface TestRemote extends EJBObject
{
public String getText() throws RemoteException ;
}
</pre>
And here is my ejb_jar.xml:
<pre>
<?xml version="1.0"?>
<!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN' 'http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd'>
<ejb-jar>
<enterprise-beans>
<session>
<ejb-name>TestBean</ejb-name>
<home>ejb.TestHome</home>
<remote>ejb.TestRemote</remote>
<ejb-class>ejb.TestBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
</session>
</enterprise-beans>
<assembly-descriptor>
<container-transaction>
<method>
<ejb-name>TestBean</ejb-name>
<method-intf>Remote</method-intf>
<method-name>*</method-name>
</method>
<trans-attribute>Required</trans-attribute>
</container-transaction>
</assembly-descriptor>
</ejb-jar>
</pre>
And my default.properties:
<pre>
ejipt.maxContexts=100
</pre>
I put them in a jar and the jar tool says this:
<pre>
added manifest
adding: ejb/TestBean.class(in = 562) (out= 304)(deflated 45%)
adding: ejb/TestHome.class(in = 275) (out= 204)(deflated 25%)
adding: ejb/TestRemote.class(in = 251) (out= 189)(deflated 24%)
adding: META-INF/ejb_jar.xml(in = 905) (out= 361)(deflated 60%)
adding: default.properties(in = 23) (out= 25)(deflated -8%)
</pre>
I copy it all to the deploy directory and run the JRun deploy tool and get back "No beans found in jar(s)". What am I doing wrong?
 
Yup, yup, yup. Tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic