summaryrefslogtreecommitdiffstats
path: root/archiva-webapp
diff options
context:
space:
mode:
authorBrett Porter <brett@apache.org>2006-09-20 09:19:35 +0000
committerBrett Porter <brett@apache.org>2006-09-20 09:19:35 +0000
commit3a9ddca3d70e3af53b16f3a9f793f6fafd68eb16 (patch)
tree07edfe211ef54f500cc0ea05ce6c247ac3050000 /archiva-webapp
parent184b4bed374415158dc6c16dc1cfbeaba5b78b4d (diff)
downloadarchiva-3a9ddca3d70e3af53b16f3a9f793f6fafd68eb16.tar.gz
archiva-3a9ddca3d70e3af53b16f3a9f793f6fafd68eb16.zip
use data source instead
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@448135 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'archiva-webapp')
-rw-r--r--archiva-webapp/pom.xml1
-rw-r--r--archiva-webapp/src/jetty-env.xml26
-rw-r--r--archiva-webapp/src/main/resources/META-INF/plexus/application.xml14
3 files changed, 41 insertions, 0 deletions
diff --git a/archiva-webapp/pom.xml b/archiva-webapp/pom.xml
index 98bd725de..515df07eb 100644
--- a/archiva-webapp/pom.xml
+++ b/archiva-webapp/pom.xml
@@ -280,6 +280,7 @@
<configuration>
<scanIntervalSeconds>10</scanIntervalSeconds>
<contextPath>/</contextPath>
+ <jettyEnvXml>src/jetty-env.xml</jettyEnvXml>
<connectors>
<connector implementation="org.mortbay.jetty.nio.SelectChannelConnector">
<port>9000</port>
diff --git a/archiva-webapp/src/jetty-env.xml b/archiva-webapp/src/jetty-env.xml
new file mode 100644
index 000000000..91e2f9a17
--- /dev/null
+++ b/archiva-webapp/src/jetty-env.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+<!DOCTYPE Configure PUBLIC "-//Mort Bay Consulting//DTD Configure//EN" "http://jetty.mortbay.org/configure.dtd">
+
+<Configure class="org.mortbay.jetty.webapp.WebAppContext">
+
+<New id="users" class="org.mortbay.jetty.plus.naming.Resource">
+ <Arg>jdbc/users</Arg>
+ <Arg>
+ <New class="org.apache.derby.jdbc.EmbeddedDataSource">
+ <Set name="DatabaseName">target/database</Set>
+ <Set name="createDatabase">create</Set>
+ </New>
+ </Arg>
+</New>
+<New id="shutdown" class="org.mortbay.jetty.plus.naming.Resource">
+ <Arg>jdbc/shutdown</Arg>
+ <Arg>
+ <New class="org.apache.derby.jdbc.EmbeddedDataSource">
+ <Set name="DatabaseName">target/database</Set>
+ <Set name="shutdownDatabase">shutdown</Set>
+ </New>
+ </Arg>
+</New>
+
+</Configure>
+
diff --git a/archiva-webapp/src/main/resources/META-INF/plexus/application.xml b/archiva-webapp/src/main/resources/META-INF/plexus/application.xml
index afadbcaa1..ad2f05403 100644
--- a/archiva-webapp/src/main/resources/META-INF/plexus/application.xml
+++ b/archiva-webapp/src/main/resources/META-INF/plexus/application.xml
@@ -74,6 +74,12 @@
<hierarchy>JPOX</hierarchy>
<level>WARN</level>
</level>
+<!--
+ <level>
+ <hierarchy>JPOX.RDBMS.SQL</hierarchy>
+ <level>DEBUG</level>
+ </level>
+-->
<level>
<hierarchy>freemarker</hierarchy>
<level>WARN</level>
@@ -123,9 +129,15 @@
<component>
<role>org.codehaus.plexus.jdo.JdoFactory</role>
+<!--
<implementation>org.codehaus.plexus.jdo.DefaultConfigurableJdoFactory</implementation>
+-->
+ <implementation>org.codehaus.plexus.jdo.DataSourceConfigurableJdoFactory</implementation>
<configuration>
+ <connectionFactoryName>java:comp/env/jdbc/users</connectionFactoryName>
+ <shutdownConnectionFactoryName>java:comp/env/jdbc/shutdown</shutdownConnectionFactoryName>
+
<!-- HSQLDB Configuration -->
<!--
NOTE: NO NOT USE THIS CONFIGURATION FOR A PRODUCTION SYSTEM.
@@ -142,10 +154,12 @@
-->
<!-- Apache Derby Configuration -->
+<!--
<driverName>org.apache.derby.jdbc.EmbeddedDriver</driverName>
<url>jdbc:derby:${plexus.home}/database;create=true</url>
<userName>sa</userName>
<password></password>
+-->
<!-- Postgresql Configuration -->
<!--