1. download guava module from google web site.
    then place it in 010.jal-mobile-dev\ws\moto_web_app\WEB-INF\lib directory.
    

1.1 download atomsphere library and put them in the web-inf/lib directory.
atmosphere-compat-jbossweb-1.0.17.jar
atmosphere-runtime-1.0.17.jar
atmosphere-compat-tomcat-1.0.17.jar
atmosphere-compat-tomcat7-1.0.17.jar


2. css/parse module dependency setting
   create jboss-deployment-structure.xml in the 010.jal-mobile-dev\ws\moto_web_app\WEB-INF\lib directory as follows


-----------
<?xml version="1.0" encoding="UTF-8"?>  
<jboss-deployment-structure>  
    <deployment>  
         <dependencies>  
              <module name="org.w3c.css.sac" />  
              <module name="net.sourceforge.cssparser" />  
        </dependencies>  
    </deployment>  
</jboss-deployment-structure>


3. enable jms in WEB-INF/web.xml

-----------
<?xml version='1.0' encoding='UTF-8'?>  
  
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"  
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"  
    version="3.0">  
    ^^^^^^^^^^^^^^
:
:
:
:
  <!-- enable richfaces push/jms -->
    <context-param>
        <param-name>org.richfaces.push.initializeOnStartup</param-name>
        <param-value>true</param-value>
    </context-param>
    <context-param>
        <param-name>org.richfaces.push.jms.disabled</param-name>
        <param-value>true</param-value>
    </context-param>
    <context-param> 
        <param-name>org.richfaces.push.jms.connectionUsername</param-name> 
        <param-value>jmsuser</param-value>
    </context-param>  
    <context-param> 
        <param-name>org.richfaces.push.jms.connectionPassword</param-name> 
        <param-value>jmspassword</param-value> 
    </context-param>  
:
:
:
:



!!!!!! ========== 4.1 nor 4.2 NOT required????? ===========
4.1 topic initialization
Add topic initializer class in the project and WEB-INF/faces-config.xml as follows.

------------
<?xml version="1.0"?>  
<faces-config version="2.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xi="http://www.w3.org/2001/XInclude"  
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-facesconfig_2_0.xsd">  
  
    <application>  
        <system-event-listener>  
            <system-event-listener-class>motoSample.TopicsInitializer</system-event-listener-class>  
            <system-event-class>javax.faces.event.PostConstructApplicationEvent</system-event-class>  
        </system-event-listener>  
    </application>  
  
  
</faces-config>  


4.2 jms topic add

# jms-topic add --topic-address=motoTestTopic --entries=topic/motoTest,java:jboss/exported/jms/topic/motoTest

# cd /subsystem=messaging/hornetq-server=default/jms-queue=testQueue
# jms-topic remove --topic-address=motoTestTopic



