Author: chirino
Date: Wed Oct 20 18:32:56 2010
New Revision: 1025664
URL: http://svn.apache.org/viewvc?rev=1025664&view=rev
Log:
Updated to the latest scalate version.
Removed:
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/errors/500.scaml
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/css/scalate/errors.css
Modified:
activemq/activemq-apollo/trunk/apollo-cassandra/pom.xml
activemq/activemq-apollo/trunk/apollo-web/pom.xml
activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/ServletContextListener.scala
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/layouts/default.scaml
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/web.xml
activemq/activemq-apollo/trunk/pom.xml (contents, props changed)
Modified: activemq/activemq-apollo/trunk/apollo-cassandra/pom.xml
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-cassandra/pom.xml?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-cassandra/pom.xml (original)
+++ activemq/activemq-apollo/trunk/apollo-cassandra/pom.xml Wed Oct 20 18:32:56
2010
@@ -102,6 +102,25 @@
<scope>test</scope>
<version>${junit-version}</version>
</dependency>
+
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-api</artifactId>
+ <version>${slf4j-version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>slf4j-log4j12</artifactId>
+ <version>${slf4j-version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.slf4j</groupId>
+ <artifactId>jcl-over-slf4j</artifactId>
+ <version>${slf4j-version}</version>
+ <scope>test</scope>
+ </dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
Modified: activemq/activemq-apollo/trunk/apollo-web/pom.xml
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/pom.xml?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-web/pom.xml (original)
+++ activemq/activemq-apollo/trunk/apollo-web/pom.xml Wed Oct 20 18:32:56 2010
@@ -80,14 +80,19 @@
<!-- Web Framework APIs -->
<dependency>
<groupId>org.fusesource.scalate</groupId>
- <artifactId>scalate-war</artifactId>
+ <artifactId>scalate-core</artifactId>
<version>${scalate-version}</version>
- <type>war</type>
</dependency>
- <dependency>
- <groupId>org.fusesource.scalate</groupId>
- <artifactId>scalate-guice</artifactId>
- <version>${scalate-version}</version>
+ <!--<dependency>-->
+ <!--<groupId>org.fusesource.scalate</groupId>-->
+ <!--<artifactId>scalate-war</artifactId>-->
+ <!--<version>${scalate-version}</version>-->
+ <!--<type>war</type>-->
+ <!--</dependency>-->
+ <dependency>
+ <groupId>com.sun.jersey</groupId>
+ <artifactId>jersey-server</artifactId>
+ <version>${jersey-version}</version>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
Modified:
activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/ServletContextListener.scala
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/ServletContextListener.scala?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
---
activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/ServletContextListener.scala
(original)
+++
activemq/activemq-apollo/trunk/apollo-web/src/main/scala/org/apache/activemq/apollo/web/ServletContextListener.scala
Wed Oct 20 18:32:56 2010
@@ -16,27 +16,23 @@
*/
package org.apache.activemq.apollo.web
-import com.google.inject.servlet.GuiceServletContextListener
-import org.fusesource.scalate.guice.ScalateModule
-import javax.servlet.ServletContextEvent
import java.io.File
-import com.google.inject.{Provides, Guice, Singleton}
import org.apache.activemq.apollo.broker.{BrokerRegistry, Broker}
import org.apache.activemq.apollo.util._
+import javax.servlet.{ServletContextListener, ServletContextEvent}
/**
- * A servlet context listener which registers
- * <a href="http://code.google.com/p/google-guice/wiki/Servlets">Guice
Servlet</a>
+ * A servlet context listener which handles starting the
+ * broker instance.
*
* @version $Revision : 1.1 $
*/
-class ServletContextListener extends GuiceServletContextListener {
+class ApolloListener extends ServletContextListener {
var configStore:ConfigStore = null
- override def contextInitialized(servletContextEvent: ServletContextEvent) = {
-
+ def contextInitialized(sce: ServletContextEvent) = {
try {
configStore = createConfigStore
ConfigStore() = configStore
@@ -64,13 +60,9 @@ class ServletContextListener extends Gui
case e:Exception =>
e.printStackTrace
}
-
- super.contextInitialized(servletContextEvent);
}
- override def contextDestroyed(servletContextEvent: ServletContextEvent) = {
- super.contextDestroyed(servletContextEvent);
-
+ def contextDestroyed(sce: ServletContextEvent) = {
val tracker = new LoggingTracker("webapp shutdown")
configStore.foreachBroker(false) { config=>
// remove started brokers what we configured..
@@ -84,21 +76,6 @@ class ServletContextListener extends Gui
configStore = null
}
- def getInjector = Guice.createInjector(new ScalateModule() {
-
- @Singleton
- @Provides
- def provideConfigStore:ConfigStore = configStore
-
- // lets add any package names which contain JAXRS resources
- // https://jersey.dev.java.net/issues/show_bug.cgi?id=485
- override def resourcePackageNames =
- "org.apache.activemq.apollo.web.resources" ::
- "org.codehaus.jackson.jaxrs" ::
- super.resourcePackageNames
- })
-
-
def createConfigStore():ConfigStore = {
val store = new FileConfigStore
store.file = new File("activemq.xml")
Modified:
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/layouts/default.scaml
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/layouts/default.scaml?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
---
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/layouts/default.scaml
(original)
+++
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/scalate/layouts/default.scaml
Wed Oct 20 18:32:56 2010
@@ -35,10 +35,10 @@
.wrapper
%ul
%li
- - if (requestURI.startsWith("/index."))
- %span Home
- - else
- %a(href={uri("/index.scaml")}) Home
+ -# - if (requestURI.startsWith("/index."))
+ -# %span Home
+ -# - else
+ %a(href={uri("/index.scaml")}) Home
#content
.wrapper
Modified:
activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/web.xml
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/web.xml?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/web.xml
(original)
+++ activemq/activemq-apollo/trunk/apollo-web/src/main/webapp/WEB-INF/web.xml
Wed Oct 20 18:32:56 2010
@@ -23,30 +23,67 @@
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
version="2.5">
- <display-name>Bookstore</display-name>
+ <display-name>Apollo</display-name>
<description>
- Bookstore Sample
+ The Apollo web application
</description>
<listener>
-
<listener-class>org.apache.activemq.apollo.web.ServletContextListener</listener-class>
+
<listener-class>org.apache.activemq.apollo.web.ApolloListener</listener-class>
</listener>
<filter>
- <filter-name>guiceFilter</filter-name>
- <filter-class>com.google.inject.servlet.GuiceFilter</filter-class>
+ <filter-name>Jersey Filter</filter-name>
+
<filter-class>com.sun.jersey.spi.container.servlet.ServletContainer</filter-class>
+ <init-param>
+ <param-name>com.sun.jersey.config.feature.Trace</param-name>
+ <param-value>false</param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.config.feature.Redirect</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.config.feature.ImplicitViewables</param-name>
+ <param-value>true</param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.config.property.packages</param-name>
+ <param-value>
+ org.codehaus.jackson.jaxrs;
+ org.fusesource.scalate.console;
+ org.apache.activemq.apollo.web.resources
+ </param-value>
+ </init-param>
+ <init-param>
+ <param-name>com.sun.jersey.config.feature.FilterForwardOn404</param-name>
+ <param-value>true</param-value>
+ </init-param>
</filter>
<filter-mapping>
- <filter-name>guiceFilter</filter-name>
+ <filter-name>Jersey Filter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
+ <filter>
+ <filter-name>TemplateEngineFilter</filter-name>
+
<filter-class>org.fusesource.scalate.servlet.TemplateEngineFilter</filter-class>
+ </filter>
+ <filter-mapping>
+ <filter-name>TemplateEngineFilter</filter-name>
+ <url-pattern>/*</url-pattern>
+ </filter-mapping>
+
+ <welcome-file-list>
+ <welcome-file>index</welcome-file>
+ </welcome-file-list>
+
<error-page>
<error-code>500</error-code>
<location>/WEB-INF/scalate/errors/500.scaml</location>
</error-page>
-
+
</web-app>
Modified: activemq/activemq-apollo/trunk/pom.xml
URL:
http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/pom.xml?rev=1025664&r1=1025663&r2=1025664&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/pom.xml (original)
+++ activemq/activemq-apollo/trunk/pom.xml Wed Oct 20 18:32:56 2010
@@ -84,7 +84,7 @@
<regexp-version>1.3</regexp-version>
<rome-version>0.8</rome-version>
- <slf4j-version>1.5.0</slf4j-version>
+ <slf4j-version>1.6.0</slf4j-version>
<jaxb-api-version>2.1</jaxb-api-version>
<jaxb-version>2.1.6</jaxb-version>
@@ -106,10 +106,11 @@
<bdb-version>4.0.103</bdb-version>
<jetty-version>6.1.22</jetty-version>
- <scalate-version>1.2</scalate-version>
+ <scalate-version>1.4-SNAPSHOT</scalate-version>
<servlet-api-version>2.5</servlet-api-version>
<jackson-version>1.5.2</jackson-version>
- <logback-version>0.9.18</logback-version>
+ <logback-version>0.9.24</logback-version>
+ <jersey-version>1.5-ea01</jersey-version>
<!-- maven plugin versions -->
<maven-scala-plugin-version>2.14</maven-scala-plugin-version>
@@ -569,7 +570,7 @@
<plugin>
<groupId>org.fusesource.mvnplugins</groupId>
<artifactId>maven-graph-plugin</artifactId>
- <version>1.7</version>
+ <version>1.11</version>
</plugin>
</plugins>
</build>
Propchange: activemq/activemq-apollo/trunk/pom.xml
('svn:executable' removed)