How can I Upload File on Amazon Glacier through web application?

352 views Asked by At

I am trying to create a web application which can upload files to amazon glacier. I have created web UI.

I am able to upload a file by giving file path if I run my program locally.

But I am unable to do it if I deploy my application on server. I am getting below exception:

"com.amazonaws.AmazonClientException: Unable to compute hash for file: "POST /dropbox/v1/documents/old/xyz/upload?filepath=E:\Test.txt HTTP/1.1" 400 34 174 174"

I have deployed application on amazon EC2.

Can anyone please help me? is there any easy way to get rid of this issue? plz help me..

ArchiveTransferManager atm = new ArchiveTransferManager(client,credentials);
String vaultName = "xyz";
String filePathUpload = "E:/bkp1/New Text Document.txt"

UploadResult result1 = atm.upload(vaultName, filePathUpload, new File(filePathUpload));
0

There are 0 answers