从PF 4迁移到PF 5后停止工作,我得到了一个" No Broadcaster匹配......"错误。
首先我认为它与旧的推送API有些不兼容,但它也会出现在新的API中。
使用默认的氛围 - 运行时推送替换氛围 - 运行时 - 本机,但它不是解决方案,因为我在生产中遇到了一些问题。
使用PF 5.0.3 + Atmosphere 2.1.6 + Tomcat 7.0.52进行测试。
我是否需要一些额外的配置或依赖关系才能在PrimeFaces 5中使用 atmosphere-runtime-native ?
由于
服务器日志:(使用PrimeFaces展示的通知示例)
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Atmosphere is using org.atmosphere.cpr.DefaultAnnotationProcessor for processing annotation
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.DefaultAnnotationProcessor - AnnotationProcessor class org.atmosphere.cpr.DefaultAnnotationProcessor$BytecodeBasedAnnotationProcessor being used
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.DefaultAnnotationProcessor - Found Annotation in org.primefaces.push.impl.PushEndpointInterceptor being scanned: interface org.atmosphere.config.service.AtmosphereInterceptorService
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.DefaultAnnotationProcessor - Found Annotation in org.primefaces.push.impl.PushEndpointMapper being scanned: interface org.atmosphere.config.service.EndpointMapperService
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Auto detecting atmosphere handlers /WEB-INF/classes/
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Auto detecting WebSocketHandler in /WEB-INF/classes/
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Installed WebSocketProtocol org.atmosphere.websocket.protocol.SimpleHttpProtocol
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Installing Default AtmosphereInterceptor
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.CorsInterceptor : CORS Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.CacheHeadersInterceptor : Default Response's Headers Interceptor
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.PaddingAtmosphereInterceptor : Browser Padding Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.AndroidAtmosphereInterceptor : Android Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.HeartbeatInterceptor : Heartbeat Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.SSEAtmosphereInterceptor : SSE Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.JSONPAtmosphereInterceptor : JSONP Interceptor Support
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.JavaScriptProtocol : Atmosphere JavaScript Protocol
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.WebSocketMessageSuspendInterceptor : org.atmosphere.interceptor.WebSocketMessageSuspendInterceptor
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.OnDisconnectInterceptor : Browser disconnection detection
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - org.atmosphere.interceptor.IdleResourceInterceptor : org.atmosphere.interceptor.IdleResourceInterceptor
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Set org.atmosphere.cpr.AtmosphereInterceptor.disableDefaults to disable them.
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Using EndpointMapper class org.primefaces.push.impl.PushEndpointMapper
[http-nio-8080-exec-7] WARN org.atmosphere.cpr.AtmosphereFramework - No BroadcasterCache configured. Broadcasted message between client reconnection will be LOST. It is recommended to configure the org.atmosphere.cache.UUIDBroadcasterCache
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Default Broadcaster Class: org.atmosphere.cpr.DefaultBroadcaster
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Broadcaster Polling Wait Time 100
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Shared ExecutorService supported: true
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Messaging Thread Pool Size: Unlimited
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Async I/O Thread Pool Size: 200
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Using BroadcasterFactory: org.atmosphere.cpr.DefaultBroadcasterFactory
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Using WebSocketProcessor: org.atmosphere.websocket.DefaultWebSocketProcessor
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - HttpSession supported: false
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Atmosphere is using DefaultAtmosphereObjectFactory for dependency injection and object creation
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Atmosphere is using async support: org.atmosphere.container.Tomcat7AsyncSupportWithWebSocket running under container: Apache Tomcat/7.0.52
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Atmosphere Framework 2.1.6 started.
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework -
For Atmosphere Framework Commercial Support, visit
http://www.async-io.org/ or send an email to support@async-io.org
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereFramework - Installed AtmosphereInterceptor @PushEndpoint Interceptor with priority AFTER_DEFAULT
[http-nio-8080-exec-7] INFO org.atmosphere.cpr.AtmosphereServlet - AtmosphereServlet with native support for Tomcat 6/7 and JBossWeb Installed.
[Thread-9] INFO org.atmosphere.cpr.AtmosphereFramework - Latest version of Atmosphere's JavaScript Client 2.2.2
[http-nio-8080-exec-3] WARN org.atmosphere.cpr.MetaBroadcaster - No Broadcaster matches /notify. Message javax.faces.application.FacesMessage@1e64262c WILL BE LOST. Make sure you cache it or make sure the Broadcaster exists before.
答案 0 :(得分:0)
解决方案正在转向常规氛围 - 运行时。
此处有更多详情:https://code.google.com/p/primefaces/issues/detail?id=7189