geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "mika" <mika.wo...@gentlemansclub.de>
Subject Re: Re: Re: Re: what does a ejb-jar.xml looks like?
Date Mon, 17 Jul 2006 06:22:59 GMT
Well,

first I found out, that in the <Geronimo>\repository\org\apache\geronimo\spec-folder
a list of supported specifications are. There i found the geronimo-ejb_2.1_spec and geronimo-j2ee_1.4_spec
folders. I hope this helps you...

now my application.xml:

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE application PUBLIC '-//Sun Microsystems, Inc.//DTD J2EE Application 1.3//EN'
'http://java.sun.com/dtd/application_1_3.dtd'>

<application>
  <display-name>MyApp</display-name>
  <description>MyApp Server</description>
  <module>
    <ejb>myserver.jar</ejb>
  </module>
  <module>
    <web>
      <web-uri>myserver.war</web-uri>
      <context-root>/myapp</context-root>
    </web>
  </module>
  <module>
    <web>
      <web-uri>mysample.war</web-uri>
      <context-root>/sample</context-root>
    </web>
  </module>
  <module>
    <web>
      <web-uri>wsci.war</web-uri>
      <context-root>/service</context-root>
    </web>
  </module>
</application>

(There are also these WAR's in the EAR and some other JAR's which needn't be wrote in there...
because in the other two JAR's are only some classes, as i understood)

I've used this ear-file in some other application-servers and I thought, that I can use it
unchanged in Geronimo, too. But this is a wrong assumption, as i know now ;-).

I think that there must be done some changes...

The beginning of the ejb-jar.xml looks like following:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
"http://java.sun.com/dtd/ejb-jar_2_0.dtd">

<ejb-jar>
<!-- ... -->
</ejb-jar>

Do I have to change it too? Or is it enough to create a geronimo-ejb-jar.xml ?

Thanks,
 mika

> To start with, why don't you take a look at this:
> 
> http://chariotsolutions.com/geronimo/ejb.html#id2604520
> 
> There should be a DOCTYPE or xmlns at the very beginning of your
> ejb-jar.xml, and by comparing the values in the DOCTYPE or xmlns to
> the samples at that link, you should be able to figure out what
> version of EJB you are using.  I'm not sure Geronimo supports "EJB
> 1.0" but that's very, very old, so I think you may find you're using
> "EJB 1.1" at a minimum.  If you don't see the DOCTYPE or xmlns listed
> in your file, or they don't match anything at that link, can you post
> the first few lines of your ejb-jar.xml including the DOCTYPE or xmlns
> here?
> 
> Also, can you post your application.xml?  That would let us confirm
> the version of the EAR packaging it's using, and make sure it's
> listing the right values for your EAR.  As I understand it you have 3
> WARs, 1 EJB JAR, and 2 regular JARs in the EAR, so we want to make
> sure you have the right entries in application.xml for the EAR.
> 
> Thanks,
>      Aaron
> 
> On 7/14/06, mika <mika.works@gentlemansclub.de> wrote:
> > Hi Aaron,
> >
> > first i thank you for your advices.
> >
> > Now my answears:
> > I don't know exactly what EJB's are. I only know that they are
> Enterprise Java Beans. But what they are doing is a little black cloud in my mind.
> >
> > My EAR consists of three JAR's, three WAR's and an application.xml as
> well as a principle.xml.
> >
> > In one of the JAR's is an ejb-jar.xml. This file consists, as you wrote,
> of the Beans decided to deploy.
> > This JAR is the only which has to be deployed. The other two are some
> additional informations... some classes more or less.
> >
> > The versions of J2EE and EJB depends on what geronimo 1.1 requires. I
> think, that they are not higher than J2EE 1.2 and EJB 1 (i asked my boss, and
> this is what he is supposing).
> >
> > In association with this and my thinking of solve this problem I suggest
> that I have to set an URL to the ejb-jar.xml in the contained JAR-file of
> the EAR.
> > Is this the right approach?
> > If you could tell me the way of setting the ejb-jar.xml-path so, that
> geronimo doesn't make this error, I would thank you very much!
> >
> > PS: assume that the ejb-jar.xml is contained in the META-INF-directory
> of MyJAR.jar, which is contained in MyEAR.ear. This is only for better
> understanding :-).
> >
> > Thanks a lot, mika
> >
> > > Well, it sounds like the EAR contains an EJB JAR, or at least, the
> > > META-INF/application.xml for the EAR is *saying* that it contains an
> > > EJB JAR.
> > >
> > > That EJB JAR should be a JAR file in the EAR, that contains a file
> > > META-INF/ejb-jar.xml file.
> > >
> > > The format of the ejb-jar.xml file is controlled by the EJB
> > > specification.  It's a bit different depending on which revision of
> > > J2EE and EJB you're targeting.  But there are DTDs or XML Schemas that
> > > dictate the format for each version.
> > >
> > > As far as what the content of the ejb-jar.xml file is supposed to be,
> > > that depends on what the EJB JAR contains -- there should be entries
> > > in ejb-jar.xml for each EJB you want to deploy, for example, in the
> > > format dictated by the DTD or Schema.
> > >
> > > So from here, I have a few questions for you:
> > >  - Do you know what EJBs are and how to use them?
> > >  - Do you think your EAR contains an EJB JAR?
> > >  - Would it help you if I gave you the URLs for the ejb-jar.xml DTDs
> or
> > > Schemas?
> > >  - If so, do you know which EJB or J2EE spec version you're targeting?
> > >
> > > Thanks,
> > >     Aaron
> > --
> >
> >
> > Echte DSL-Flatrate dauerhaft für 0,- Euro*!
> > "Feel free" mit GMX DSL! http://www.gmx.net/de/go/dsl
> >

-- 


Echte DSL-Flatrate dauerhaft für 0,- Euro*!
"Feel free" mit GMX DSL! http://www.gmx.net/de/go/dsl

Mime
View raw message