[ https://issues.apache.org/jira/browse/MYFACES-4565?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17689657#comment-17689657 ]
Werner Punz edited comment on MYFACES-4565 at 2/16/23 10:19 AM: ---------------------------------------------------------------- found it... The else part creates a TempDir resource loader! was (Author: werpu): This could be the cause... The deleteDir is called from init... Now I am not sure how synchronized the delete and create is with the java code (should be though), but in this sequence of TemFileDireCacheResourceLoader the image dir creation and deletion is called several times. Causing at least 3 times the deletion and recreation of the image dir, which might be in combination with file locks some operating systems have can cause this issue, theoretically. {code:java} _resourceLoaders = new ResourceLoader[] { new TempDirFileCacheResourceLoader(new ExternalContextResourceLoader('/' +directory)), new TempDirFileCacheResourceLoader(new FacesFlowClassLoaderResourceLoader()), new TempDirFileCacheResourceLoader( new FacesJSResourceLoader( new InternalClassLoaderResourceLoader(META_INF_RESOURCES))), new TempDirFileCacheResourceLoader( new FacesJSResourceLoader( new ClassLoaderResourceLoader(META_INF_RESOURCES))) }; {code} This is by no means new code! Similar code has been in the code base since ages. > TempDirFileCacheResourceLoader delete error > ------------------------------------------- > > Key: MYFACES-4565 > URL: https://issues.apache.org/jira/browse/MYFACES-4565 > Project: MyFaces Core > Issue Type: Task > Affects Versions: 4.0.0-RC5 > Reporter: Werner Punz > Assignee: Werner Punz > Priority: Major > -- This message was sent by Atlassian Jira (v8.20.10#820010)