[ 
https://issues.jboss.org/browse/RF-13592?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12959205#comment-12959205
 ] 

Igor Bolshakov edited comment on RF-13592 at 4/4/14 5:42 AM:
-------------------------------------------------------------

Please, use test application maven project. We don't use portlets anymore. This 
is only old context parameter we forgot to clean up. Anyway we built sample 
application and we deployed it under Tomcat Version 8.0.5 and Tomcat Version 
7.0.52. Bug is reproduced on both J2EE containers. To test just build WAR and 
deploy it. Open in browser url http://localhost:8080/sample/pages/push.xhtml. 
Below is result of "mvn -v" command on my local machine:
{quote}Apache Maven 3.0.5 (r01de14724cdef164cd33c7c8c2fe155faf9602da; 
2013-02-19 14:51:28+0100)
Maven home: B:\tools\maven
Java version: 1.7.0_45, vendor: Oracle Corporation
Java home: B:\tools\jdk\jre
Default locale: de_DE, platform encoding: UTF-8
OS name: "windows 7", version: "6.1", arch: "amd64", family: "windows"{quote}
                
      was (Author: igor_ab):
    Test application project
                  
> a4j:push doesn't work after rendering
> -------------------------------------
>
>                 Key: RF-13592
>                 URL: https://issues.jboss.org/browse/RF-13592
>             Project: RichFaces
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: component-push/poll
>    Affects Versions: 4.3.5
>         Environment: JBoss EAP 6.2
> Browser: Chrome 33.0.1750.154 and IE 8.0.7601.17514
> JSF 2.19, Richfaces 4.3.5
>            Reporter: Igor Bolshakov
>            Assignee: Pavol Pitonak
>            Priority: Critical
>              Labels: waiting_on_user
>         Attachments: a4j.log, localhost.har, push-test.zip, push-test.zip, 
> screenshot.png, web.xml
>
>
> I use {{rendered}} attribute to start/stop a4j:push component in example 
> below. After rendering of a4j:push element the handling of incoming push 
> messages is broken. In my simple example I set alert to notify about recieved 
> message (see attached screenshot).
> View xhtml code:
> {code:xml}<?xml version="1.0" encoding="ISO-8859-1"?>
> <ui:composition xmlns="http://www.w3.org/1999/xhtml";
>     xmlns:a4j="http://richfaces.org/a4j";
>     xmlns:h="http://java.sun.com/jsf/html";
>     xmlns:ui="http://java.sun.com/jsf/facelets";>
>     <h:form>
>         <a4j:outputPanel id="push-panel">
>             <a4j:push address="TEST_ADDRESS" 
> ondataavailable="alert('event.rf.data=' + event.rf.data)"
>                 rendered="#{testBean.enabled}"/>
>         </a4j:outputPanel>
>         <a4j:commandButton id="startBtn" value="Start Push" 
> action="#{testBean.startPush}" render="push-panel"/>
>         <a4j:commandButton id="stopBtn" value="Stop Push" 
> action="#{testBean.stopPush}" render="push-panel"/>
>         <a4j:commandButton id="sendMessage" value="Send Message" 
> action="#{testBean.sendMessage}"/>
>     </h:form>
> </ui:composition>{code}
> Backing bean class:
> {code}public class TestBean {
>     private boolean enabled = false;
>     public boolean isEnabled() {
>         return enabled;
>     }
>     public void startPush() {
>         enabled = true;
>     }
>     public void stopPush() {
>         enabled = false;
>     }
>     public void sendMessage() throws MessageException {
>         TopicsContext.lookup().publish(new TopicKey("TEST_ADDRESS"), "Hello 
> World");
>     }
> }{code}
> Configuration in web.xml (see attachment).
> Scenario:
> 1) Open page
> 2) Click "Start Push" button
> 3) Click "Send Message" button 
> 4) Alert "event.rf.data=Hello World" is shown (see attached screenshot)
> 5) Click "Stop Push" button
> 6) Polling is closed (see localhost.har in attachment)
> 7) Click "Start Push" button
> 8) Polling is started (see localhost.har in attachment)
> 9) Click "Send Message" button
> 10) Message is recieved (see localhost.har in attachment)
> 11) No alert, no javascript error
> For more details I saved a4j:log output in a4j.log file.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
_______________________________________________
richfaces-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/richfaces-issues

Reply via email to