JSF1064: Unable to find or serve resource, theme.css, from library, primefaces.

UI Components for JSF
User avatar
tefron
Posts: 93
Joined: 15 Sep 2010, 23:54
Location: Canada
Contact:

23 May 2018, 17:03

It seems that we both lack the knowledge to solve this issue, however, the fact that the error is coming from JSF does not mean that it didn't originated in primefaces.

For example the issue below has the same error message that was solved in primefaces:

viewtopic.php?t=50198
PrimeFaces: primefaces-6.2
Mojara2.1.13
Netbeans8.2
wildfly-13.0.0.Final

tandraschko
PrimeFaces Core Developer
Posts: 3644
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

23 May 2018, 17:07

But not when random ;)
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

javajuneau
Posts: 12
Joined: 13 Mar 2013, 20:22

30 May 2018, 14:31

I am receiving this same warning JSF1064 when using Payara Server 5 (full) with HTTP2 support enabled, and the resource is pointing to an issue with PrimeFaces resources...specifically with the Sentinel layout. I eventually receive a java.io.IOException: Connection is closed, and the page simply hangs and the browser continues to load forever.

The problem is resolved when HTTP2 support is disabled. I am currently using with HTTP2 disabled, but it would be great if I were able to take full advantage of the new features in Java EE 8. Any ideas why the PrimeFaces resources are being flagged with this warning?

spadovan
Posts: 137
Joined: 05 Jun 2013, 12:04

30 May 2018, 14:37

I have same problem with widifly 10.2 and Firefox 60, please help us, thanks
Primefaces 7.0.7, Wildfly 14.0.1, JDK 8

Melloware
Posts: 1346
Joined: 22 Apr 2013, 15:48

31 May 2018, 13:54

For Firefox your issue is this: viewtopic.php?f=48&t=55047&start=10

Terrible terrible new Firefox feature turned on by default.
PrimeFaces Developer | PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 7.0.8 / PF Extensions 7.0.3

javajuneau
Posts: 12
Joined: 13 Mar 2013, 20:22

04 Jun 2018, 13:57

I've forgotten to mention that HTTP/2 works fine without SSL. Therefore, it is the HTTPS and HTTP/2 combination that is causing the issue.

I've tried from Safari, Chrome, and FireFox with the same result on each. When HTTP/2 is enabled on http-listener2 (SSL), the pages do not load or they take a significant time to load (60+ seconds).

Warning: JSF1064: Unable to find or serve resource, fonts/titilliumweb-regular-webfont.svg, from library, primefaces-sentinel.
Warning: java.io.IOException: Write timeout exceeded when trying to flush the data
at org.glassfish.grizzly.http.io.OutputBuffer.blockAfterWriteIfNeeded(OutputBuffer.java:999)
at org.glassfish.grizzly.http.io.OutputBuffer.write(OutputBuffer.java:701)
at org.apache.catalina.connector.OutputBuffer.writeBytes(OutputBuffer.java:336)
at org.apache.catalina.connector.OutputBuffer.write(OutputBuffer.java:323)
at org.apache.catalina.connector.CoyoteOutputStream.write(CoyoteOutputStream.java:154)
at java.nio.channels.Channels$WritableByteChannelImpl.write(Channels.java:458)
at com.sun.faces.application.resource.ResourceHandlerImpl.handleResourceRequest(ResourceHandlerImpl.java:342)
at javax.faces.application.ResourceHandlerWrapper.handleResourceRequest(ResourceHandlerWrapper.java:195)
at org.primefaces.application.resource.PrimeResourceHandler.handleResourceRequest(PrimeResourceHandler.java:87)
at javax.faces.application.ResourceHandlerWrapper.handleResourceRequest(ResourceHandlerWrapper.java:195)
at javax.faces.webapp.FacesServlet.executeLifecyle(FacesServlet.java:728)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:475)
at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1622)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:339)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:209)
at org.apache.logging.log4j.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:71)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:251)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:209)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:160)
at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:654)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:593)
at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:99)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:159)
at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:371)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:238)
at com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:516)
at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:213)
at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:182)
at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:156)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:218)
at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:95)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:260)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:177)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:109)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:88)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:53)
at org.glassfish.grizzly.http2.Http2Session.sendMessageUpstream(Http2Session.java:1285)
at org.glassfish.grizzly.http2.Http2Session.sendMessageUpstream(Http2Session.java:1261)
at org.glassfish.grizzly.http2.Http2ServerFilter$2.run(Http2ServerFilter.java:1056)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:569)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:549)
at java.lang.Thread.run(Thread.java:748)

Warning: JSF1064: Unable to find or serve resource, fonts/titilliumweb-semibolditalic-webfont.eot, from library, primefaces-sentinel.
Warning: java.io.IOException: Connection is closed
at org.glassfish.grizzly.nio.NIOConnection.assertOpen(NIOConnection.java:440)
at org.glassfish.grizzly.http.io.OutputBuffer.write(OutputBuffer.java:663)
at org.apache.catalina.connector.OutputBuffer.writeBytes(OutputBuffer.java:336)
at org.apache.catalina.connector.OutputBuffer.write(OutputBuffer.java:323)
at org.apache.catalina.connector.CoyoteOutputStream.write(CoyoteOutputStream.java:154)
at java.nio.channels.Channels$WritableByteChannelImpl.write(Channels.java:458)
at com.sun.faces.application.resource.ResourceHandlerImpl.handleResourceRequest(ResourceHandlerImpl.java:342)
at javax.faces.application.ResourceHandlerWrapper.handleResourceRequest(ResourceHandlerWrapper.java:195)
at org.primefaces.application.resource.PrimeResourceHandler.handleResourceRequest(PrimeResourceHandler.java:87)
at javax.faces.application.ResourceHandlerWrapper.handleResourceRequest(ResourceHandlerWrapper.java:195)
at javax.faces.webapp.FacesServlet.executeLifecyle(FacesServlet.java:728)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:475)
at org.apache.catalina.core.StandardWrapper.service(StandardWrapper.java:1622)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:339)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:209)
at org.apache.logging.log4j.web.Log4jServletFilter.doFilter(Log4jServletFilter.java:71)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:251)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:209)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:160)
at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:654)
at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:593)
at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:99)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:159)
at org.apache.catalina.connector.CoyoteAdapter.doService(CoyoteAdapter.java:371)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:238)
at com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:516)
at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:213)
at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:182)
at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:156)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:218)
at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:95)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:260)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:177)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:109)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:88)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:53)
at org.glassfish.grizzly.http2.Http2Session.sendMessageUpstream(Http2Session.java:1285)
at org.glassfish.grizzly.http2.Http2Session.sendMessageUpstream(Http2Session.java:1261)
at org.glassfish.grizzly.http2.Http2ServerFilter$2.run(Http2ServerFilter.java:1056)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:569)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:549)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.io.IOException: Locally closed

kukeltje
Expert Member
Posts: 9418
Joined: 17 Jun 2010, 13:34
Location: Netherlands

04 Jul 2018, 22:45

Warning: JSF1064: Unable to find or serve resource, fonts/titilliumweb-regular-webfont.svg, from library, primefaces-sentinel.
Warning: java.io.IOException: Write timeout exceeded when trying to flush the data
at org.glassfish.grizzly.http.io.OutputBuffer.blockAfterWriteIfNeeded(OutputBuffer.java:999)
How is PF (or JSF) responsible for this error? Really looks like a Payara issue... or a jdk issue? or caused by a client problem. (Or do you think it stops reading from the disk?)

https://stackoverflow.com/questions/432 ... h-the-data has the same error

and

https://stackoverflow.com/questions/502 ... ded-when-t
Ronald van Kuijk
______________________________
PrimeFaces 6.1, PrimeFaces plus 0.0.2 | JbossWildfly 10.1| Mojarra 2.2.13
Fedora 61, Firefox 'most recent'
Read the forum posting rules
Beginners: https://jsf.zeef.com/bauke.scholtz

kwutzke
Posts: 154
Joined: 20 Jul 2012, 21:35

09 Nov 2019, 22:32

Hello,

I found this on the new EE4J project:

https://github.com/eclipse-ee4j/mojarra/issues/4280

There's a patch for Mojarra users, e.g. those on Wildfly:
@BalusC Commented
Confirmed.

In the meanwhile, you can create a custom ResourceHandler to suppress the warnings. Here's an example: https://github.com/javaeekickoff/java-e ... Patch.java
Link again: https://github.com/javaeekickoff/java-e ... Patch.java

Example for PF resources:

Code: Select all

public class ResourceHandlerImplPatch extends DefaultResourceHandler {

	public ResourceHandlerImplPatch(ResourceHandler wrapped) {
		super(wrapped);
	}

	@Override
	public String getLibraryName() {
		return "primefaces";  // or "primefaces-<theme>" if needed
	}

	@Override
	public Resource createResourceFromLibrary(String resourceName, String contentType) {
		try {
			if (Faces.getResource("/" + getLibraryName() + "/" + resourceName) != null) {
				return getWrapped().createResource(resourceName, getLibraryName(), contentType);
			}
			else {
				return null; // So ResourceHandlerImpl with its unnecessary logging will be skipped.
			}
		}
		catch (MalformedURLException e) {
			throw new FacesException(e);
		}
	}
}
Just put it into the faces-config.xml like in https://github.com/javaeekickoff/java-e ... config.xml and the warnings should go away. If you use PF themes you probably have to add one resource handler for each theme that you use.

I had to remove the "/resources" prefix. Again, credits go to the infamous BalusC.

HTH
Karsten
PF 8.0, Mojarra 2.3, Wildfly 15

kukeltje
Expert Member
Posts: 9418
Joined: 17 Jun 2010, 13:34
Location: Netherlands

11 Nov 2019, 18:27

infamous? ;-)
Ronald van Kuijk
______________________________
PrimeFaces 6.1, PrimeFaces plus 0.0.2 | JbossWildfly 10.1| Mojarra 2.2.13
Fedora 61, Firefox 'most recent'
Read the forum posting rules
Beginners: https://jsf.zeef.com/bauke.scholtz

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 12 guests