We got this running on Windows here out of the Program Files
directory, both putting the source code and tomcat installation under /
Program Files/jetexpress/jetexpress and /Program Files/jetexpress/
tomcat6 respectively. So I want to make it clear: IT IS POSSIBLE TO
BUILD AND RUN JETSPEED ON WINDOWS UNDER PROGRAM FILES. That said, I
don't recommend it, as I know there are some old issues associated
with doing this, not to mention the frequent emails to this list from
newbies trying to install it there and not being familiar with Java
development.
Lets re-review your email and see if I can identify the issues....
On Sep 14, 2009, at 2:49 AM, Varsha NRao (HCL Financial Services) wrote:
Hello ,
I have deployed Jetspeed 2 Tomcat-6.0.20 using the following maven
commands
mvn org.apache.maven.plugins:maven-archetype-plugin:2.0-
alpha-4:generate -DarchetypeGroupId=org.apache.portals.jetspeed-2 -
DarchetypeArtifactId=jetspeed-archetype -DarchetypeVersion=2.2.0 -
DartifactId=jetexpress -Dpackage=org.apache.portals.tutorials -
DgroupId=org.apache.portals.tutorials -Dversion=1.0-SNAPSHOT
I changed the jetspeed-mvn-settings.xml file as per the instructions
in the tutorials and I ran the following command to build and deploy
in tomcat
The jetspeed-mvn-settings.xml instructs you to put your database in /
tmp, however according to your jetexpress.xml below, you put it under
D:\Program Files\Apache Software Foundation\Tomcat 6.0\database\derby
\productiondb, so something doesn't add up
mvn jetspeed:mvn -Dtarget=all
I am able to launch the jetexpress portal from tomcat.
I moved the jars required for login into the lib folder . And I add
the JAAS realm in sever.xml as follows :
Not necessary. The build moves all the jars around for you. Recommend
starting with a clean Tomcat as it sounds like some jar is now in the
wrong place
<Realm className="org.apache.catalina.realm.JAASRealm"
appName="Jetspeed"
userClassNames="org.apache.jetspeed.security.impl.UserPrincipalImpl"
roleClassNames="org.apache.jetspeed.security.impl.RolePrincipalImpl"
useContextClassLoader="true"
debug="5"/>
Again, not necessary to do. Don't edit the server.xml. The build will
create a custom server xml file for the jetexpress webapp.
My jetspeed.xml located under conf\Catalina\localhost is as follows:
<Context crossContext="true">
<Realm className="org.apache.catalina.realm.JAASRealm"
appName="Jetspeed"
userClassNames
=
"org
.apache
.jetspeed
.security
.impl
.UserImpl
,org
.apache
.jetspeed
.security
.impl
.TransientUser,org.apache.jetspeed.security.UserSubjectPrincipalImpl"
roleClassNames
=
"org
.apache
.jetspeed
.security
.impl.RoleImpl,org.apache.jetspeed.security.impl.TransientRole"
useContextClassLoader="true"
debug="0"/>
<Resource name="jdbc/jetspeed" auth="Container"
factory="org.apache.commons.dbcp.BasicDataSourceFactory"
type="javax.sql.DataSource" username="" password=""
driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
url="jdbc:derby:D:\Program Files\Apache Software Foundation\Tomcat
6.0\database\derby\productiondb;create=true"
maxActive="100" maxIdle="30" maxWait="10000"/>
There is the problem -- I missed it the first time.
You cannot have single back slashes in Java -- This is probably one
of the oldest problems for Java newbies on Windows when running the
Jetspeed build.
Key:
This is a forward slash: /
This is a back slash: \
Try
driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
url="jdbc:derby:/Program Files/Apache Software Foundation/Tomcat 6.0/
database/derby/productiondb;create=true"
or
driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
url="jdbc:derby:D:/Program Files/Apache Software Foundation/Tomcat 6.0/
database/derby/productiondb;create=true"
or
driverClassName="org.apache.derby.jdbc.EmbeddedDriver"
url="jdbc:derby:D:\\Program Files\\Apache Software Foundation\\Tomcat
6.0\\database\\derby\\productiondb;create=true"
Make sure to set ALL your jetspeed-mvn-settings.xml without the single
backslashes including the <org.apache.jetspeed.server.home> setting
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]