...
Wiki Markup |
---|
If the Java Virtual Machine (JVM) interacts with a file system that operates over an unreliable network, file I/O might also incur a performance penalty. In such cases, avoid file I/O over the network while holding a lock. File operations such as logging that may block waiting for the output stream lock or for I/O to complete may be performed in a dedicated thread to speedupspeed up task processing. Logging requests can be added to a queue given that the {{put()}} operation incurs little overhead as compared to file I/O \[[Goetz 06, pg 244|AA. Java References#Goetz 06]\]. |
...