Can you describe a bit more about your application and enviroment?
what os you use? version of java, what does you applicaion look like? using any frameworks?
What does you code do exacly? processing files. are you closing input/output streams?
if you are on linux can you post output of lsof for jboss java process.
Java version : 1.6.0_23 64 bit
OS: Windows 7 64 bit
Frameworks: All plugins are osgi plugin jar files added to Jboss 7 server group
Jboss : Jboss 7.1.0 Final using the server in ha mode.
About the application:
I have the about 120 files( each line line approximately 1KB) coming every few seconds sitting in a shared directory. My applicaiton picks the file parses it and then writes the data to database.
Picking ->Parsing ->Writing to database takes less than a second ( each server instance ) initially. But after a few second picking the file itself takes long time .
I have doubts at two places:
1 ) Jgroups ( related to network traffic )
2 ) Memory usage and Garbage collection
Note:Closing the stream after each read.