Download as pdf or txt
Download as pdf or txt
You are on page 1of 19

Cloud Storage

Umme Midrar
Cloud Storage is an object storage service
● Website content
● Storing data for archiving and disaster recovery.
● Distributing large data objects to users via direct download

Basic tools for Cloud Storage


● Console
● Google Cloud CLI
● Client libraries
Cloud Storage Overview
1. Buckets :
● Buckets are the basic containers that hold your data.
● Everything that you store in Cloud Storage must be contained in a bucket.
● Globally Unique Name ( Name requirement)
● Cannot be nested
● There are limits to rate you can create or delete buckets.
2. Objects
● Data in the buckets are objects.
Ex : text files, audio files,video file etc.
● Objects inherit the storage class of bucket when created.
● No minimum size of objects.
● Unlimited storage.

3. Access

● Use gsutil command or


● Rest full API
Cloud Storage Classes
Storage classes offered by Cloud Storage are :

❏ Standard storage
❏ Nearline storage
❏ Coldline storage
❏ Archive storage
1. Standard storage
● Use case : "Hot" data and/or stored for only brief periods of time like
data-intensive computations.
● Minimum storage duration : None
● Retrieval cost : none

2 . Nearline storage

● Infrequently accessed data like data backup and data archiving


● Minimum storage duration : 30 days
● Retrieval cost : $0.01 per GB
3. Coldline storage
● Use case : Infrequently accessed data that you read or modify at most once a quarter
● Minimum storage duration : 90 days
● Retrieval cost : $0.02 per GB

4. Archive storage

● Use case : Data archiving, online backup, and disaster recovery .


● Minimum storage duration : 365 days
● Retrieval cost : $0.05 per GB
Choosing the storage class
Changing the default storage class
● Default class is applied to new objects.
● Regional bucket can never be changed to multi-regional region
● Multi- region can never be changed to regional.
● Objects can be moved from bucket to bucket.
● Object Lifecycle Management can manage the classes of objects.
Access Control
1. IAM -
● use IAM for the project to control which individual users or service account can see the
bucket ,list the objects in the bucket, view the names of the objects in the bucket or create
new buckets.
2. Access Control List - offer finer control for even more detailed control.
3. Signed URL -provide a cryptographic key that gives time limited access to a bucket or
object.
4. Sighed policy document -refines the control by determining what file can be uploaded by
someone with a signed URL
Access Control List
● ACL is a mechanisms used to define who has access to your buckets and objects, as
well as what the level of access to have.
● The maximum number of ACL entries you can create for a bucket or object is 100.
● Each ACL of one or more entries, and these entries consists of two pieces of
information.

1. A scope - which defines who can perform the specified action.

2. Permission - defines what actions can be performed.

Ex : allUsers identifier.

allAuthenticatedUsers.
Signed URLS
● For some applications it is easier and more efficient to grant limited time access tokens that
can be used by any user instead of using account based authentication for controlling
resource access.
● For example, when you don't want to require users to have a Google account Signed URLS
allow you to do this for cloud storage.
Cloud Storage Features
1. Object Versioning

You enable Object Versioning for a bucket. Once enabled:

● Cloud Storage retains a noncurrent object version each time you replace or delete a
live object version.
○ Noncurrent versions retain the name of the object, but are uniquely identified
by their generation number.
● You permanently delete versions of objects by including the generation number in
the deletion request or by using Object Lifecycle Management.
2. Object Lifecycle Management

To support common use cases like

● setting a Time to Live (TTL) for objects


● retaining noncurrent versions of objects, or
● "downgrading" storage classes of objects to help manage costs.

In order to use Object Lifecycle Management, you define a lifecycle configuration,


which must be set on a bucket.
● The configuration contains a set of rules which apply to current and future
objects in the bucket.
● When an object meets the criteria of one of the rules, Cloud Storage automatically
performs a specified action on the object .

Ex :

❖ Downgrade the storage class of objects older than 365 days to Coldline storage.
❖ Delete objects created before January 1, 2019.
❖ Keep only the 3 most recent versions of each object in a bucket with versioning enabled.
3. Object Change Notification

● Object change notification can be used to notify an application when an object is


updated or added to a bucket.
● A client application can send a request to watch for changes to the objects in a
particular bucket.
● Completing a watch request creates a new notification channel.
● Notification channel : webhook
4. Data Import service :

I. Transfer Appliance
II. Storage Transfer service
III. Offline Media Import.

5. Strong Consistency :

- Provides Strong global consistency


- Uploads are strongly consistent.

You might also like