User: vlada   
  Date: 01/04/21 16:52:01

  Modified:    src/docs howtoj2eedeployer.xml
  Log:
  fixed xml validity
  
  Revision  Changes    Path
  1.4       +86 -75    manual/src/docs/howtoj2eedeployer.xml
  
  Index: howtoj2eedeployer.xml
  ===================================================================
  RCS file: /cvsroot/jboss/manual/src/docs/howtoj2eedeployer.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- howtoj2eedeployer.xml     2001/04/19 11:38:11     1.3
  +++ howtoj2eedeployer.xml     2001/04/21 23:52:01     1.4
  @@ -1,12 +1,15 @@
   <?xml version = "1.0" encoding = "UTF-8"?>
  -<section>
  -     <title>Deployment on JBoss</title>        
  -     <para>        Author:<author>
  -                     <firstname>Daniel</firstname>
  -                     <surname>Schulze</surname>
  -             </author>
  -             <email>[EMAIL PROTECTED]</email>      
  -     </para>
  +<section id="deployment-on-JBoss">
  +     <sectioninfo>
  +        <author>
  +         <firstname>Daniel</firstname>
  +         <surname>Schulze</surname>
  +         <affiliation>
  +                     <address><email>[EMAIL PROTECTED]</email></address>
  +                 </affiliation>
  +        </author>
  +     </sectioninfo>
  +     <title>Deployment on JBoss</title>              
        <section>
                <title>Introduction</title>
                <para>The application deployment on JBoss is managed by the 
J2eeDeployer MBean. The 
  @@ -102,14 +105,13 @@
   all files on their place you have
   to create a deployment descriptor. This file must reside in the 
<![CDATA[<your_app_dir>/META-INF directory and must be
   named application.xml. 
  -]]></para>
  -             <para>Example: 
  -the content of a simple application.xml file: </para>
  -             <programlisting><![CDATA[
  -   <application>
  +]]></para>           
  +             <figure id="sample-application-xml">
  +                     <title>Example of application.xml file</title> 
  +                     <programlisting><![CDATA[
  + <application>
  +     <display-name>My Application</display-name>
   
  -      <display-name>My Application</display-name>
  -
         <module>
            <web>
               <web-uri>web-app.war</web-uri>
  @@ -120,62 +122,63 @@
         <module>
            <ejb>ejb-app.jar</ejb>
         </module>
  -
  -   </application>
  -]]></programlisting>
  -             <para> 
  -This descriptor describes an application that contains a web application 
  -package (JSPs/Servlets/HTML) and an 
  -ejb application (EJBs). The web applications war package is located at the 
  -root of the .ear file and is named
  -web-app.war. It will be deployed under the webcontext /myapp. The ejb package 
  -also resides in the applications 
  -root directory and is called ejb-app.jar.</para>
  + </application>
  +             ]]></programlisting>
  +             </figure>
  +             <para> This descriptor describes an application that contains a web 
application 
  +                        package (JSPs/Servlets/HTML) and an ejb application (EJBs). 
The web applications war 
  +                        package is located at the root of the .ear file and is 
named web-app.war. It will be 
  +                        deployed under the webcontext /myapp. The ejb package also 
resides in the applications 
  +                        root directory and is called ejb-app.jar.
  +             </para>
                <para>Understanding the shared classloader architecture in JBoss</para>
                <para>When an application in JBoss gets deployed, every module will 
get deployed by 
  -a separate container.
  -Every container will get its own classloader - this means that a call from one 
  -module to an other must
  -be an remote call and all parameters must be serialized, because the classes 
  -(even if they are loaded 
  -from the same physical file) are not compatible across container boundaries. 
  -To allow optimized 
  -interaction across container boundaries (local calls with parameter ... per 
  -reference) the classes 
  -that are involved in this communication must be loaded by the same 
classloader.</para>
  -             <para>In JBoss we achieve this issue with the following classloader 
architecture: </para>
  -             <para>On deployment one - common - classloader is created. This 
classloader will get 
  -all archives in its classpath
  -that are referenced (MANIFEST.MF/Class-Path <co id = "classpath.gotcha"/>)by any 
module contained in this 
  -application. </para>
  +                       a separate container. Every container will get its own 
classloader - this means that a 
  +                       call from one module to an other must be an remote call and 
all parameters must be serialized,
  +                       because the classes (even if they are loaded from the same 
physical file) are not compatible 
  +                       across container boundaries. To allow optimized interaction 
across container boundaries (local 
  +                       calls with parameter ... per reference) the classes that are 
involved in this communication 
  +                       must be loaded by the same classloader.
  +             </para>
  +             <para>In JBoss we achieve this issue with the following classloader 
architecture: 
  +             </para>
  +             <para>On deployment one common classloader is created. This 
classloader will get all archives in its 
  +                     classpath that are referenced in MANIFEST.MF/Class-Path 
entries of the each individual module
  +                     contained in enclosing application. <xref linkend = 
"web-manifest-figure"/> shows such an entry
  +             </para>
                <para>When afterwards all modules become deployed in their containers, 
the 
  -classloaders created by these containers 
  -are all children of the common classloader.</para>
  +                     classloaders created by these containers are all children of 
the common classloader.
  +             </para>
                <para>Now on runtime the communication between modules across 
container 
  -boundaries can be optimized when the classes used for the communication are 
  -loaded by the common classloader. </para>
  -             <para>example (continued): 
  -To allow our previous mentioned simple example to make use of the 
  -optimization, we must provide the classes the web 
  -module needs to communicate with the ejb module in an separate third package, 
  -lets call it ejb-client.jar.
  -This ejb-client.jar archive contains the remote interfaces of the ejbs and 
  -special method parameter types that are 
  -needed for the communication (if any). Now we put this package in the 
  -directory /lib of our application.</para>
  +                     boundaries can be optimized when the classes used for the 
communication are 
  +                     loaded by the common classloader. 
  +             </para>
  +             <para>To allow our previous mentioned simple example to make use of 
the 
  +                     optimization, we must provide the classes the web 
  +                     module needs to communicate with the ejb module in an separate 
third package, 
  +                     lets call it ejb-client.jar.
  +                     This ejb-client.jar archive contains the remote interfaces of 
the ejbs and 
  +                     special method parameter types that are 
  +                     needed for the communication (if any). Now we put this package 
in the 
  +                     directory /lib of our application.
  +             </para>
                <para>To make sure that this package is now loaded by the common 
classloader, we 
  -reference it from within the web 
  -package by adding a Class-Path: entry to the web packages MANIFEST.MF file <co id = 
"classpath.gotcha"/> 
  -that looks something like this: </para>   
  -             <literallayout>   
  +                     reference it from within the web package by adding a 
Class-Path entry to the web 
  +                     packages MANIFEST.MF file.
  +             </para> 
  +             <figure id="web-manifest-figure">
  +              <title>Example Manifest file of web module</title>     
  +               <literallayout>   
                        <computeroutput>   Manifest-Version: 1.0
  -   Class-Path: ./lib/ejb-client.jar
  -   </computeroutput>   
  -             </literallayout>
  -             <para>Now you just jar your applications directory, name it 
<![CDATA[<anyhow>.ear, and drop it in one of JBoss' 
  -autodeploy directories... 
  -]]></para>
  -             <para>the content of our simple applications archive: </para>
  +                        Class-Path: ./lib/ejb-client.jar
  +                     </computeroutput>   
  +               </literallayout>
  +             </figure>       
  +             <para>Now you just jar your applications directory, name it 
<![CDATA[<anyhow>.ear, and drop it in 
  +                     one of JBoss' autodeploy directories. ]]>
  +             </para>                 
  +             <figure id="application-manifest-figure">
  +                     <title>Example application archive contents</title>
                <literallayout>
                        <computeroutput>   META-INF/
      META-INF/MANIFEST.MF
  @@ -184,18 +187,26 @@
      web-app.war
      lib/
      lib/ejb-client.jar
  - </computeroutput>  
  +                     </computeroutput>  
                </literallayout>
  -           <calloutlist>
  -               <callout arearefs = "classpath.gotcha">
  +             </figure>
                     <para>
  -                    <orderedlist>
  -                       <listitem>The MANIFEST.MF referred to is the one inside the 
ejb or war archive and NOT the one directly in the ear archive.</listitem>
  -                       <listitem>There is a "feature" of the jdk jarfile reader 
that means that you need to have a carriage return after the Class-Path entry in the 
manifest file - otherwise it is not found.</listitem>
  -                    </orderedlist>
  +                     Note:
  +                     <orderedlist>
  +                    <listitem>
  +                             <para>The MANIFEST.MF as shown in <xref linkend = 
"web-manifest-figure"/> is inside of the ejb or the war 
  +                                     archive and NOT the one directly in the ear 
archive.
  +                             </para>
  +                        </listitem>
  +                       <listitem>
  +                             <para>There should be a carriage return after the 
Class-Path entry in the manifest file - otherwise it is not found.
  +                             </para>
  +                        </listitem>
  +                    </orderedlist>                   
                     </para>
  -               </callout>
  -           </calloutlist>
  -
  +                     <para>
  +                     Some useful references are <ulink url = 
"http://java.sun.com/docs/books/tutorial/jar/basics/manifest.html";>Manifest 
tutorial</ulink> 
  +                     and <ulink url = 
"http://java.sun.com/j2se/1.3/docs/guide/jar/jar.html";>Jar specification</ulink>
  +                     </para>
        </section>
   </section>
  
  
  

_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to