GithubHelp home page GithubHelp logo

Comments (13)

luannguyenkhoa avatar luannguyenkhoa commented on August 15, 2024 3

I can get this worked with my folk: https://github.com/luannguyenkhoa/aws-mobile-appsync-sdk-ios
The only thing you need to implement is adding a func inside extension AWSS3TransferUtility: AWSS3ObjectManager{} in API.swift file as below:

public func uploadFiles(s3Objects: [AWSS3InputObjectProtocol & AWSS3ObjectProtocol], completion: @escaping ((Bool, Error?) -> Void)) {}

that should performs a parallel file upload when getting invoked.
All changes are included the latest commit, very appreciated if you guys can take a look and leave some ideas.

from aws-mobile-appsync-sdk-ios.

Derek-X-Wang avatar Derek-X-Wang commented on August 15, 2024 1

Hi @rohandubal,

Thanks for replying!

I had thought about that option in the beginning.

Since it's a mutation that will be used a lot, I would like to keep thumbnail generation locally to save some money.

I'm currently doing two mutations in sequence for uploading and it works.

But the thing just gets messier after we figure it out that we may need three complex objects.

It will be really awesome that the SDK will handle the S3 uploads.

Anyway, keep me updated on this.

Thanks,
Derek

from aws-mobile-appsync-sdk-ios.

end3r117 avatar end3r117 commented on August 15, 2024 1

I came here because I just tried to do this, too! Specifically the thumbnail thing. I'll try the lambda solution for now and will watch this thread.

Thanks, guys!

from aws-mobile-appsync-sdk-ios.

rohandubal avatar rohandubal commented on August 15, 2024

Hello @Derek-X-Wang

Thanks for reporting this use-case. I will take this as a feature request to the team.

In the mean while, could you use some lambda trigger to create thumbnails once the customer uploads the complex objects? You can find the tutorial to do that here.

Thanks,
Rohan

from aws-mobile-appsync-sdk-ios.

rohandubal avatar rohandubal commented on August 15, 2024

Thanks again for explaining your use-case. This helps us determine our future features. I will keep this thread updated if we have a solution to achieve this in a simple way using the SDK.

Thanks,
Rohan

from aws-mobile-appsync-sdk-ios.

adamup928 avatar adamup928 commented on August 15, 2024

@palpatim, @rohandubal - Is there any movement on this feature implementation? We'd also like the option to upload multiple S3 object types within a single mutation.

from aws-mobile-appsync-sdk-ios.

DanteEvil avatar DanteEvil commented on August 15, 2024

Hello all,
Do we have any update on this issue?
I'm using AWSAppSync 3.0.0 but seems no way to upload more than one s3 object in the same mutation.

input CreateMessageInput {
	id: ID
	messageContent: [S3ObjectInput] -> Unable to upload
}
input CreateMessageInput {
	id: ID
	messageContent: S3ObjectInput -> Work fine
}

@luannguyenkhoa did you able to handle this issue?
Thanks

from aws-mobile-appsync-sdk-ios.

julien-tamade avatar julien-tamade commented on August 15, 2024

Hi,

I'm also curious about the status of this. I'm planning to write a schema with a model that will have an array of photos and am hoping to use the built in s3 support

thanks!

from aws-mobile-appsync-sdk-ios.

end3r117 avatar end3r117 commented on August 15, 2024

They've said they're aware of the feature request. As others have pointed out, it really just comes down to adding a method or two to the existing code. A while back, I also made a fork that worked for my purposes. [UPDATE] I updated the code for AWSAppSync 3.1.3. Still works for me.

Fork's diff page showing methods

It just recursively parses out the multiple S3Objects from their GraphQLMapConvertible structs... Again, works for me . Maybe it'll at least help point you in the right direction until official SDK support.

from aws-mobile-appsync-sdk-ios.

jonathanarevalogaray avatar jonathanarevalogaray commented on August 15, 2024

Hi,

Just wanted to see if there is an update/timeline on this issue? We are also planning on using a schema with multiple s3 objects and it would be awesome to have SDK support for this.

Thanks!

from aws-mobile-appsync-sdk-ios.

jonathanarevalogaray avatar jonathanarevalogaray commented on August 15, 2024

Hi,

It has been over 3 years, what is the status on this? Are there any recommendations/other approaches?

Thanks.

from aws-mobile-appsync-sdk-ios.

DanteEvil avatar DanteEvil commented on August 15, 2024

@jonathanarevalogaray I ended up using RxSwift to handle this issue, basically, I've used zip to merge multiple uploading requests then subscript for the result when all of them are finished.

from aws-mobile-appsync-sdk-ios.

atierian avatar atierian commented on August 15, 2024

Thank you for opening this issue. AWS AppSync SDK for iOS entered maintenance mode in September 2023 and will receive no further updates as of September 2024.

Please use Amplify Swift going forward. For information on upgrading to Amplify Swift, refer to the Upgrade from AppSync SDK documentation.

from aws-mobile-appsync-sdk-ios.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.