You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@geronimo.apache.org by Petr Hejl <he...@seznam.cz> on 2005/02/01 14:23:35 UTC

Deploy tool

Hi,
I'm begginner in j2ee. I have one war module with minimal web.xml and 
geronimo-jetty.xml (in WEB-INF of course), when I deploy it everything 
works fine on geronimo and sun app server. When I use this file in ear, 
again with minimal application.xml and geronimo-appliation.xml (in 
META-INF), this works only in sun app server, but not in geronimo - 
gives strange message "No deployer found..."
Files are attached. Thanks for advice.
Petr Sickboy Hejl

Error:
  Server reports: No deployer found:, 
moduleFile/home/sickboy/data/java/BookExamples/test3.ear
org.apache.geronimo.deployment.DeploymentException: No deployer found:, 
moduleFile/home/sickboy/data/java/BookExamples/test3.ear
        at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:140)
        at org.apache.geronimo.deployment.Deployer.deploy(Deployer.java:60)
        at 
org.apache.geronimo.deployment.Deployer$$FastClassByCGLIB$$734a235d.invoke(<generated>)
        at net.sf.cglib.reflect.FastMethod.invoke(FastMethod.java:87)
        at 
org.apache.geronimo.gbean.jmx.FastMethodInvoker.invoke(FastMethodInvoker.java:38)
        at 
org.apache.geronimo.gbean.jmx.GBeanMBeanOperation.invoke(GBeanMBeanOperation.java:142)
        at 
org.apache.geronimo.gbean.jmx.GBeanMBean.invoke(GBeanMBean.java:844)
        at 
com.sun.jmx.mbeanserver.DynamicMetaDataImpl.invoke(DynamicMetaDataImpl.java:213)
        at 
com.sun.jmx.mbeanserver.MetaDataImpl.invoke(MetaDataImpl.java:220)
        at 
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:815)
        at 
com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:784)
        at org.apache.geronimo.kernel.Kernel.invoke(Kernel.java:288)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at 
com.sun.jmx.mbeanserver.StandardMetaDataImpl.invoke(StandardMetaDataImpl.java:414)
        at 
com.sun.jmx.mbeanserver.MetaDataImpl.invoke(MetaDataImpl.java:220)
        at 
com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:815)
        at 
com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:784)
        at 
javax.management.remote.rmi.RMIConnectionImpl.doOperation(RMIConnectionImpl.java:1408)
        at 
javax.management.remote.rmi.RMIConnectionImpl.access$100(RMIConnectionImpl.java:81)
        at 
javax.management.remote.rmi.RMIConnectionImpl$PrivilegedOperation.run(RMIConnectionImpl.java:1245)
        at java.security.AccessController.doPrivileged(Native Method)
        at 
javax.management.remote.rmi.RMIConnectionImpl.doPrivilegedOperation(RMIConnectionImpl.java:1348)
        at 
javax.management.remote.rmi.RMIConnectionImpl.invoke(RMIConnectionImpl.java:782)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at 
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)
        at sun.rmi.transport.Transport$1.run(Transport.java:153)
        at java.security.AccessController.doPrivileged(Native Method)
        at sun.rmi.transport.Transport.serviceCall(Transport.java:149)
        at 
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
        at 
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
        at java.lang.Thread.run(Thread.java:595)





Re: Deploy tool

Posted by Petr Hejl <he...@seznam.cz>.
Thank you very much ;) _This_ is the solution ;) I read xsd definition, 
but it seems I misunderstood the moduleType section. Now everything 
works fine.
Petr


Dain Sundstrom wrote:

> On Feb 1, 2005, at 1:04 PM, Hari Kodungallur wrote:
>
>> Hi,
>>
>> I think it is looking inside the geronimo-jetty.xml file in the WAR
>> which is in an EAR. I have done a few such tests and I did not have any
>> problems.
>>
>> One thing that seems wrong in Petr's attachments is the
>> geronimo-application.xml file. The module element, if present, needs a
>> <web> element and either a <alt-dd> element or the entire <web-app> from
>> geronimo-jetty.xml as Jeremy suggested. I believe the <module> element
>> can be removed, if appropriate vendor DDs are present in each of the
>> modules.
>>
>> I tried a simple web-app with the Petr's DDs and it throws an "Invalid
>> DD". Everything works fine when I remove the <module> from
>> geronimo-application.xml. I am unsure where the "No deployer found"
>> error is coming from.
>
>
> Ah that sounds right.  You don't need to have the module declaration 
> in the geronimo-application.xml file unless you are going to include 
> either an alt-dd or a web-app element.  Here is a snippit from the 
> geronimo-application xsd:
>
>     <xs:complexType name="moduleType">
>         <xs:sequence>
>             <xs:choice>
>                 <xs:element name="connector" type="geronimo:pathType"/>
>                 <xs:element name="ejb" type="geronimo:pathType"/>
>                 <xs:element name="java" type="geronimo:pathType"/>
>                 <xs:element name="web" type="geronimo:pathType"/>
>             </xs:choice>
>             <xs:choice>
>                 <xs:element name="alt-dd" type="geronimo:pathType"/>
>                 <xs:any namespace="##other" processContents="lax"/>
>             </xs:choice>
>         </xs:sequence>
>     </xs:complexType>
>
> So you need either the alt-dd or vendor dd in the module type.
>
> -dain
>
>


Re: Deploy tool

Posted by Dain Sundstrom <ds...@gluecode.com>.
On Feb 1, 2005, at 1:04 PM, Hari Kodungallur wrote:

> Hi,
>
> I think it is looking inside the geronimo-jetty.xml file in the WAR
> which is in an EAR. I have done a few such tests and I did not have any
> problems.
>
> One thing that seems wrong in Petr's attachments is the
> geronimo-application.xml file. The module element, if present, needs a
> <web> element and either a <alt-dd> element or the entire <web-app> 
> from
> geronimo-jetty.xml as Jeremy suggested. I believe the <module> element
> can be removed, if appropriate vendor DDs are present in each of the
> modules.
>
> I tried a simple web-app with the Petr's DDs and it throws an "Invalid
> DD". Everything works fine when I remove the <module> from
> geronimo-application.xml. I am unsure where the "No deployer found"
> error is coming from.

Ah that sounds right.  You don't need to have the module declaration in 
the geronimo-application.xml file unless you are going to include 
either an alt-dd or a web-app element.  Here is a snippit from the 
geronimo-application xsd:

     <xs:complexType name="moduleType">
         <xs:sequence>
             <xs:choice>
                 <xs:element name="connector" type="geronimo:pathType"/>
                 <xs:element name="ejb" type="geronimo:pathType"/>
                 <xs:element name="java" type="geronimo:pathType"/>
                 <xs:element name="web" type="geronimo:pathType"/>
             </xs:choice>
             <xs:choice>
                 <xs:element name="alt-dd" type="geronimo:pathType"/>
                 <xs:any namespace="##other" processContents="lax"/>
             </xs:choice>
         </xs:sequence>
     </xs:complexType>

So you need either the alt-dd or vendor dd in the module type.

-dain


Re: Deploy tool

Posted by Hari Kodungallur <hk...@spikesource.com>.
Hi,

I think it is looking inside the geronimo-jetty.xml file in the WAR
which is in an EAR. I have done a few such tests and I did not have any
problems.

One thing that seems wrong in Petr's attachments is the
geronimo-application.xml file. The module element, if present, needs a
<web> element and either a <alt-dd> element or the entire <web-app> from
geronimo-jetty.xml as Jeremy suggested. I believe the <module> element
can be removed, if appropriate vendor DDs are present in each of the
modules.

I tried a simple web-app with the Petr's DDs and it throws an "Invalid
DD". Everything works fine when I remove the <module> from
geronimo-application.xml. I am unsure where the "No deployer found"
error is coming from.

Regards,
-Hari

PS: My source code is a couple of weeks old


On Tue, 2005-02-01 at 09:55, Jeremy Boynes wrote:
> Petr Hejl wrote:
> > Hi,
> > I'm begginner in j2ee. I have one war module with minimal web.xml and 
> > geronimo-jetty.xml (in WEB-INF of course), when I deploy it everything 
> > works fine on geronimo and sun app server. When I use this file in ear, 
> > again with minimal application.xml and geronimo-appliation.xml (in 
> > META-INF), this works only in sun app server, but not in geronimo - 
> > gives strange message "No deployer found..."
> 
> First guess is that we are not looking inside the WAR for the 
> geronimo-jetty.xml file when it is embedded inside the EAR - I think 
> this is by intent.
> 
> One option would be to copy the web-app element from that file into the 
> geronimo-application.xml file e.g.
> 
> <?xml version="1.0" encoding="UTF-8"?>
> 
> <application xmlns="http://geronimo.apache.org/xml/ns/j2ee/application"
> configId="test3"
> parentId="org/apache/geronimo/Server">
> 
> 	<module>
> 		<web>test3.war</web>
>      <web-app xmlns="http://geronimo.apache.org/xml/ns/web/jetty"
> xmlns:naming="http://geronimo.apache.org/xml/ns/naming"
> configId="test3">
> 
> 	<context-root>test3</context-root>
> 
> <context-priority-classloader>true</context-priority-classloader>
> </web-app>
> 	</module>
> </application>
> 
> Apologies for the formatting.
> 
> You do not need to include these files inside the archives themselves 
> (which makes things easier IMHO) - you would deploy them externally 
> using something like
> 
> java -jar bin/deployer.jar deploy myear.ear g-app.xml
> 
> Hope this helps
> --
> Jeremy


Re: Deploy tool

Posted by Dain Sundstrom <ds...@gluecode.com>.
On Feb 1, 2005, at 9:55 AM, Jeremy Boynes wrote:

> Petr Hejl wrote:
>> Hi,
>> I'm begginner in j2ee. I have one war module with minimal web.xml and 
>> geronimo-jetty.xml (in WEB-INF of course), when I deploy it 
>> everything works fine on geronimo and sun app server. When I use this 
>> file in ear, again with minimal application.xml and 
>> geronimo-appliation.xml (in META-INF), this works only in sun app 
>> server, but not in geronimo - gives strange message "No deployer 
>> found..."
>
> First guess is that we are not looking inside the WAR for the 
> geronimo-jetty.xml file when it is embedded inside the EAR - I think 
> this is by intent.

We should be.  The deployment code is designed to support the old style 
of putting a vendor-dd in each module and the new style of embedding it 
in the ear vendor-dd file.  If we are not looking for it in the web 
module, it is a bug.

-dain


Re: Deploy tool

Posted by Jeremy Boynes <jb...@apache.org>.
Petr Hejl wrote:
> Hi,
> I'm begginner in j2ee. I have one war module with minimal web.xml and 
> geronimo-jetty.xml (in WEB-INF of course), when I deploy it everything 
> works fine on geronimo and sun app server. When I use this file in ear, 
> again with minimal application.xml and geronimo-appliation.xml (in 
> META-INF), this works only in sun app server, but not in geronimo - 
> gives strange message "No deployer found..."

First guess is that we are not looking inside the WAR for the 
geronimo-jetty.xml file when it is embedded inside the EAR - I think 
this is by intent.

One option would be to copy the web-app element from that file into the 
geronimo-application.xml file e.g.

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

<application xmlns="http://geronimo.apache.org/xml/ns/j2ee/application"
configId="test3"
parentId="org/apache/geronimo/Server">

	<module>
		<web>test3.war</web>
     <web-app xmlns="http://geronimo.apache.org/xml/ns/web/jetty"
xmlns:naming="http://geronimo.apache.org/xml/ns/naming"
configId="test3">

	<context-root>test3</context-root>

<context-priority-classloader>true</context-priority-classloader>
</web-app>
	</module>
</application>

Apologies for the formatting.

You do not need to include these files inside the archives themselves 
(which makes things easier IMHO) - you would deploy them externally 
using something like

java -jar bin/deployer.jar deploy myear.ear g-app.xml

Hope this helps
--
Jeremy