When I am doing file upload, the files are also getting created in "bin" directory of JBoss.
How to avoid this.
Since you run the jboss server from the bin directory, thats the default location for all the uploaded files.
The MultiPartMimeServlet takes a constructor argument that can be set to be the file upload directory. Since its empty by default, it puts in the directory from where the server is started