For c), we also need to update the domain.xml template as we have the
following now:
<availability-service>
<web-container-availability availability-enabled="true"
persistence-frequency="web-method" persistence-scope="session"
persistence-type="replicated" sso-failover-enabled="false"/>
<ejb-container-availability availability-enabled="true"
sfsb-store-pool-name="jdbc/hastore"/>
<jms-availability availability-enabled="false"/>
</availability-service>
So, it seems that they choose the availability-enabled to different
value at that time.
In this case, I may remove the availability-enabled from domain.xml
template and let pick up the default from config-api.
Please let me know if there is any further comments.
Btw, please cc me in the reply as I am not in the email alias.
Thanks.
Shing Wai Chan
>
>
> -------- Original Message --------
> Subject: Re: A question on getAvailabilityServiceEnabled()
> Date: Thu, 14 Jul 2011 02:43:26 -0700
> From: Jerome Dochez <jerome.dochez_at_oracle.com>
> Reply-To: admin_at_glassfish.java.net
> To: admin_at_glassfish.java.net
> CC: Mahesh.Kannan_at_Oracle.Com Kannan <Mahesh.Kannan_at_oracle.com>
>
>
>
> I think c) is probably the least risky.
>
> Do we know why we have all those different availability settings ? It's not like we can have web container in HA mode and ejb container not, correct ?
>
> Mahesh, any feedback ?
>
> jerome
> On Jul 13, 2011, at 5:42 PM, Shing Wai Chan wrote:
>
> > While investigatinghttp://java.net/jira/browse/GLASSFISH-17041
> > I notice that serverConfigLookup.getWebContainerAvailabilityEnabledFromConfig() = true
> > out of the box. In other words, we are using HA by default. I don't think this is the desirable behavior.
> >
> > While investigating, I find the following:
> > 1. In domain.xml, we have
> > <availability-service>
> > <web-container-availability></web-container-availability>
> > <ejb-container-availability sfsb-store-pool-name="jdbc/hastore"></ejb-container-availability>
> > <jms-availability></jms-availability>
> > </availability-service>
> >
> > 2. In admin/config-api:
> > For AvailabilityService, WebContainerAvailability, EjbContainerAvailability, getAvailabilityEnabled()
> > has a "true" as default.
> > Note that JmsAvailability.getAvailabilityEnabled() has a "false" as default.
> >
> > There are several possibilities to resolve this issue:
> > a) remove the<availability-service> in the domain.xml
> > I do not know whether there is any side effect in admin / admin console side
> >
> > b) add availability-enabled="false" to availability-service, web-container-availability, ejb-container-availability
> > At least, we have to add it to web-container-availability and ejb-container-availability.
> >
> > c) change the default value of getAvailabilityServiceEnabled() in AvailabilityService, WebContainerAvailability, EjbContainerAvailability of config-api.
> >
> > Any comment?
>