terça-feira, 27 de agosto de 2013

Error loading theme, cannot find "theme.css" resource of "primefaces-bootstrap" library

Pessoal.. hoje tive o erro:

[8/27/13 15:17:23:188 BRT] 00000043 CustomExcepti E   Error loading theme, cannot find "theme.css" resource of "primefaces-bootstrap" library
                                 javax.faces.FacesException: Error loading theme, cannot find "theme.css" resource of "primefaces-bootstrap" library
    at org.primefaces.renderkit.HeadRenderer.encodeTheme(HeadRenderer.java:130)
    at org.primefaces.renderkit.HeadRenderer.encodeBegin(HeadRenderer.java:92)
    at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:579)
    at javax.faces.component.UIComponentBase.encodeAll(UIComponentBase.java:519)
    at javax.faces.component.UIComponentBase.encodeAll(UIComponentBase.java:533)
    at org.apache.myfaces.view.facelets.FaceletViewDeclarationLanguage.renderView(FaceletViewDeclarationLanguage.java:1581)
    at org.apache.myfaces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:264)
    at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:116)
    at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:239)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:191)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1224)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:774)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:456)
    at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
    at com.ibm.ws.webcontainer.filter.WebAppFilterChain.invokeTarget(WebAppFilterChain.java:136)
    at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:97)
    at org.primefaces.webapp.filter.FileUploadFilter.doFilter(FileUploadFilter.java:79)
    at com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter(FilterInstanceWrapper.java:195)
    at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:91)
    at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:928)
    at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1025)
    at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:87)
    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:895)
    at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1662)
    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:195)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:452)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:511)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:305)
    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
    at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
    at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
    at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
    at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
    at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
    at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
    at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1659)

[8/27/13 15:17:23:188 BRT] 00000043 SystemOut     O
 DEBUG ERROR
[8/27/13 15:17:23:188 BRT] 00000043 SystemOut     O


O erro foi pois eu tinha isso no meu web.xml:

    <context-param>
        <param-name>primefaces.THEME</param-name>
        <param-value>bootstrap</param-value>
    </context-param>

porém eu não tinha a dependência no meu pom.xml para o primefaces-bootstrap.. por isso acontecia o erro..

Abraços!
Adriano Schmidt

Um comentário:

  1. Cara, valeu pelo post. No final das contas foi simples o problema e a solução e resolveu pra mim. Abraços!

    ResponderExcluir