[Design the new POJO MicroContainer] - Re: JBoss with spaces in the directory name
by alesj
I still think the path should be decoded asap in the whole execution stack.
Since there might be a few similar cache points to this one I found in FileHandler:
| public VirtualFileHandler createChildHandler(String name) throws IOException
| {
| File parentFile = getFile();
| File child = new File(parentFile, name);
| VirtualFileHandler handler = childCache.get(name);
| // if a child has already been created use that
| // if the child has been modified on disk then create a new handler
| if (handler != null && handler.hasBeenModified())
| {
| handler = null;
| }
| if (handler == null)
| {
| FileSystemContext context = getVFSContext();
| handler = context.createVirtualFileHandler(this, child);
| if (handler != null)
| childCache.put(name, handler);
| }
| return handler;
| }
|
e.g. if the name once comes with %20 and the 2nd time w/o, then we'll have two entries for the same file.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166419#4166419
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166419
17 years, 8 months
[Design the new POJO MicroContainer] - Re: VFS Performance
by adrian@jboss.org
"adrian(a)jboss.org" wrote : "adrian(a)jboss.org" wrote :
| | Reading byte code from zip files
| |
| | | java.util.zip.Inflater.inflateBytes(Inflater.java:Unknown line)
| | | java.util.zip.Inflater.inflate(Inflater.java:215)
| | | java.util.zip.InflaterInputStream.read(InflaterInputStream.java:128)
| | | java.io.FilterInputStream.read(FilterInputStream.java:90)
| | | org.jboss.virtual.plugins.context.zip.ZipEntryInputStream.read(ZipEntryInputStream.java:112)
| | | org.jboss.classloader.plugins.ClassLoaderUtils.loadByteCode(ClassLoaderUtils.java:150)
| | | org.jboss.classloader.spi.base.BaseClassLoader$2.run(BaseClassLoader.java:475)
| | | org.jboss.classloader.spi.base.BaseClassLoader$2.run(BaseClassLoader.java:464)
| | | java.security.AccessController.doPrivileged(AccessController.java:Unknown line)
| | | org.jboss.classloader.spi.base.BaseClassLoader.loadClassLocally(BaseClassLoader.java:462)
| | |
| |
|
| This one might improve if we wrap the VFS stream in a BufferedInputStream
| in ClassLoaderUtils?
|
Although ClassLoaderUtils is already using a 1K buffer, so its probably
not relevant introducing more buffering.
However BufferedInputStream uses an 8K buffer by default, so maybe
we can increase the buffer size to see if it helps.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4166412#4166412
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4166412
17 years, 8 months