SlideShare a Scribd company logo
1 of 8
Download to read offline
Uploading multiple files to
Google Cloud Storage
Zdenko Hrcek
https://the-swamp.info
zdenulo@gmail.com
@zdenulo
+ZdenkoHrcek
Motivation
● Based on application, users often need to upload files (images, documents,
videos)
● Usually content is posted to server and then processed and saved
● Files are usually small (few MB) but can be larger (tens/hundreds) MB
● Uploading lot of content can be memory demanding for server
● Google Cloud Storage offers possibility to upload file straight to bucket
Process for uploading file from Browser to Google Cloud Storage
1. Before actual upload, make request to server to get signed url for file which
will be uploaded
2. Generate signed url for upload with GCS client library on server and return
back
3. Use the signed url to upload content of file (via Ajax request)
Process for uploading file from Browser to Google Cloud Storage
Steps
1. Create bucket in Google Cloud Storage
2. Setup CORS (Cross Origin Resource Sharing)
3. Setup Service Account
4. Setup server (in this case Google App Engine)
Signed URL
Manual process of constructing signed url is described here:
https://cloud.google.com/storage/docs/access-control/signed-urls
More simpler approach is to use one of client libraries. In Python:
url = file_blob.generate_signed_url(datetime.datetime.now() + datetime.timedelta(hours=2),
method='PUT', content_type=content_type)
Full example with code
https://github.com/zdenulo/gcs_multiple_upload
Detailed description:
https://www.the-swamp.info/blog/uploading-files-google-cloud-storage/
Subscribe
Weekly Newsletter about Google Cloud Platform:
https://www.the-swamp.info/newsletter/
Blog:
https://www.the-swamp.info/blog/
Youtube channel:
https://www.youtube.com/channel/UCDWFQggcnphi9UyZxyFjolg
Consulting:
https://www.the-swamp.info/consulting/

More Related Content

What's hot

Docker道場「Dockerの基本概念」0825インフラ勉強会資料
Docker道場「Dockerの基本概念」0825インフラ勉強会資料Docker道場「Dockerの基本概念」0825インフラ勉強会資料
Docker道場「Dockerの基本概念」0825インフラ勉強会資料Masahito Zembutsu
 
flaws.cloudに挑戦しよう!
flaws.cloudに挑戦しよう!flaws.cloudに挑戦しよう!
flaws.cloudに挑戦しよう!zaki4649
 
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能について
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能についてDeep Dive into the Linux Kernel - メモリ管理におけるCompaction機能について
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能についてNTT DATA Technology & Innovation
 
Python을 활용한 챗봇 서비스 개발 2일차
Python을 활용한 챗봇 서비스 개발 2일차Python을 활용한 챗봇 서비스 개발 2일차
Python을 활용한 챗봇 서비스 개발 2일차Taekyung Han
 
JiraとConfluenceのTips集
JiraとConfluenceのTips集JiraとConfluenceのTips集
JiraとConfluenceのTips集Hiroshi Ohnuki
 
ダークネットのはなし #ssmjp
ダークネットのはなし #ssmjpダークネットのはなし #ssmjp
ダークネットのはなし #ssmjpsonickun
 
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...taeseon ryu
 
LLM 모델 기반 서비스 실전 가이드
LLM 모델 기반 서비스 실전 가이드LLM 모델 기반 서비스 실전 가이드
LLM 모델 기반 서비스 실전 가이드Tae Young Lee
 
Ruby 3のキーワード引数について考える
Ruby 3のキーワード引数について考えるRuby 3のキーワード引数について考える
Ruby 3のキーワード引数について考えるmametter
 
Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話dcubeio
 
ぼくがAthenaで死ぬまで
ぼくがAthenaで死ぬまでぼくがAthenaで死ぬまで
ぼくがAthenaで死ぬまでShinichi Takahashi
 
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウYoichi Kawasaki
 
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?Google Cloud Platform - Japan
 
コンテナの作り方「Dockerは裏方で何をしているのか?」
コンテナの作り方「Dockerは裏方で何をしているのか?」コンテナの作り方「Dockerは裏方で何をしているのか?」
コンテナの作り方「Dockerは裏方で何をしているのか?」Masahito Zembutsu
 
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみたtokita-r
 
ソーシャルゲームにおけるMongoDB適用事例 - Animal Land
ソーシャルゲームにおけるMongoDB適用事例 - Animal LandソーシャルゲームにおけるMongoDB適用事例 - Animal Land
ソーシャルゲームにおけるMongoDB適用事例 - Animal LandMasakazu Matsushita
 
BuildKitによる高速でセキュアなイメージビルド
BuildKitによる高速でセキュアなイメージビルドBuildKitによる高速でセキュアなイメージビルド
BuildKitによる高速でセキュアなイメージビルドAkihiro Suda
 
Hpo를 위한 sweep 소개
Hpo를 위한 sweep 소개Hpo를 위한 sweep 소개
Hpo를 위한 sweep 소개kiminPark2
 
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기CONNECT FOUNDATION
 

What's hot (20)

Docker道場「Dockerの基本概念」0825インフラ勉強会資料
Docker道場「Dockerの基本概念」0825インフラ勉強会資料Docker道場「Dockerの基本概念」0825インフラ勉強会資料
Docker道場「Dockerの基本概念」0825インフラ勉強会資料
 
flaws.cloudに挑戦しよう!
flaws.cloudに挑戦しよう!flaws.cloudに挑戦しよう!
flaws.cloudに挑戦しよう!
 
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能について
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能についてDeep Dive into the Linux Kernel - メモリ管理におけるCompaction機能について
Deep Dive into the Linux Kernel - メモリ管理におけるCompaction機能について
 
Python을 활용한 챗봇 서비스 개발 2일차
Python을 활용한 챗봇 서비스 개발 2일차Python을 활용한 챗봇 서비스 개발 2일차
Python을 활용한 챗봇 서비스 개발 2일차
 
JiraとConfluenceのTips集
JiraとConfluenceのTips集JiraとConfluenceのTips集
JiraとConfluenceのTips集
 
ダークネットのはなし #ssmjp
ダークネットのはなし #ssmjpダークネットのはなし #ssmjp
ダークネットのはなし #ssmjp
 
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...
Senti prompt sentiment knowledge enhanced prompt tuning for aspect-based sent...
 
LLM 모델 기반 서비스 실전 가이드
LLM 모델 기반 서비스 실전 가이드LLM 모델 기반 서비스 실전 가이드
LLM 모델 기반 서비스 실전 가이드
 
Ruby 3のキーワード引数について考える
Ruby 3のキーワード引数について考えるRuby 3のキーワード引数について考える
Ruby 3のキーワード引数について考える
 
Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話Go初心者がGoでコマンドラインツールの作成に挑戦した話
Go初心者がGoでコマンドラインツールの作成に挑戦した話
 
ぼくがAthenaで死ぬまで
ぼくがAthenaで死ぬまでぼくがAthenaで死ぬまで
ぼくがAthenaで死ぬまで
 
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ
15分でお届けする Elastic Stack on Azure 設計・構築ノウハウ
 
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
Google Cloud ベストプラクティス:Google BigQuery 編 - 01 : BigQuery とは?
 
コンテナの作り方「Dockerは裏方で何をしているのか?」
コンテナの作り方「Dockerは裏方で何をしているのか?」コンテナの作り方「Dockerは裏方で何をしているのか?」
コンテナの作り方「Dockerは裏方で何をしているのか?」
 
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた
【GOJAS Meetup-10】Splunk:SmartStoreを使ってみた
 
Cerberus Testing
Cerberus TestingCerberus Testing
Cerberus Testing
 
ソーシャルゲームにおけるMongoDB適用事例 - Animal Land
ソーシャルゲームにおけるMongoDB適用事例 - Animal LandソーシャルゲームにおけるMongoDB適用事例 - Animal Land
ソーシャルゲームにおけるMongoDB適用事例 - Animal Land
 
BuildKitによる高速でセキュアなイメージビルド
BuildKitによる高速でセキュアなイメージビルドBuildKitによる高速でセキュアなイメージビルド
BuildKitによる高速でセキュアなイメージビルド
 
Hpo를 위한 sweep 소개
Hpo를 위한 sweep 소개Hpo를 위한 sweep 소개
Hpo를 위한 sweep 소개
 
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기
[부스트캠프 Tech Talk] 진명훈_datasets로 협업하기
 

Similar to Uploading multiple files to Google Cloud Storage

Optimising Web Application Frontend
Optimising Web Application FrontendOptimising Web Application Frontend
Optimising Web Application Frontendtkramar
 
GAE for PHP - Google Cloud SQL and Cloud Storage
GAE for PHP - Google Cloud SQL and Cloud StorageGAE for PHP - Google Cloud SQL and Cloud Storage
GAE for PHP - Google Cloud SQL and Cloud StorageChen Yi-Huan
 
High Performance Ajax Applications
High Performance Ajax ApplicationsHigh Performance Ajax Applications
High Performance Ajax ApplicationsSiarhei Barysiuk
 
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptxSachinGosavi15
 
Lavakumar kuppan _lust_2_0 - ClubHack2009
Lavakumar kuppan _lust_2_0 - ClubHack2009Lavakumar kuppan _lust_2_0 - ClubHack2009
Lavakumar kuppan _lust_2_0 - ClubHack2009ClubHack
 
Analysis of Google Page Speed Insight
Analysis of Google Page Speed InsightAnalysis of Google Page Speed Insight
Analysis of Google Page Speed InsightSarvesh Sonawane
 
Implementing Early Hints in Chrome - Approaches and Challenges
Implementing Early Hints in Chrome - Approaches and ChallengesImplementing Early Hints in Chrome - Approaches and Challenges
Implementing Early Hints in Chrome - Approaches and ChallengesViet-Hoang Tran
 
Overview of Cookies in HTTP - Miran al Mehrab
Overview of Cookies in HTTP - Miran al MehrabOverview of Cookies in HTTP - Miran al Mehrab
Overview of Cookies in HTTP - Miran al MehrabCefalo
 
T3DD22 - Set up a CDN in 5 Minutes
T3DD22 - Set up a CDN in 5 MinutesT3DD22 - Set up a CDN in 5 Minutes
T3DD22 - Set up a CDN in 5 MinutesBenni Mack
 
File uploads to s3
File uploads to s3File uploads to s3
File uploads to s3varunlalan
 
Cache is keeping you from reaching the full potential as a developer (word ca...
Cache is keeping you from reaching the full potential as a developer (word ca...Cache is keeping you from reaching the full potential as a developer (word ca...
Cache is keeping you from reaching the full potential as a developer (word ca...Thomas Audunhus
 
Web site loading time optimization
Web site loading time optimizationWeb site loading time optimization
Web site loading time optimizationDamith Kothalawala
 
Reducing latency on the web with the Azure CDN - DevSum - SWAG
Reducing latency on the web with the Azure CDN - DevSum - SWAGReducing latency on the web with the Azure CDN - DevSum - SWAG
Reducing latency on the web with the Azure CDN - DevSum - SWAGMaarten Balliauw
 
BUILDING WEBSITES ON WORDPRESS
BUILDING WEBSITES ON WORDPRESSBUILDING WEBSITES ON WORDPRESS
BUILDING WEBSITES ON WORDPRESSPRINCE KUMAR
 
Web Site Optimization
Web Site OptimizationWeb Site Optimization
Web Site OptimizationSunil Patil
 
Web site optimization
Web site optimizationWeb site optimization
Web site optimizationSunil Patil
 
The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...Otto Kekäläinen
 

Similar to Uploading multiple files to Google Cloud Storage (20)

Optimising Web Application Frontend
Optimising Web Application FrontendOptimising Web Application Frontend
Optimising Web Application Frontend
 
GAE for PHP - Google Cloud SQL and Cloud Storage
GAE for PHP - Google Cloud SQL and Cloud StorageGAE for PHP - Google Cloud SQL and Cloud Storage
GAE for PHP - Google Cloud SQL and Cloud Storage
 
High Performance Ajax Applications
High Performance Ajax ApplicationsHigh Performance Ajax Applications
High Performance Ajax Applications
 
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx
219568662-QUICK-Cloud-Storage-Forensic-Analysis-Presentation.pptx
 
Lavakumar kuppan _lust_2_0 - ClubHack2009
Lavakumar kuppan _lust_2_0 - ClubHack2009Lavakumar kuppan _lust_2_0 - ClubHack2009
Lavakumar kuppan _lust_2_0 - ClubHack2009
 
Analysis of Google Page Speed Insight
Analysis of Google Page Speed InsightAnalysis of Google Page Speed Insight
Analysis of Google Page Speed Insight
 
Implementing Early Hints in Chrome - Approaches and Challenges
Implementing Early Hints in Chrome - Approaches and ChallengesImplementing Early Hints in Chrome - Approaches and Challenges
Implementing Early Hints in Chrome - Approaches and Challenges
 
Overview of Cookies in HTTP - Miran al Mehrab
Overview of Cookies in HTTP - Miran al MehrabOverview of Cookies in HTTP - Miran al Mehrab
Overview of Cookies in HTTP - Miran al Mehrab
 
T3DD22 - Set up a CDN in 5 Minutes
T3DD22 - Set up a CDN in 5 MinutesT3DD22 - Set up a CDN in 5 Minutes
T3DD22 - Set up a CDN in 5 Minutes
 
File uploads to s3
File uploads to s3File uploads to s3
File uploads to s3
 
Final Presentation
Final PresentationFinal Presentation
Final Presentation
 
Cache is keeping you from reaching the full potential as a developer (word ca...
Cache is keeping you from reaching the full potential as a developer (word ca...Cache is keeping you from reaching the full potential as a developer (word ca...
Cache is keeping you from reaching the full potential as a developer (word ca...
 
Web site loading time optimization
Web site loading time optimizationWeb site loading time optimization
Web site loading time optimization
 
Reducing latency on the web with the Azure CDN - DevSum - SWAG
Reducing latency on the web with the Azure CDN - DevSum - SWAGReducing latency on the web with the Azure CDN - DevSum - SWAG
Reducing latency on the web with the Azure CDN - DevSum - SWAG
 
Website optimization
Website optimizationWebsite optimization
Website optimization
 
BUILDING WEBSITES ON WORDPRESS
BUILDING WEBSITES ON WORDPRESSBUILDING WEBSITES ON WORDPRESS
BUILDING WEBSITES ON WORDPRESS
 
Web server
Web serverWeb server
Web server
 
Web Site Optimization
Web Site OptimizationWeb Site Optimization
Web Site Optimization
 
Web site optimization
Web site optimizationWeb site optimization
Web site optimization
 
The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...
 

Recently uploaded

CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Hyundai Motor Group
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsMemoori
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 

Recently uploaded (20)

CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2Next-generation AAM aircraft unveiled by Supernal, S-A2
Next-generation AAM aircraft unveiled by Supernal, S-A2
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
AI as an Interface for Commercial Buildings
AI as an Interface for Commercial BuildingsAI as an Interface for Commercial Buildings
AI as an Interface for Commercial Buildings
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 

Uploading multiple files to Google Cloud Storage

  • 1. Uploading multiple files to Google Cloud Storage Zdenko Hrcek https://the-swamp.info zdenulo@gmail.com @zdenulo +ZdenkoHrcek
  • 2. Motivation ● Based on application, users often need to upload files (images, documents, videos) ● Usually content is posted to server and then processed and saved ● Files are usually small (few MB) but can be larger (tens/hundreds) MB ● Uploading lot of content can be memory demanding for server ● Google Cloud Storage offers possibility to upload file straight to bucket
  • 3. Process for uploading file from Browser to Google Cloud Storage 1. Before actual upload, make request to server to get signed url for file which will be uploaded 2. Generate signed url for upload with GCS client library on server and return back 3. Use the signed url to upload content of file (via Ajax request)
  • 4. Process for uploading file from Browser to Google Cloud Storage
  • 5. Steps 1. Create bucket in Google Cloud Storage 2. Setup CORS (Cross Origin Resource Sharing) 3. Setup Service Account 4. Setup server (in this case Google App Engine)
  • 6. Signed URL Manual process of constructing signed url is described here: https://cloud.google.com/storage/docs/access-control/signed-urls More simpler approach is to use one of client libraries. In Python: url = file_blob.generate_signed_url(datetime.datetime.now() + datetime.timedelta(hours=2), method='PUT', content_type=content_type)
  • 7. Full example with code https://github.com/zdenulo/gcs_multiple_upload Detailed description: https://www.the-swamp.info/blog/uploading-files-google-cloud-storage/
  • 8. Subscribe Weekly Newsletter about Google Cloud Platform: https://www.the-swamp.info/newsletter/ Blog: https://www.the-swamp.info/blog/ Youtube channel: https://www.youtube.com/channel/UCDWFQggcnphi9UyZxyFjolg Consulting: https://www.the-swamp.info/consulting/