bulk: report 413 Entity Too Large is limits on bulk requests are exce…#8093
Open
DmitryLitvintsev wants to merge 1 commit into11.0from
Open
bulk: report 413 Entity Too Large is limits on bulk requests are exce…#8093DmitryLitvintsev wants to merge 1 commit into11.0from
DmitryLitvintsev wants to merge 1 commit into11.0from
Conversation
…eded Motivation: ----------- Issue #7997 reports that when the number of targets in a bulk request exceeds the configured limit, dCache replies with HTTP 403 – Forbidden which is confusing. Suggested response: 413 Content Too Large Modification: ------------- Instead of BulkPermissionDeniedException throw newly added BulkContentTooLargeException when limits are exceeded and throwing ClientErrorException(REQUEST_ENTITY_TOO_LARGE, error) in the sunbsequent handling resulting in 413 code returned to the client. Result: -------- dCache replies w/ 413 Entity Too Large code when various bulk request limits are exceeded. python dcache_tape_api.py -d uqbar -s /pnfs/fs/usr/fermilab/users/litvinse/1.data /pnfs/fs/usr/fermilab/users/litvinse/10.data 413 Client Error: Request Entity Too Large for url: https://uqbar:3880/api/v1/tape/stage Ticket: #7997 Acked-by: Anastasiia Chub Patch: https://rb.dcache.org/r/14683/ Target: trunk Request: 11.2, 11.1, 11.0, 10.2 Require-book: no Require-notes: yes
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…eded
Motivation:
Issue #7997 reports that when the number of targets in a bulk request exceeds the configured limit, dCache replies with HTTP 403 – Forbidden which is confusing.
Suggested response: 413 Content Too Large
Modification:
Instead of BulkPermissionDeniedException throw newly added BulkContentTooLargeException when limits are exceeded and throwing ClientErrorException(REQUEST_ENTITY_TOO_LARGE, error) in the sunbsequent handling resulting in 413 code returned to the client.
Result:
dCache replies w/ 413 Entity Too Large code when various bulk request limits are exceeded.
python dcache_tape_api.py -d uqbar -s /pnfs/fs/usr/fermilab/users/litvinse/1.data /pnfs/fs/usr/fermilab/users/litvinse/10.data 413 Client Error: Request Entity Too Large for url: https://uqbar:3880/api/v1/tape/stage
Ticket: #7997
Acked-by: Anastasiia Chub
Patch: https://rb.dcache.org/r/14683/
Target: trunk
Request: 11.2, 11.1, 11.0, 10.2
Require-book: no
Require-notes: yes