Thank you, that works.
 
I created a separate deployment plan for TomCat cluster and deployed it
successfully - it shows up as running under system modules. However,
when I"m trying to deploy a web app referencing that cluster
configuration - it fails. Any ideas why it can't find TomcatCluster
would be appreciated. Do I need to declare gbean-ref to TomcatCluster in
geronimo-web.xml? Actually I tried and still doesn't find.
 
Here is part of geronimo-web.xml:
 
<dependencies>

    ......

<dependency>

<groupId>returnpath</groupId>

<artifactId>TomcatCluster</artifactId>

</dependency>

...

 

<cluster>TomcatCluster</cluster>

....

 

Fails to start.

Caused by: org.apache.geronimo.gbean.InvalidConfigurationException:
Configuration returnpath/prequal/1.7.0-myview/war failed to start due to
the following reasons:
  The service
J2EEApplication=null,j2eeType=WebModule,name=returnpath/prequal/1.7.0-my
view/war did not start because
returnpath/prequal/1.7.0-myview/war?J2EEApplication=null,WebModule=retur
npath/prequal/1.7.0-myview/war,j2eeType=Cluster,name=TomcatCluster did
not start.
 
        at
org.apache.geronimo.kernel.config.ConfigurationUtil.startConfigurationGB
eans(ConfigurationUtil.java:403)
        ... 14 more
 
 
Cluster deployment plan:
<?xml version="1.0" encoding="UTF-8"?>

<module xmlns="http://geronimo.apache.org/xml/ns/deployment-1.1";>

<environment>

<moduleId>

<groupId>returnpath</groupId>

<artifactId>TomcatCluster</artifactId>

<version>1.2.0</version>

<type>car</type>

</moduleId>

<dependencies>

<dependency>

<groupId>geronimo</groupId>

<artifactId>tomcat</artifactId>

<type>car</type>

</dependency>

</dependencies>

</environment>

<!-- Cluster --> 

<gbean name="TomcatCluster"
class="org.apache.geronimo.tomcat.cluster.CatalinaClusterGBean">

<attribute
name="className">org.apache.catalina.cluster.tcp.SimpleTcpCluster</attri
bute> 

<attribute name="initParams">

managerClassName=org.apache.catalina.cluster.session.DeltaManager

expireSessionsOnShutdown=false

useDirtyFlag=false

notifyListenersOnReplication=true

</attribute> 

<reference name="Membership">

<name>TomcatMembership</name> 

</reference>

<reference name="Receiver">

<name>TomcatReceiver</name> 

</reference>

<reference name="Sender">

<name>TomcatSender</name> 

</reference>

<reference name="TomcatValveChain">

<name>ReplicationValve</name> 

</reference>

<!-- 

<reference name="ClusterDeployer"> <name>FarmWarDeployer</name>
</reference> 

--> 

</gbean>

<!-- Membership --> 

<gbean name="TomcatMembership"
class="org.apache.geronimo.tomcat.cluster.MembershipServiceGBean">

<attribute
name="className">org.apache.catalina.cluster.mcast.McastService</attribu
te> 

<attribute name="initParams">

mcastAddr=228.0.0.9

<!-- mcastBindAddress=IPAddressMultiIn DON'T SET THIS - IT WILL SCREW
YOU -->

mcastPort=45564

mcastFrequency=500

mcastDropTime=3000

</attribute> 

</gbean>

<!-- Receiver --> 

<gbean name="TomcatReceiver"
class="org.apache.geronimo.tomcat.cluster.ReceiverGBean">

<attribute
name="className">org.apache.catalina.cluster.tcp.ReplicationListener</at
tribute> 

<attribute name="initParams">

tcpListenAddress=172.16.215.2

tcpListenPort=4001

tcpSelectorTimeout=100

tcpThreadCount=6

</attribute> 

</gbean>

<!-- Sender --> 

<gbean name="TomcatSender"
class="org.apache.geronimo.tomcat.cluster.SenderGBean">

<attribute
name="className">org.apache.catalina.cluster.tcp.ReplicationTransmitter<
/attribute> 

<attribute name="initParams">

replicationMode=pooled

ackTimeout=15000

</attribute> 

</gbean>

<!-- Valves --> 

<gbean name="ReplicationValve"
class="org.apache.geronimo.tomcat.ValveGBean">

<attribute
name="className">org.apache.catalina.cluster.tcp.ReplicationValve</attri
bute> 

<attribute
name="initParams">filter=.*\.gif;.*\.js;.*\.css;.*\.png;.*\.jpeg;.*\.jpg
;.*\.htm;.*\.html;.*\.txt;</attribute> 

<reference name="NextValve">

<name>JvmRouteBinderValve</name> 

</reference>

</gbean>

<!-- Valve to allow sticky session failover to work properly for more
than two nodes --> 

<gbean name="JvmRouteBinderValve"
class="org.apache.geronimo.tomcat.ValveGBean">

<attribute
name="className">org.apache.catalina.cluster.session.JvmRouteBinderValve
</attribute> 

<attribute name="initParams">enabled=true</attribute> 

</gbean>

</module>


________________________________

From: David Carew [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 18, 2006 3:26 PM
To: user@geronimo.apache.org
Subject: Re: Creating a mail session


You can deploy it on its own. Just point the deployer to the plan. If
using the Admin Console just select "Deploy New" and fill in the plan
field (leaving the application/module field empty).  


On 12/18/06, Pavel Maximov <[EMAIL PROTECTED]> wrote: 

        Saw this email.
        
        I'm trying to create a system-wide cluster config as a
deployable module
        and then reference it from geronimo-web.xml
        
        The deployment descriptor below - should it be packaged as an
ejb-jar?
        And do you deploy it as an application or as a common-lib?
        
        Thank you,
        --Pavel.
        
        -----Original Message-----
        From: Mike Perham [mailto:[EMAIL PROTECTED]
        Sent: Wednesday, November 29, 2006 5:16 PM 
        To: user@geronimo.apache.org
        Subject: Re: Creating a mail session
        
        Thanks, all.  The following plan will create a system-wide mail
session.
        In your J2EE module, you just need to declare a dependency on
it. 
        
        <module
xmlns="http://geronimo.apache.org/xml/ns/deployment-1.1";>
          <environment>
            <moduleId>
                <groupId>geronimo</groupId> 
                <artifactId>MailSession</artifactId>
                <version>1.0</version>
            </moduleId>
            <dependencies>
              <dependency>
                <groupId>geronimo</groupId> 
                <artifactId>javamail</artifactId>
              </dependency>
              <dependency>
                <groupId>geronimo</groupId>
                <artifactId>geronimo-mail</artifactId> 
                <type>jar</type>
              </dependency>
              <dependency>
                <groupId>geronimo</groupId>
                <artifactId>geronimo-javamail-transport</artifactId> 
                <type>jar</type>
              </dependency>
            </dependencies>
          </environment>
        
          <gbean name="MailSession"
class="org.apache.geronimo.mail.MailGBean"> 
            <attribute name="transportProtocol">smtp</attribute>
            <attribute name="useDefault">false</attribute>
            <attribute name="host">mailserver</attribute> 
            <attribute name="properties">
              mail.debug=false
              mail.smtp.port=25
            </attribute>
          </gbean>
        </module>
        
        On 11/27/06, David Carew < [EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> > wrote:
        > Take a look at the WAS CE samples (you can download them from
the same
        
        > place you downloaded WAS CE). There's an application called
        > PlantsByWebsphere that uses a mail session and has all the
required 
        info in the deployment plan .
        > I've tried it before  and it has worked for me. HTH
        >
        >
        > On 11/27/06, Mike Perham <[EMAIL PROTECTED]> wrote:
        > > I've spent the last few days trying to figure out how to
create an 
        > > system-wide javamail Session for application email usage.
        > >
        > > I updated the javamail module in config.xml to point to my
SMTP
        > > server but can't find any documentation on how to create a
session 
        > > based on that config.  If someone has a working mail
session, could
        > > you reply with your plan?  I'm using WAS CE 1.1.0.1.
        > >
        > > mike
        > >
        >
        >
        


Reply via email to