我目前正在遷移到richfaces 4.5,JSF2.2並且還添加了primefaces-6.0(用於richfaces不支持的其他功能) 我正在使用Tomcat 8作爲服務器。rich:FileUpload stackoverflow錯誤在AjaxOutputTracker.getAjaxOutputs
在XHTML文件,我只是把下面只是爲了測試這個簡單的代碼:
<rich:fileUpload id="upload"
fileUploadListener="#{cc.attrs.beanPage.uploadListener}"
maxFilesQuantity="1"
acceptedTypes=".ppt, .pptx, .doc, .docx, .txt, .xls, .xlsx, .zip, .pdf" />
,並在uploadListener我只是把一些事情只是爲了調試
public void uploadListener(FileUploadEvent event) {
this.item = event.getUploadedFile();
String projectFileName = this.item.getName();
}
當我調試我看到它到達聽衆,並沒有錯誤地結束。但我聽到這個錯誤後聽到下面的錯誤:
java.lang.StackOverflowError
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:679)
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:643)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:86)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91).. keep repeating
Jul 15, 2016 4:09:36 PM org.primefaces.application.exceptionhandler.PrimeExceptionHandler logException
SEVERE: null
java.lang.StackOverflowError
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:679)
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:643)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:86)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91)... keep repeating
Jul 15, 2016 4:09:38 PM org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/PORTAL].[Faces Servlet] invoke
SEVERE: Servlet.service() for servlet [Faces Servlet] in context with path [/PORTAL] threw exception [Servlet execution threw an exception] with root cause
java.lang.StackOverflowError
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:679)
at javax.faces.component.UIComponentBase.findComponent(UIComponentBase.java:643)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:86)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91)
at org.richfaces.context.AjaxOutputTracker.getAjaxOutputs(AjaxOutputTracker.java:91)..... and so on keep repeating
以前它的工作在舊版本..任何想法,我在做什麼錯了?我懷疑有一個配置,我錯過了這個原因。
什麼是「舊版本」?沒有PF或舊的RF和JSF? –
沒有PF和較舊的RF和JSF。 – leafy
你是否解決了jQuery版本衝突(因爲總會有這樣的衝突)? BTW。這看起來有點可疑,findComponent中的SOE。 –