Skip to content
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

Slower Fetch Times for S3 Objects in INTELLIGENT_TIERING compared to STANDARD Tier #3192

Open
1 task
Manjunathagopi opened this issue Nov 14, 2024 · 9 comments
Assignees
Labels
bug This issue is a bug. p2 This is a standard priority issue

Comments

@Manjunathagopi
Copy link

Describe the bug

Currently, we are attempting to download S3 objects in part size of 24MB, the fetch time for each 24MB chunk is noticeably slower in the INTELLIGENT_TIERING storage class compared to the STANDARD tier.

Regression Issue

  • Select this option if this issue appears to be a regression.

Expected Behavior

As we know initial fetching time for intelligent tiering will be slow but once the first download is complete, the rest of the download will be invariant.

Current Behavior

As we know initial fetching time for intelligent tiering will be slow but once the first download is complete, the rest of the download will be invariant. But this is not happening using AWS CPP SDK.

Reproduction Steps

To reproduce the issue, start downloading S3 objects from the INTELLIGENT_TIERING storage class in small chunks and compare with downloading from STANDARD tiering. You'll easily observe that fetch times for each part are significantly slower in INTELLIGENT_TIERING.

Possible Solution

No response

Additional Information/Context

No response

AWS CPP SDK version used

1.11.408

Compiler and Version used

gcc (GCC) 4.8.5

Operating System and version

CentOS Linux and version 7

@Manjunathagopi Manjunathagopi added bug This issue is a bug. needs-triage This issue or PR still needs to be triaged. labels Nov 14, 2024
@jmklix
Copy link
Member

jmklix commented Nov 15, 2024

Can you include some trace level logs of the GetObjectRequests that you are making? There should be a header included in the response that says some info about the current tier that your objects currently have

@jmklix jmklix added response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. p2 This is a standard priority issue and removed needs-triage This issue or PR still needs to be triaged. labels Nov 15, 2024
@jmklix jmklix self-assigned this Nov 15, 2024
@Manjunathagopi
Copy link
Author

@jmklix please find the trace level logs for both intelligent tiering and standard tiering below.
Intelligent-tiering logs , Standard-tiering logs

@jmklix jmklix removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Nov 18, 2024
@jmklix
Copy link
Member

jmklix commented Nov 20, 2024

Sorry, but I was mistaken. The logs only state the the storage class is INTELLIGENT_TIERING rather then tell us what tier each object is currently at:

[TRACE] 2024-11-18 11:01:37.792 http-stream [140011056908032] id=0x7f56d001e680: Incoming header: x-amz-storage-class: INTELLIGENT_TIERING

This looks like the s3 might not have you object in the tier that you are expecting. This might be because something is wrong on the s3 side, s3 is taking longer than expected to change the tier, or s3 documentation might not be clear with it's documentation for how intelligent tiering is supposed to work. Can you try analyzing what storage tier some objects are before and after you try accessing them? You can to this with s3 Inventory and look for this field S3 Intelligent-Tiering access tier

@jmklix jmklix added the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Nov 20, 2024
@Manjunathagopi
Copy link
Author

@jmklix but aws s3 cp cli command is taking the same time to download the file irrespective of STANDARD or INTELLIGENT_TIERING

@github-actions github-actions bot removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Nov 23, 2024
@DmitriyMusatkin
Copy link
Contributor

Is cli and cpp perf similar for standard tier?
Im wondering of cli is equally slow for both tiers, but for cpp something is making standard tier faster, but not intelligent tier.

In general there should be no tier specific code in sdks. To sdk is just all endpoint and it does not care what data it is pulling. My initial guess is that it might have something to do with dns resolution or connection pooling. S3 supported mva dns for over a year now, but maybe something in how cpp sdk chooses ip or how it reuses connection causes intelligent to be slower

@jmklix jmklix added the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Nov 27, 2024
@Manjunathagopi
Copy link
Author

@DmitriyMusatkin relatively CLI performance for both STANDARD and INTELLIGENT-TIERING is the same, so why its not the same in the case of CPP performance?

@DmitriyMusatkin
Copy link
Contributor

Hard to tell off hand without a deeper dive. What we know is on sdk side there is no difference between the tiers, sdk ends up calling the same endpoints regardless of tier. This will require some bandwidth from someone sdk team to investigate.

Some potential theories:

  • cli is just slow for both tiers, while on cpp sdk side some optimization makes standard tier go faster, but not intelligent tier. im not an expert on how intelligent tier is implemented, but i think its reasonable to assume that s3 cannot make the object hot in all hosts after initial download in intelligent tier. So its possible that CPP SDK is more eager to connect to new host on which the object is not hot
  • maybe cli and cpp send slightly different requests and that has impact on perf. thing like transfer-encoding or some defaults might be different

Note: cli does not save anything on client side between runs. So whatever results in improved perf on subsequent runs must be server side

@github-actions github-actions bot removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Dec 3, 2024
@jmklix
Copy link
Member

jmklix commented Dec 11, 2024

What timings are you seeing for STANDARD vs INTELLIGENT-TIERING are you seeing when using the cpp sdk?

@jmklix jmklix added the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Dec 11, 2024
@Manjunathagopi
Copy link
Author

@jmklix To fetch 24MB from intelligent-tiering using CPP SDK it is taking around 1200ms, while fetching from STANDARD tiering it is taking around 400ms for the same. There is around 800ms diff between the two.
Yes we are see this using CPP SDK

@github-actions github-actions bot removed the response-requested Waiting on additional info and feedback. Will move to "closing-soon" in 10 days. label Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue is a bug. p2 This is a standard priority issue
Projects
None yet
Development

No branches or pull requests

3 participants