3 Replies Latest reply on May 13, 2017 8:21 AM by Jagadeesh J

    jQuery.atmosphere is undefined in jquery-atmosphere.js.jsf 2620

    prashant sindhu Newbie

      I am implementing a4j:push in my application. I am getting jQuery.atmosphere is undefined in jquery-atmosphere.js.jsf 2620 in my browser console and so a4j:push is not able to render the desired data. Please give any suggestion.

      Environment - Rich faces version - 4.3.7

      server - tomcat 7

      java -1.6

       

      my project dont have maven so i am manually adding following dependencies --

      atmosphere-annotations-1.0.18.jar
      atmosphere-compat-jbossweb-1.0.18.ja

      r atmosphere-compat-tomcat-1.0.18.jar

      atmosphere-compat-tomcat7-1.0.18.jar

      atmosphere-jersey-1.0.18.jar

      atmosphere-runtime-1.0.18.jar

      slf4j-api-1.6.1.jar

      logback-classic-1.0.10.jar

      logback-core-1.0.10.jar

       

      browser error console -

      browser-errorConsole.PNG

       

      xhtml code --

      <a4j:push id="ajaxPush11" address="chat" enabled="true">
        
      <a4j:ajax event="dataavailable"
        
      render="alarmTablePanel,alarmBrowserMainMessage" />
        
      </a4j:push>


      web.xml --

      <servlet>

              <servlet-name>Push Servlet</servlet-name>

              <servlet-class>org.richfaces.webapp.PushServlet</servlet-class>

              <load-on-startup>1</load-on-startup>

              <async-supported>true</async-supported>

          </servlet>


      <servlet-mapping>

              <servlet-name>Push Servlet</servlet-name>

              <url-pattern>/__richfaces_push</url-pattern>

          </servlet-mapping>

       

      <context-param>

              <param-name>org.richfaces.push.handlerMapping</param-name>

              <param-value>/__richfaces_push</param-value>

          </context-param>

       

      bean code --

      private static TopicKey topicKey = new TopicKey("chat");

      TopicsContext topicsContext = TopicsContext.lookup();

                  topicsContext.getOrCreateTopic(topicKey);

                  try {

                      topicsContext.publish(topicKey, "message");

                  } catch (MessageException e) {

                      // TODO Auto-generated catch block

                      e.printStackTrace();

                  }