Author: nbelaevski
Date: 2010-11-01 19:49:06 -0400 (Mon, 01 Nov 2010)
New Revision: 19871
Added:
branches/RF-7817/examples/push-demo/
branches/RF-7817/examples/push-demo/pom.xml
branches/RF-7817/examples/push-demo/src/
Modified:
branches/RF-7817/examples/pom.xml
branches/RF-7817/examples/push-demo/src/main/java/demo/TopicsInitializer.java
branches/RF-7817/examples/push-demo/src/main/webapp/chat.xhtml
Log:
https://jira.jboss.org/browse/RF-9158
Modified: branches/RF-7817/examples/pom.xml
===================================================================
--- branches/RF-7817/examples/pom.xml 2010-11-01 23:47:24 UTC (rev 19870)
+++ branches/RF-7817/examples/pom.xml 2010-11-01 23:49:06 UTC (rev 19871)
@@ -46,6 +46,7 @@
<module>input-demo</module>
<module>repeater-demo</module>
<module>iteration-demo</module>
+ <module>push-demo</module>
<module>richfaces-showcase</module>
<!--<module>dist</module>-->
</modules>
Added: branches/RF-7817/examples/push-demo/pom.xml
===================================================================
--- branches/RF-7817/examples/push-demo/pom.xml (rev 0)
+++ branches/RF-7817/examples/push-demo/pom.xml 2010-11-01 23:49:06 UTC (rev 19871)
@@ -0,0 +1,203 @@
+<?xml version="1.0" encoding="UTF-8"?>
+ <!--
+ JBoss, Home of Professional Open Source Copyright 2010, Red Hat,
+ Inc. and individual contributors by the @authors tag. See the
+ copyright.txt in the distribution for a full listing of
+ individual contributors. This is free software; you can
+ redistribute it and/or modify it under the terms of the GNU
+ Lesser General Public License as published by the Free Software
+ Foundation; either version 2.1 of the License, or (at your
+ option) any later version. This software is distributed in the
+ hope that it will be useful, but WITHOUT ANY WARRANTY; without
+ even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+ PARTICULAR PURPOSE. See the GNU Lesser General Public License
+ for more details. You should have received a copy of the GNU
+ Lesser General Public License along with this software; if not,
+ write to the Free Software Foundation, Inc., 51 Franklin St,
+ Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF site:
+
http://www.fsf.org.
+ -->
+<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.richfaces.examples</groupId>
+ <artifactId>richfaces-example-parent</artifactId>
+ <version>4.0.0-SNAPSHOT</version>
+ <relativePath>../parent/pom.xml</relativePath>
+ </parent>
+
+ <groupId>org.richfaces.examples</groupId>
+ <artifactId>push-demo</artifactId>
+ <packaging>war</packaging>
+ <version>4.0.0-SNAPSHOT</version>
+ <name>RichFaces Examples: Push</name>
+
+ <properties>
+ <hornetq.version>2.1.2.Final</hornetq.version>
+ </properties>
+
+ <dependencyManagement>
+ <dependencies>
+ </dependencies>
+ </dependencyManagement>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.hornetq</groupId>
+ <artifactId>hornetq-core</artifactId>
+ <version>${hornetq.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.hornetq</groupId>
+ <artifactId>hornetq-jms</artifactId>
+ <version>${hornetq.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.hornetq</groupId>
+ <artifactId>hornetq-logging</artifactId>
+ <version>${hornetq.version}</version>
+ </dependency>
+ <!-- dependency>
+ <groupId>org.hornetq</groupId>
+ <artifactId>hornetq-transports</artifactId>
+ <version>2.1.0.r9031</version>
+ </dependency -->
+ <dependency>
+ <groupId>org.jboss.netty</groupId>
+ <artifactId>netty</artifactId>
+ <version>3.2.2.Final</version>
+ </dependency>
+ <dependency>
+ <groupId>javax.jms</groupId>
+ <artifactId>jms</artifactId>
+ <version>1.1</version>
+ </dependency>
+
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.7</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.atmosphere</groupId>
+ <artifactId>atmosphere-runtime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.faces</groupId>
+ <artifactId>jsf-impl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.core</groupId>
+ <artifactId>richfaces-core-impl</artifactId>
+ </dependency>
+
+
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>servlet-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet.jsp</groupId>
+ <artifactId>jsp-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.el</groupId>
+ <artifactId>el-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>jstl</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.richfaces.ui.core</groupId>
+ <artifactId>richfaces-ui-core-ui</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>net.sf.ehcache</groupId>
+ <artifactId>ehcache</artifactId>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <artifactId>maven-compiler-plugin</artifactId>
+ </plugin>
+ </plugins>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>jee6</id>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-war-plugin</artifactId>
+ <configuration>
+
<webappDirectory>${project.build.directory}/${project.build.finalName}-jee6</webappDirectory>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <dependencies>
+ <!-- TODO these should be switchable in example specific parent
-->
+ <dependency>
+ <groupId>com.sun.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>com.sun.faces</groupId>
+ <artifactId>jsf-impl</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>javax.transaction</groupId>
+ <artifactId>jta</artifactId>
+ <version>1.1</version>
+ <scope>provided</scope>
+ </dependency>
+ </dependencies>
+ </profile>
+ <profile>
+ <id>jetty</id>
+ <dependencies>
+ <dependency>
+ <groupId>org.eclipse.jetty</groupId>
+ <artifactId>jetty-websocket</artifactId>
+ <version>8.0.0.M1</version>
+ </dependency>
+ </dependencies>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.mortbay.jetty</groupId>
+ <artifactId>jetty-maven-plugin</artifactId>
+ <version>8.0.0.M1</version>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+
+ <scm>
+
<
connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/trunk/exam...
+
<
developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/trun...
+ <
url>http://fisheye.jboss.org/browse/richfaces</url>
+ </scm>
+</project>
Copied: branches/RF-7817/examples/push-demo/src (from rev 19862,
branches/RF-7817/push-redesign-app/src)
Modified: branches/RF-7817/examples/push-demo/src/main/java/demo/TopicsInitializer.java
===================================================================
---
branches/RF-7817/push-redesign-app/src/main/java/demo/TopicsInitializer.java 2010-11-01
19:50:05 UTC (rev 19862)
+++
branches/RF-7817/examples/push-demo/src/main/java/demo/TopicsInitializer.java 2010-11-01
23:49:06 UTC (rev 19871)
@@ -83,7 +83,7 @@
if (chatBean == null ||
"badname".equals(chatBean.getUserName())) {
throw new EventAbortedException("User name has not passed
validation");
}
- }
+ }
});
}
Modified: branches/RF-7817/examples/push-demo/src/main/webapp/chat.xhtml
===================================================================
--- branches/RF-7817/push-redesign-app/src/main/webapp/chat.xhtml 2010-11-01 19:50:05 UTC
(rev 19862)
+++ branches/RF-7817/examples/push-demo/src/main/webapp/chat.xhtml 2010-11-01 23:49:06 UTC
(rev 19871)
@@ -6,7 +6,7 @@
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:c="http://java.sun.com/jsp/jstl/core"
-
xmlns:p="http://richfaces.org/push-redesign">
+
xmlns:a4j="http://richfaces.org/a4j">
<f:view>
<f:metadata>
@@ -53,7 +53,7 @@
</h:selectBooleanCheckbox>
<h:panelGroup layout="block"
rendered="#{channel.rendered}">
- <p:push address="#{channelName}@chat"
onerror="alert(event.rf.data)" ondataavailable="jQuery('<div
/>').prependTo('.#{channelName}Output').text(event.rf.data)"
/>
+ <a4j:push address="#{channelName}@chat"
onerror="alert(event.rf.data)" ondataavailable="jQuery('<div
/>').prependTo('.#{channelName}Output').text(event.rf.data)"
/>
<h:inputText styleClass="messageInput"
value="#{chatBean.message}" size="40" />