-
Notifications
You must be signed in to change notification settings - Fork 594
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: update streaming dependencies to support react-native #895
Conversation
This comment has been minimized.
This comment has been minimized.
Codecov Report
@@ Coverage Diff @@
## smithy-codegen #895 +/- ##
==================================================
+ Coverage 92.15% 92.18% +0.03%
==================================================
Files 148 149 +1
Lines 2905 2930 +25
Branches 513 516 +3
==================================================
+ Hits 2677 2701 +24
- Misses 228 229 +1
Continue to review full report at Codecov.
|
Found an issue: the Need to dive deep on where do these discrepencies come from. UPDATE: v3 browser is actually parsed same to v3 ReactNative: |
Because the test cases doesn't work in karma for now, but have been validated in rn integration test. see: aws#895
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread. |
UPDATE: This PR update the dependency packages that uses API's not exist in ReactNative.
chunked-blob-reader-rn
: Equivalents tochunked-blob-reader
package in browser except that it usesFileReader.readAsDataURL()
instead ofFileReader.readAsArrayBuffer()
. The later one is not implemented in RN (code)stream-collector-rn
: Equivalents tostream-collector-browser
package in browser except not usingFileReader.readAsArrayBuffer()
.fetch-http-handler
: AddbufferBody
config to the constructor. If it's set totrue
, thefetch-http-handler
will buffer the whole response before returning. Hence, the returnedResponse.body
will be aBlob
shape instead ofReadableStream
in browsers normally. So response streaming is not available in RN. When the option is set,fetch-http-handler
usesBody.blob()
under the hood to buffer the response.This PR is tested with
CognitoIdentity.GetId
,S3.putObject
,S3.deleteObject
,S3.deleteObjects
,S3.listObjects
.Resolves: #881 #874
This is a POC of adding RN support to SDK. Only tested withS3.listObjects
. before setting up the local test environment, you need to manually publish all the relacted V3 SDK packages to a local npm server.Test repo: https://github.com/AllanFly120/RNTestJSSDK
Screen Shot:
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.