Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8670231
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T18:39:50+00:00 2026-06-12T18:39:50+00:00

The Google Cloud Storage Developer Guide explains how to set Cache-Control headers, and explains

  • 0

The Google Cloud Storage Developer Guide explains how to set Cache-Control headers, and explains their critical impact on the consistency behavior of the api, yet the Expires headers aren’t mentioned nor did they appear to be inheriting from the Cache-Control configuration.

The Expires header appeared to always be equal to request time plus 1 year, regardless of Cache-Control setting, eg.

$ gsutil setmeta -h "Cache-Control:300" gs://example-bucket/doc.html 

A request was made to a document (doc.html) in the Google Cloud Storage bucket (example-bucket) via

$ curl -I http://example-bucket.storage.googleapis.com/doc.html

which produced the following headers

HTTP/1.1 200 OK
Server: HTTP Upload Server Built on Oct 3 2012 16:52:30 (1349308350)
Date: Sat, 13 Oct 2012 00:51:13 GMT
Cache-Control: 300, no-transform
Expires: Sun, 13 Oct 2013 00:51:13 GMT
Last-Modified: Fri, 12 Oct 2012 20:08:41 GMT
ETag: "28fafe4213ae34c7d3ebf9ac5a6aade8"
x-goog-sequence-number: 82
x-goog-generation: 1347601001449082
x-goog-metageneration: 1
Content-Type: text/html
Accept-Ranges: bytes
Content-Length: 7069
Vary: Origin
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T18:39:51+00:00Added an answer on June 12, 2026 at 6:39 pm

    Not sure why you say the Expires header shows request time plus 1 year. In your example, the Expires header shows a timestamp one hour after the request date, which is to be expected.

    I just did an experiment where I set an object’s max age to 3600 and then 7200 via this command:

    gsutil setmeta "Cache-Control:max-age=7200" gs://marc-us/xyz.txt
    

    Then I retrieved the object using the gsutil cat command with the -D option to see the request/response details, like this:

    gsutil -D cat gs://marc-us/xyz.txt
    

    In both experiments, the Expires header produced the expected timestamp, as per the object’s max-age setting (i.e. one hour after request time and two hours after request time).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I set up a required environment for Google Cloud Storage according to the manual.
I am looking for some examples on storing some data into Google cloud storage
I'm using the carrierwave gem to upload file attachments to Google cloud storage. This
Google cloud storage allows users to check a publicly shared? field in the storage
We would like to start using Google Cloud Storage as a persistent store for
I want to upload data from Google Cloud Storage to BigQuery, but I can't
I am very new to the google cloud storage. I want to create folder
I'm trying to create a bucket on google cloud storage using PHP and REST.
I am using the code given below to get response from google cloud storage
Do you know good C/C++ library for Google Cloud Storage ? I can find

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.