5

What's the best way to use Amazon Simple Storage Service (S3) on Android?

For iPhone I use ASIHTTPRequest. Is there something similar for Android?

hpique
  • 119,096
  • 131
  • 338
  • 476

3 Answers3

4

There is now an Amazon-supported Android SDK: http://aws.amazon.com/sdkforandroid/ . It's only been out since the end of 2010, but it seems to work well - it allowed me to easily upload a photo to S3.

Eric Brynsvold
  • 2,880
  • 3
  • 17
  • 22
1

To be honest I think if no library exists which works with android you will need to just roll your own. Take a look at the REST API and implement just the methods that you need for your application.

Doing it this way is more work but you will keep the filesize of your application down.

Nick Bastin
  • 30,415
  • 7
  • 59
  • 78
matto1990
  • 3,766
  • 2
  • 27
  • 32
  • +1 S3 is RESTful and does only expose two kinds of resources (buckets and objects). This should not be too complicated... – moxn Jun 26 '10 at 22:09
  • @moxn: writing your own generic S3 library that actually supports ACLs, etc., is reasonably complex. That being said, writing a library that serves the needs of a specific application is much less complex. – Nick Bastin Jun 27 '10 at 04:24
  • I should add that an Amazon employee recommended using this method over at the Amazon forums. – hpique Jun 28 '10 at 22:28
0

I think any S3 Java API should do it ? Look at the docs for Java API Libraries.

Toni Menzel
  • 764
  • 3
  • 10
  • 1
    The AWS Java SDK requires third-party libraries that seem incompatible with Android. – hpique Jun 20 '10 at 10:19
  • Can you give a pointer of what is incompatible ? Link Resource or Errormessage etc ? – Toni Menzel Jun 22 '10 at 07:58
  • 1
    They need third-party jars that include java.* and javax.* packages. Even if they were compatible, the jar dependencies amount to more than 6MB, which is too much for a mobile application. – hpique Jun 22 '10 at 11:11