You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Prince Raj (Jira)" <ji...@apache.org> on 2026/09/23 06:11:00 UTC

[jira] [Assigned] (HDDS-16584) Object TTL configuration returns generic 400 error for past expiration date

     [ https://issues.apache.org/jira/browse/HDDS-16584?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Prince Raj reassigned HDDS-16584:
---------------------------------

    Assignee: Priyesh Karatha

> Object TTL configuration returns generic 400 error for past expiration date
> ---------------------------------------------------------------------------
>
>                 Key: HDDS-16584
>                 URL: https://issues.apache.org/jira/browse/HDDS-16584
>             Project: Apache Ozone
>          Issue Type: Bug
>            Reporter: Prince Raj
>            Assignee: Priyesh Karatha
>            Priority: Major
>
> h3. Description
> While testing S3 bucket lifecycle configuration, I observed that providing an expiration date in the past results in an HTTP 400 error, but the response does not provide a meaningful error message explaining that the lifecycle date is invalid because it is in the past.
> The API should provide a clear validation error explaining why the lifecycle configuration was rejected.
> h3. Steps to Reproduce
>  # Create a lifecycle configuration with an expiration date in the past.
>  
> {{{
>   "Rules": [\{
>     "ID": "expire-key1-fso",
>     "Status": "Enabled",
>     "Filter": {
>       "Prefix": "key1/"
>     },
>     "Expiration": \{
>       "Date": "2020-01-01T00:00:00Z"
>     }
>   }]
> }}}
>  # Apply the lifecycle configuration:
>  
> {{aws s3api put-bucket-lifecycle-configuration \
>   --bucket <bucket-name> \
>   --lifecycle-configuration file://lifecycle.json}}
>  # Observe the response.
> h3. Actual Result
> The request fails with {*}HTTP 400 / InvalidRequest{*}, but the response only contains a generic error:
>  
> {{An error occurred (InvalidRequest) when calling the PutBucketLifecycleConfiguration operation: Invalid Request}}
> There is no indication that the expiration date is rejected because it is in the past.
> h3. Expected Result
> The API should reject the invalid lifecycle configuration with a meaningful validation error that clearly indicates the reason for rejection, for example that the supplied expiration date is in the past.
> This would make it easier for users to identify and correct invalid lifecycle configurations.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org