I developing a web application using GWT where i am trying to upload a file . My servlet is working fine.
but when i use DiskFileItemFactory() it gives me error.
You cannot use RMI in GAE - if you want something similar, take a look at this question.
But from your code it doesn't seem you need to use RMI at all - why are you using it? Ain't you just going to process and store it somewhere?
If you are going to store large files (up to 32MB), use the Blobstore API.
If you know you'll only have files <1MB, you can store them using JDO/JPA and a normal Entity that contains a Blob - this option will also allow you to easily pre-process the data.