<commit_before>This document defines the semantics of a gcsfuse file system mounted with a GCS
bucket, including how files and directories map to object names, what
consistency guarantees are made, etc.


# Caching

By default, gcsfuse has two forms of caching enabled that reduce consistency
guarantees. They are discussed in this section, along with their trade-offs and
the situations in which they are and are not safe to use.

**Important**: The rest of this document assumes that caching is disabled (by
setting `--stat_cache_ttl 0` and `--type_cache_ttl 0`. This is not the default.
If you want the consistency guarantees discussed in this document, you must use
these options to disable caching.

## Stat caching

The cost of the consistency guarantees discussed in the rest of this document<commit_msg>Added a discussion of the default behavior.<commit_after>This document defines the semantics of a gcsfuse file system mounted with a GCS
bucket, including how files and directories map to object names, what
consistency guarantees are made, etc.


# Caching

By default, gcsfuse has two forms of caching enabled that reduce consistency
guarantees. They are discussed in this section, along with their trade-offs and
the situations in which they are and are not safe to use.

The default behavior is appropriate, and brings significant performance
benefits, when the bucket is never modified or is modified only via a single
gcsfuse mount. If you are using gcsfuse in a situation where multiple actors
will be modifying a bucket, be sure to read the rest of this section carefully
and consider disabling caching.

**Important**: The rest of this document assumes that caching is disabled (by
setting `--stat_cache_ttl 0` and `--type_cache_ttl 0`. This is not the default.
If you want the consistency guarantees discussed in this document, you must use
these options to disable caching.

## Stat caching

The cost of the consistency guarantees discussed in the rest of this document
{'fraction_non_alphanumeric': 0.036180904522613064, 'fraction_numerical': 0.0020100502512562816, 'mean_word_length': 4.721264367816092, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1255955', 'n_tokens_mistral': 502, 'n_tokens_neox': 466, 'n_words': 306}