Skip to content

Conversation

@SanjayMarreddi
Copy link
Contributor

@SanjayMarreddi SanjayMarreddi commented Jun 20, 2025

Description
This PR is a follow-up to the existing PRs #13347 and #13348 in the series addressing feature gaps in the stream powered by analytics-accelerator-s3. It's part of our ongoing effort towards default-on integration. This PR specifically adds support for range-based reads.

Testing
When s3.analytics-accelerator.enabled is set to true, previously skipped integration test testRangeRead works now.

@github-actions github-actions bot added the AWS label Jun 20, 2025
SanjayMarreddi added a commit to awslabs/analytics-accelerator-s3 that referenced this pull request Jun 25, 2025
## Description of change
We want to support `readFully` as a part of our ongoing effort to
integrate with Iceberg S3FileIO by default. [RangeReadable in
Iceberg](https://github.com/apache/iceberg/blob/main/api/src/main/java/org/apache/iceberg/io/RangeReadable.java#L47)

**Note:** Here's the comparison with existing read method:

| Aspect | `read(byte[] buffer, int offset, int length)` |
`readFully(long position, byte[] buffer, int offset, int length)` |

|--------|----------------------------------------------|-------------------------------------------------------------------|
| Method Signature | Reads from current stream position | Reads from
specified position |
| Position Behavior | Advances the stream position by the number of
bytes actually read | Does not modify the stream position
(position-independent read) |
| Return & Error Handling | Returns `int` indicating bytes read; returns
-1 at end of stream; may return fewer bytes than requested | Returns
`void`; throws `IOException` if unable to read exact number of requested
bytes |

#### Relevant issues
Once this feature is released as `1.2.0`, we will update this [Iceberg
PR](apache/iceberg#13361)

#### Does this contribution introduce any breaking changes to the
existing APIs or behaviors?
No

#### Does this contribution introduce any new public APIs or behaviors?
Yes

#### How was the contribution tested?
Ran existing and new tests locally

#### Does this contribution need a changelog entry?
- [x] I have updated the CHANGELOG or README if appropriate

---

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license and I agree to the terms of
the [Developer Certificate of Origin
(DCO)](https://developercertificate.org/).
ozkoca pushed a commit to awslabs/analytics-accelerator-s3 that referenced this pull request Jun 26, 2025
## Description of change
We want to support `readFully` as a part of our ongoing effort to
integrate with Iceberg S3FileIO by default. [RangeReadable in
Iceberg](https://github.com/apache/iceberg/blob/main/api/src/main/java/org/apache/iceberg/io/RangeReadable.java#L47)

**Note:** Here's the comparison with existing read method:

| Aspect | `read(byte[] buffer, int offset, int length)` |
`readFully(long position, byte[] buffer, int offset, int length)` |

|--------|----------------------------------------------|-------------------------------------------------------------------|
| Method Signature | Reads from current stream position | Reads from
specified position |
| Position Behavior | Advances the stream position by the number of
bytes actually read | Does not modify the stream position
(position-independent read) |
| Return & Error Handling | Returns `int` indicating bytes read; returns
-1 at end of stream; may return fewer bytes than requested | Returns
`void`; throws `IOException` if unable to read exact number of requested
bytes |

#### Relevant issues
Once this feature is released as `1.2.0`, we will update this [Iceberg
PR](apache/iceberg#13361)

#### Does this contribution introduce any breaking changes to the
existing APIs or behaviors?
No

#### Does this contribution introduce any new public APIs or behaviors?
Yes

#### How was the contribution tested?
Ran existing and new tests locally

#### Does this contribution need a changelog entry?
- [x] I have updated the CHANGELOG or README if appropriate

---

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license and I agree to the terms of
the [Developer Certificate of Origin
(DCO)](https://developercertificate.org/).
@SanjayMarreddi SanjayMarreddi marked this pull request as ready for review June 27, 2025 10:36
@SanjayMarreddi SanjayMarreddi force-pushed the support_range_reads_in_AAL_stream branch from 371918f to 9ae820a Compare June 27, 2025 16:15
@SanjayMarreddi SanjayMarreddi force-pushed the support_range_reads_in_AAL_stream branch from 9ae820a to a85ef81 Compare July 8, 2025 13:32
@github-actions
Copy link

github-actions bot commented Aug 8, 2025

This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.

@github-actions github-actions bot added the stale label Aug 8, 2025
@github-actions
Copy link

This pull request has been closed due to lack of activity. This is not a judgement on the merit of the PR in any way. It is just a way of keeping the PR queue manageable. If you think that is incorrect, or the pull request requires review, you can revive the PR at any time.

@github-actions github-actions bot closed this Aug 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants