Skip to Content
Head First Python, 개정판 : 스스로 질문하며 답을 찾는 파이썬 학습서(Python 3)
book

Head First Python, 개정판 : 스스로 질문하며 답을 찾는 파이썬 학습서(Python 3)

by 우정은, 폴 배리
December 2017
Beginner
624 pages
15h 38m
Korean
Hanbit Media, Inc.
Content preview from Head First Python, 개정판 : 스스로 질문하며 답을 찾는 파이썬 학습서(Python 3)
460 Chapter 11
다양한 문제
때로는 입출력이 오래 걸릴 수 있어요
우리 웹앱은 백엔드 데이터베이스와 거의 동시에 통신하므로 웹앱 사용자는 웹앱과
데이터베이스가 통신하는 동안 거의 아무 지연도 느낄 수 없습니다. 하지만 백엔드
데이터베이스와 통신하는 데 몇 초 정도 걸린다고 생각해보세요.
from time import sleep
import
문을 추가했으면
log
_
request
함수의
with
문 앞에 아래 코드를
추가하세요.
sleep(15)
웹앱을 다시 시작한 다음 검색을 수행하면 결과가 표시되기 전에 상당한 지연이 발생합니다.
15
초는 상당히 긴 시간입니다. 웹에
15
초의 지연이 발생하면 대부분의 사용자는 우리
웹앱이 크래시되었다고 생각할 겁니다.
Do it!
버튼을 클릭하면
웹 브라우저는 기다리고...
기다리고... 계속 기다립니다.
어떤 작업을 하는 데 시간이 오래 걸리면 어떤 일이 일어날까요?
백엔드 데이터베이스가 다른 건물 또는 심지어 다른 대륙에 있다면 어떤 일이
일어날까요?
3
백엔드 데이터베이스와 통신하는 데 시간이 걸릴 수 있습니다. 실제로 코드가 파일,
데이터베이스, 네트워크 등 외부 리소스와 상호작용하느라 시간이 걸릴 수 있는데 이는
우리가 어떻게 제어할 수 있는 부분이 아닙니다. 하지만 어떤 동작이 오래 걸릴 수도 있다 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

NGINX 쿡북 : 112가지 레시피로 배우는 고성능 부하분산, 보안, 서버 배포와 관리

NGINX 쿡북 : 112가지 레시피로 배우는 고성능 부하분산, 보안, 서버 배포와 관리

노승현, 데릭 디용기
몽고DB 완벽 가이드(3판): 실전 예제로 배우는 NoSQL 데이터베이스 기초부터 활용까지

몽고DB 완벽 가이드(3판): 실전 예제로 배우는 NoSQL 데이터베이스 기초부터 활용까지

김인범, 크리스티나 초도로우, 섀넌 브래드쇼, 오언 브라질

Publisher Resources

ISBN: 9791162240281