While reading am using encoding the file and agin if I encode it with same then the file become old type as in the server rite ?.
The encoding will be the same if you use the same encoding, otherwise it will be different (maybe I'm missing what you're trying to say).
is = new BufferedInputStream(new FileInputStream(pdfFile));
Again, this will only work if the file has the platform default encoding. If you're storing the file with any other encoding, then you need to specify that encoding here.