amazon-archives / aws-sdk-react-native

AWS SDK for React Native (developer preview)
Apache License 2.0
631 stars 68 forks source link

Moving android async functions to background threads #9

Closed markbiddlecom closed 7 years ago

markbiddlecom commented 7 years ago

Using an abstraction over Android's AsyncTask.

I really wanted the BackgroundRunner's API to be lambda-based but that's apparently fraught in android land. I think my fallback is only slightly more verbose :smile:

Didn't migrate DynamoDB or any of the other libraries because I'm not using those in my app and so can't test them directly. Both Cognito and Lambda are working in the happy case on my simulator. I haven't yet directly tested the failure cases, but will try to get to that soon.

Ran the unit tests from my consuming app and seems like they still pass, but I'll confess I'm not exactly sure I'm doing that right.