tracker issue : CF-4203581

select a category, or use search below
(searches all categories and all time range)
Title:

"java.lang.NoClassDefFoundError: java/nio/channels/FileLock" during shutdown and restart

| View in Tracker

Status/Resolution/Reason: To Track//PRNeedInfo

Reporter/Name(from Bugbase): A. Bakia / ()

Created: 11/27/2018

Components: Caching, Distributed Caching

Versions: 2016

Failure Type: Others

Found In Build/Fixed In Build: 2016.0.07.311392 /

Priority/Frequency: Normal /

Locale/System: / Win 2016

Vote Count: 0

Problem Description: 
Whenever we restart ColdFusion we get the following error message in coldfusion-error.log.

Steps to Reproduce:
1) Restart ColdFusion (or a ColdFusion instance);
2) Open the log file, coldfusion-error.log, in a text editor and examine the lines corresponding to the restart.

Actual Result:
You will see the following error message:

Jul 26, 2018 11:01:18 AM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["ajp-nio-8026"]
Exception in thread "Thread-11" java.lang.NoClassDefFoundError: java/nio/channels/FileLock
	at net.sf.ehcache.DiskStorePathManager$DiskStorePath.unlock(DiskStorePathManager.java:358)
	at net.sf.ehcache.DiskStorePathManager.releaseLock(DiskStorePathManager.java:236)
	at net.sf.ehcache.CacheManager.shutdown(CacheManager.java:1571)
	at coldfusion.tagext.io.cache.ehcache.GenericEhcache$CacheCleanUpAgent.run(GenericEhcache.java:1166)
	at coldfusion.scheduling.Scheduler.run(Scheduler.java:245)
	at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.ClassNotFoundException: java.nio.channels.FileLock
	at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
	at coldfusion.bootstrap.BootstrapClassLoader.loadClass(BootstrapClassLoader.java:226)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:357)

Expected Result:
No such error message.

Any Workarounds:
Not applicable

Attachments:

Comments:

We are uncertain as to the effect of NoClassDefFoundError exception on java.nio.channels.FileLock. It might be negligible. But then again it might be critical.
Comment by A. B.
29971 | November 27, 2018 04:16:24 PM GMT
Setup: We are using distributed Ehcache
Comment by A. B.
29990 | December 03, 2018 11:14:25 AM GMT
I have attached the relevant Java source code
Comment by A. B.
30074 | December 19, 2018 02:27:32 PM GMT
Hi Bakia I don't see this error of CF restart. I am verifying this on CF2016. Could you please check that any piece of code is generating this error and let me know about the same. Thanks Poonan
Comment by Poonam J.
30126 | January 17, 2019 05:08:51 AM GMT
Hi Poonam, Thank you for taking a look at this ticket. I am withdrawing it, as I have been unable to reproduce the issue consistently. Nevertheless, I am searching for a solution or workaround myself. Kind regards, Bakia
Comment by A. B.
30156 | January 29, 2019 08:36:15 PM GMT