You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-user@portals.apache.org by ch...@polytech.unice.fr on 2006/09/14 21:12:34 UTC
Portal deployment in Tomcat
Hi,
I'm wondering if it's possible to build a WAR from a custom portal, inside
which there is a context.xml for describing DB connections.
Because my co-workers, who worked with J1, told me they could deploy their
resulting WAR using Tomcat Manager's 2nd option for deployment (with only
1 file to provide - a WAR). AFAIK, they were using some sort of "torque"
file properties...
This is what I'm trying to achieve as well, so that we need not to pass 2
files from dev servers to prod ones, but only 1 instead.
For information, I'm using j2:portal.genapp, which in the end produces
/target/myportal.war and /target/portal-conf/tomcat/context.xml
Thanks,
Ludovic
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org
Re: Portal deployment in Tomcat
Posted by ch...@polytech.unice.fr.
>
> consider yourself fortunate that you are not using Torque :)
> If you don't want to use the default method of connecting to a database
> (via the application server and jndi) simply override your spring
> configuration's datasource.xml, for example:
>
> <bean id="JetspeedDS" class="org.apache.commons.dbcp.BasicDataSource"
> destroy-method="close"
> >
> <property
> name="driverClassName"><value>com.mysql.jdbc.Driver</value></property>
> <property
> name="url"><value>jdbc:mysql://localhost/j2</value></property>
> <property name="username"><value>j2</value></property>
> <property name="password"><value>xxx</value></property>
> </bean>
>
I am trying your suggestion, however :
- if I keep the "class=..." you've pointed out, jetspeed fail to start
- if I take the
"class=org.apache.jetspeed.components.rdbms.ojb.ConnectionRepositoryEntry"
(comes from default one), jetspeed starts but can't display any of my
portlet-app that were inside its /WEB-INF/deploy... even if they have been
deployed. Here's the content of each portlet istead :
>> Failed to find Servlet context for Portlet Application: /rss
It looks like there's only 1 thing missing, I just don't know what...
Ludovic
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org
Re: Portal deployment in Tomcat
Posted by David Sean Taylor <da...@bluesunrise.com>.
chungue@polytech.unice.fr wrote:
> Hi,
>
> I'm wondering if it's possible to build a WAR from a custom portal, inside
> which there is a context.xml for describing DB connections.
> Because my co-workers, who worked with J1, told me they could deploy their
> resulting WAR using Tomcat Manager's 2nd option for deployment (with only
> 1 file to provide - a WAR). AFAIK, they were using some sort of "torque"
> file properties...
consider yourself fortunate that you are not using Torque :)
If you don't want to use the default method of connecting to a database
(via the application server and jndi) simply override your spring
configuration's datasource.xml, for example:
<bean id="JetspeedDS" class="org.apache.commons.dbcp.BasicDataSource"
destroy-method="close"
>
<property
name="driverClassName"><value>com.mysql.jdbc.Driver</value></property>
<property
name="url"><value>jdbc:mysql://localhost/j2</value></property>
<property name="username"><value>j2</value></property>
<property name="password"><value>xxx</value></property>
</bean>
>
> This is what I'm trying to achieve as well, so that we need not to pass 2
> files from dev servers to prod ones, but only 1 instead.
>
> For information, I'm using j2:portal.genapp, which in the end produces
> /target/myportal.war and /target/portal-conf/tomcat/context.xml
>
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-user-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-user-help@portals.apache.org