Giter Club home page Giter Club logo

Comments (3)

martijnhoekstra avatar martijnhoekstra commented on August 18, 2024

note: perhaps it's actually/also the implementation that's wrong, and it should return a Future<Result> rather than a Future<Void>? It for sure it's not easy to get the results from the ResponseHandler

from aws-sdk-java-v2.

debora-ito avatar debora-ito commented on August 18, 2024

CompletableFuture<Void> is correct, it's not a bug.

SelectObjectContent is an event stream operation, so you need to use the SelectObjectContentResponseHandler to handle the response stream.

I see we don't have a S3 SelectObjectContent example in our Developer Guide, I'll work with our Docs Team and add one. In the meantime, take a look at the code in our Integration Tests and see if it's helpful -
https://github.com/aws/aws-sdk-java-v2/blob/master/services/s3/src/it/java/software/amazon/awssdk/services/SelectObjectContentIntegrationTest.java#L51

from aws-sdk-java-v2.

martijnhoekstra avatar martijnhoekstra commented on August 18, 2024

I see, I would have expected the returned value to hold some sort of API for streaming the response -- sort of like the V1 sync client does.

The examples do help, though it's a bit dishearting to see that the exposed API is so low level: Records message: Can contain a single record, partial records, or multiple records. Depending on the size of the result, a response can contain one or more of these messages. getting a stream of records out of the stream of messages is something I would have expected the SDK to do, not something to be done on the application level.

Documentation with an example that shows getting a stream of messages in CSV and JSON output would be very handy, since that's the intended use.

from aws-sdk-java-v2.

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.